Android Question Splash image & multiple screen

luke2012

Well-Known Member
Licensed User
Longtime User
Hi to all,
I have to introduce a new splash in my app.

Which is the best approach in order to display the image correctly on all devices ?

1) Create differtent version of the image based on the display resolution
2) Create a single image and set the gravity to center. (the problem in this case is to center correctly the image on all the kind of device).

Any suggestion ?
 

luke2012

Well-Known Member
Licensed User
Longtime User
You can use ImageView with Gravity = Gravity.FILL. This way the image will be stretched as needed.

Yes I'm already using this Gravity setting.
My problem is that the image (480 x 800 pixel) is stretched on big screen (ex. Galaxy S4) and the image ratio is lost.

The Galaxy S4 has a screen width of 1080 pixel and my image has a width of 480.
 
Upvote 0
Top