luke2012 Well-Known Member Licensed User Longtime User Aug 8, 2017 #1 The designer is very useful to set an image file with a couple of clicks (I always use this). But when the need is to support several image resolution for several screen size and dpi is it better to use the drawable_ldpi / ... approach ? In this case I can't set this within the current designer right ? I must use the code approach ? Thanks in advance for your reply.
The designer is very useful to set an image file with a couple of clicks (I always use this). But when the need is to support several image resolution for several screen size and dpi is it better to use the drawable_ldpi / ... approach ? In this case I can't set this within the current designer right ? I must use the code approach ? Thanks in advance for your reply.
Eme Fibonacci Well-Known Member Licensed User Longtime User Aug 8, 2017 #2 I understand your problem. I'll follow the topic to see the best solution. I think it would be useful to have access to something like this in the script: Code: Copy ImageView1.Bitmap = LoadBitmap (File.DirAssets, "resolution1\someimage.jpg") ... ImageView1.Bitmap = LoadBitmap (File.DirAssets, "resolution2\someimage.jpg") Maybe this can not be implemented. I created an imagegallery class and I have several icons in it. The icons are initialized depending on the resolution of the device. I believe that for large images this is not a good solution. Upvote 0
I understand your problem. I'll follow the topic to see the best solution. I think it would be useful to have access to something like this in the script: Code: Copy ImageView1.Bitmap = LoadBitmap (File.DirAssets, "resolution1\someimage.jpg") ... ImageView1.Bitmap = LoadBitmap (File.DirAssets, "resolution2\someimage.jpg") Maybe this can not be implemented. I created an imagegallery class and I have several icons in it. The icons are initialized depending on the resolution of the device. I believe that for large images this is not a good solution.
Erel B4X founder Staff member Licensed User Longtime User Aug 9, 2017 #3 If the gravity is set to FILL then in most cases you can use a high resolution image and it will look good on all devices. Upvote 0
If the gravity is set to FILL then in most cases you can use a high resolution image and it will look good on all devices.