Android ViewPager Performance on Galaxy Tab 2

I have an application that uses Android ViewPager (7 views, quite complicated with images and animations). This app works fantastically on my Asus Eee Pad. This is just great.

I also have a Galaxy Tab 2 10.1, which can hardly start the application ... despite the fact that it is completely new and theoretically more powerful than my EEE Pad. I would like to mention that both terminals are running Android 4.0.3, and their screen size is identical (1280x800). The application works in landscape mode.

The application does not use sql or Internet access, just animation on different views and the ViewPager scroll effect.

I checked, I think everything, from the heap, from lint, from almost all available profiling tools, but nothing seems to improve the performance of my user interface on the Galaxy Tab 2 ... I wonder if there is any difference in finally, the hardware in which ASUS will use a graphics processor to display its processor’s user interface and Galaxy Tab 2 ...

I was wondering, finally, if any of you noticed some similar problems on the Galaxy Tab or other tablets when comparing the behavior of your application for several purposes ...

Hooray! Floor

--- added on September 6 ---

Well, it seems that despite the fact that the Galaxy tablet should use hardware acceleration, it is not. When I force every xml layout with android:layerType="hardware" and

 v.setLayerType(View.LAYER_TYPE_HARDWARE, null);  ObjectAnimator oaAlpha = ObjectAnimator.ofFloat(v, "alpha",0f, 1f); 

it works, finally, better ... even if it's not as smooth as on Asus one

+4
source share
1 answer

Finally, I discovered - and this is really strange - the performance issue was caused by the font size being too high!?!

It was a sad experience ... but for some stupid reason, Galaxy Tab 2.0 had serious problems with displaying texts written in capital letters. And this is due to Galaxy Tabs (as I present the equipment), because I tried with So to just remake your application with smaller fonts and do not forget to complain about Samsung.

+1
source

Source: https://habr.com/ru/post/1432492/


All Articles