My Canvas Drawing is not shown in some devices ... strange behavior - android

I have an application, I have created a custom view and implement onDraw Myself, The application take some bitmaps and draw them as list with some algorithm
I have used 9 item to test it and it works perfect, when I increase the number of items to 18 item and try to test, it draw item when I use portrait mode but draw nothing on landscape mode
It works on the following devices :
Samsung (GT-I5510) with 2.2 OS
Samsung (GT-S6500D) with 2.3.6 OS
HTC (Nexus One) with 2.3.6 OS
Sony (Xperia-ST23i) with 4.0.4 OS
TouchMate Tablet
it have a strange behavior in the following devices:
Samsung (Tablet GT-P3100, S2, S4) it show the drawing on portrait mode but it doesn't show it in landscape mode
HTC (OneX) it doesn't show drawing in portrait or landscape
I have the following warning show in Logcat
Bitmap too large to be uploaded into a texture (Tablet)
Reached here in cacheGlyph
Can any one help please ? I think it may be something related to hardware

You should try turning off the hardware acceleration.
This will explain everything you need to know about hardware acceleration: http://developer.android.com/guide/topics/graphics/hardware-accel.html

Related

Landscape/portrait orientation for my first app: why is it stuck?

I've just deployed the "first app" demo from Android Studio on a Nexus 10 emulator and on my physical Nexus 10 (API 22 / Lollipop 5.1).
On the emulator, when I change the orientation, the app rotates, but on my physical device it doesn't, it's stuck in landscape.
I've checked VLC rotates fine on my physical device for example, so the sensor is not the problem.
If you want to change your screen orientation based on sensors use the below code
activityContext.setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_FULL_SENSOR);
Thats what VLC does rotates screen based on Sensors.

Android screen vertically desynchronization when run app

Our android app user reported they had display error situation like the picture below, on some tablets like these 2 :
Sony Xperia Z3 8 inch,
Google nexus 7 2013.
Both are Android 6.0.1, 1200x1920 resolution.
Is there any special setting needed to some tablet, Android 6.0.1 or resolution 1200x1920? Or does anyone has similar desynchronization happened on your app?
This display error is not reported on phones. Most of phones' resolution are 1080x1920 or less.
this is the screen shot
We've found the root cause. It's because we use the solution below to detect soft keyboard appearance and then hide some views. When the views are hidden, the value of "activityRootView.getHeight();" will become bigger. So, the threshold of "dpToPx(this, 200)", to check whether soft keyboard appears, need be carefully choose.
How to check visibility of software keyboard in Android?

Odroid-XU4 Android full-screen portrait orientation

I want to install an Android OS to an Odroid-XU4 device and connect it to a vertical touchscreen through HDMI. I want the content be displayed as portrait and fit the screen.
I installed 4.4.4, 6.0 (Cyanogenmod 13.0) and 7.1(Lineage 14.1) android images to the Odroid. By default, all of them display the screen as landscape , so I must configure the OS to get it displayed as portrait.
I first used AndroidUtility (a tool included in the OS image) and set HDMI orientation as portrait. The screen is displayed great (portrait and full screen) with the 4.4.4 OS image. Unfortunately, 4.4.4 OS doesn't work for me because the device has to be a COSU and this needs 6.0 or above OS version.
But using AndroidUtility , the screen is displayed like this in both 6.0 and 7.1 OSs:
After looking it over forums, blogs... I found out that the solution should be editting these lines in OS build.prop config file:
persist.demo.hdmirotation=portrait
ro.sf.hwrotation=270 (I have tried 90 too)
windowsmgr.support_rotation_270=true
Doing this, 7.1 OS version looks as portait and fills all the screen... but it's displayed upside down.
And 6.0 OS version looks not only turned, but also cropped:
How can I get it displayed as portrait and full-screen?
I had this same issue using LineageOS from here
(Source)
I ran the update to the most recent release from the ODROID Utility and it changed the "HDMI Landscape / HDMI Portrait 90+270" to a straight 0, 90, 180, 270. To change it required a reboot.
(Fetched)
All Android devices manages the screen sizes in the same way, so that has nothing to do with your android odroid, unless you have forced to be in landscape, and your monitor source is with a portrait orientation.
You just need to adjust your screen display monitor source orientation usually is using your screen menu, `
Menu->Display->(Horizontal or Vertical)

Android blurry screen sometimes

This device:
https://www.amazon.de/Sony-Tablet-PC-Touchscreen-GHz-Quad-Core-Prozessor-interner/dp/B00IN1N66I
Sony Xperia Tablet Z2 SGP511 (10,1") Tablet-PC (Touchscreen, 2,3
GHz-Quad-Core-Prozessor, 3GB RAM, 16GB)
Android version 5.1.1 (Lollipop)
I'm developing an app with cordova (hybrid) and the screen gets blurry sometimes for no appearant reason.
This usually goes away when I tap the screen in a random place inside the div or element that is blurry.
Blurry:
=============================================
Clear:
The application gets blurry only while remotely debugging the android device. So it isn't an issue or some error. Blur goes away either when tapping the application or by disconnecting the device from the computer.

LG optimus 3D effect in portrait mode

I am working on LG optimus 3D mobile platform and it seems to me I can experience the depth of three dimensions in landscape mode but the effect is completely lost while the phone is in portrait. does anyone have any suggeston how to make that work on portrait mode as well?
If you are using the p920, i'm afraid you (actually we cuz I have one too) are out of luck. 3d is landscape only.
Reference links :
http://3dvision-blog.com/5798-testing-the-3d-capabilities-of-the-lg-optimus-3d-p920-smartphone/
http://blog.gsmarena.com/htc-evo-3d-vs-lg-optimus-3d-taking-the-fight-to-another-dimension/

Categories

Resources