Forums Register Login

Images for multi screen support

+Pie Number of slices to send: Send
Hello friends,

I have confusion regarding multi screens support in android. I have gone through article for multi screen support at android developer forum. My question is if app has 15-20 images that need to be shown full screen on device screen. Now if I want to support all screens what resolution & densities images i should put in three folders ldpi, mdpi & hdpi. Here what i am doing till now

In ldpi - images of 240x320 resolution
mdpi - images of 320x480 reolution
hdpi - images of 720x800 resolution.
(I am using same densities for all three resolution)
I think this is not right approach.

What exactly I should do? Put images of different resolution in drawable-ldpi, drawable-mdpi & drawable-hdpi as above or should i use images of different densities 120 dpi, 160 dpi & 240 dpi. If i use images of different densities what should be their resolution(should 120 dpi resolution be 240x320, 160 dpi resolution 320x480 & 240 dpi resolution be 480x800). Or if i am using different dpi images their resolution should be same(320x480) for all densities .

Regards,
Anuj
+Pie Number of slices to send: Send
I don't think Android uses the image density - it just goes by the pixel size and scales as needed. One thing to try would be to use a single "drawable" directory (i.e., delete the more specific ones) and put images with a 480 pixel width in it (which for the time being should be large enough for all phones).
+Pie Number of slices to send: Send
Thanks for replying.

I have tried that using images of 480x800 resolution. It does not look good when tested on device(samsung galaxy 3) or emulator of resolution 320x480 mdpi. Images look compressed, there are horizontal compression lines that are slightly visible.
+Pie Number of slices to send: Send
If the approach you mentioned in your first post doesn't produce satisfactory results, maybe you need to do it programmatically: ship images of various sizes with the app, detect the screen size with your code, and then pick and display an image of appropriate size.
Do not set lab on fire. Or this tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com


reply
reply
This thread has been viewed 2024 times.
Similar Threads
Tablet support in general and table specific APIs
How to convert Android App to Samsung Galaxy S2
How to force landscape under all circumstances?
Using graphics in game
Portrait/Landscape image size
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 28, 2024 16:14:51.