[android-developers] Re: Optimal packaging of image app for various screen resolutions
What you can do is put all of the images in the raw directory at high resolution. And on first start scale them and place them into cache(SD card or app's own storage). On 7 фев, 23:28, Johan johan.pelg...@gmail.com wrote: Hi there, I'm working on an app which displays various images. I want to optimize this for the various screen resolutions. The MultiResolution (1) tutorial uses many resource qualifiers in the res folder to display the appropriate images for the various device resolutions, but how do you package this? I don't want to ship the images for all devices (or do I?). I want to keep the download size as small as possible, so I only want to package the ones for that particular screen resolution. Or, should I forget packaging images and put the images on-line somewhere? Any opinions on this subject would be appreciated (1)http://developer.android.com/resources/samples/MultiResolution/index -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Optimal packaging of image app for various screen resolutions
I don't think I would recommend separate APKs, actually. That'll inevitably cause confusion and problems for your users, as well as splitting whatever userbase you have across multiple packages, not good for your Market rankings. If you're not targeting Cupcake, a variation on Aleksandr's suggestion might work.: put all your images in -hdpi directories and let the system scale them for other densities. It generally does a better job downscaling than upscaling, for obvious reasons, so the results might be acceptable. Note that I haven't tried this, but it seems plausible. String -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Optimal packaging of image app for various screen resolutions
Thanks Aleksandr and Sterling! Might be worth a shot! On Feb 8, 10:54 am, String sterling.ud...@googlemail.com wrote: I don't think I would recommend separate APKs, actually. That'll inevitably cause confusion and problems for your users, as well as splitting whatever userbase you have across multiple packages, not good for your Market rankings. If you're not targeting Cupcake, a variation on Aleksandr's suggestion might work.: put all your images in -hdpi directories and let the system scale them for other densities. It generally does a better job downscaling than upscaling, for obvious reasons, so the results might be acceptable. Note that I haven't tried this, but it seems plausible. String -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: Optimal packaging of image app for various screen resolutions
Android automatically scales images packaged into res/drawable-res to match the actual device density (not sure about persistent caching, though). Therefore, it's not necessary to provide all images at all resolutions. If Android's default scaling works for you in terms of quality and performance, it's enough to just place images into -hdpi (or -xhdpi) and let the framework do the rest. Now, if those are not UI icon type images but rather large, media gallery type images, then yes, Alex's suggestion is a very good one (except I'd use res/drawable-nodpi, to let build tools perform image optimization). -- Kostya 08.02.2011 12:36, JAlexoid (Aleksandr Panzin) пишет: What you can do is put all of the images in the raw directory at high resolution. And on first start scale them and place them into cache(SD card or app's own storage). On 7 фев, 23:28, Johanjohan.pelg...@gmail.com wrote: Hi there, I'm working on an app which displays various images. I want to optimize this for the various screen resolutions. The MultiResolution (1) tutorial uses many resource qualifiers in the res folder to display the appropriate images for the various device resolutions, but how do you package this? I don't want to ship the images for all devices (or do I?). I want to keep the download size as small as possible, so I only want to package the ones for that particular screen resolution. Or, should I forget packaging images and put the images on-line somewhere? Any opinions on this subject would be appreciated (1)http://developer.android.com/resources/samples/MultiResolution/index -- Kostya Vasilyev -- WiFi Manager + pretty widget -- http://kmansoft.wordpress.com -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Optimal packaging of image app for various screen resolutions
Unfortunately, there's no way to avoid duplication with the current architecture, AFAIK. You can sometimes use some redirection to reuse a given image for, say, both -large and -hdpi, but that's about it. In my experience, this is one big reason for APK bloat. Long ago, I submitted a feature request to address this issue ( http://code.google.com/p/android/issues/detail?id=5207), but right now it only has 2 stars and hasn't even been acknowledged by the platform team. String -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: Optimal packaging of image app for various screen resolutions
I thought android automatically resizes images for different screen sizes? Maybe I read that wrong. Assuming the picture is of the right proportion to fill the screen, I thought by using dp instead of pixels it would scale properly up or down depending on size of screen. On Mon, Feb 7, 2011 at 7:48 PM, String sterling.ud...@googlemail.comwrote: Unfortunately, there's no way to avoid duplication with the current architecture, AFAIK. You can sometimes use some redirection to reuse a given image for, say, both -large and -hdpi, but that's about it. In my experience, this is one big reason for APK bloat. Long ago, I submitted a feature request to address this issue ( http://code.google.com/p/android/issues/detail?id=5207), but right now it only has 2 stars and hasn't even been acknowledged by the platform team. String -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: Optimal packaging of image app for various screen resolutions
On Tuesday, February 8, 2011 4:38:25 AM UTC, andjarnic wrote: I thought android automatically resizes images for different screen sizes? It automatically scales for different DENSITIES, not screen sizes, though you can get it to scale for sizes as well if you use the correct attributes (like http://developer.android.com/reference/android/widget/ImageView.ScaleType.html). But in any case, such automated scaling will never be as good in quality as images which are natively the required resolution. String -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Optimal packaging of image app for various screen resolutions
Hi Sterling, Thanks for your answer (and I added a vote to your feature request since it perfectly describes the trouble at hand ;-). So you agree that with an image-heavy app splitting up into various apk's is good practice, but there currently aren't any good tools for it? Hmm... maybe I'll have write my own build scripts with something like AndroidAnt (http://code.google.com/p/autoandroid/wiki/AndroidAnt) or does anybody have another good build-your-own-android-build-script alternative? Cheers, Johan On Feb 8, 4:48 am, String sterling.ud...@googlemail.com wrote: Unfortunately, there's no way to avoid duplication with the current architecture, AFAIK. You can sometimes use some redirection to reuse a given image for, say, both -large and -hdpi, but that's about it. In my experience, this is one big reason for APK bloat. Long ago, I submitted a feature request to address this issue (http://code.google.com/p/android/issues/detail?id=5207), but right now it only has 2 stars and hasn't even been acknowledged by the platform team. String -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en