What if all resources are placed in one resolution for android app bundle












3















As we all know that Google launch new feature of distributing android apk using android-app-bundle that has so many advantages.



So my question is, how my app will behave if I place all the images/resources in single folder like drawable-xxxhdpi. e.g. Lets say I have one application that uses 5 images. Instead of taking different sizes for different resolutions, I place all the images in single folder (drawable-xxxhdpi) assuming lets android handle it based on device resolution.



As we know that android-app-bundle generates different different apks based on resolutions, languages and so on.



So in that case what will happen to my app ? How APKs will be generated for different resolutions (Android itself re-scales images and generates bundle ?) What will happen to app, will it crash or working properly for smaller resolution devices ?



I know this is non- coding question but its technical question. I tried to search for this but not able to find exact answer of it.



I may help to others as well.










share|improve this question



























    3















    As we all know that Google launch new feature of distributing android apk using android-app-bundle that has so many advantages.



    So my question is, how my app will behave if I place all the images/resources in single folder like drawable-xxxhdpi. e.g. Lets say I have one application that uses 5 images. Instead of taking different sizes for different resolutions, I place all the images in single folder (drawable-xxxhdpi) assuming lets android handle it based on device resolution.



    As we know that android-app-bundle generates different different apks based on resolutions, languages and so on.



    So in that case what will happen to my app ? How APKs will be generated for different resolutions (Android itself re-scales images and generates bundle ?) What will happen to app, will it crash or working properly for smaller resolution devices ?



    I know this is non- coding question but its technical question. I tried to search for this but not able to find exact answer of it.



    I may help to others as well.










    share|improve this question

























      3












      3








      3








      As we all know that Google launch new feature of distributing android apk using android-app-bundle that has so many advantages.



      So my question is, how my app will behave if I place all the images/resources in single folder like drawable-xxxhdpi. e.g. Lets say I have one application that uses 5 images. Instead of taking different sizes for different resolutions, I place all the images in single folder (drawable-xxxhdpi) assuming lets android handle it based on device resolution.



      As we know that android-app-bundle generates different different apks based on resolutions, languages and so on.



      So in that case what will happen to my app ? How APKs will be generated for different resolutions (Android itself re-scales images and generates bundle ?) What will happen to app, will it crash or working properly for smaller resolution devices ?



      I know this is non- coding question but its technical question. I tried to search for this but not able to find exact answer of it.



      I may help to others as well.










      share|improve this question














      As we all know that Google launch new feature of distributing android apk using android-app-bundle that has so many advantages.



      So my question is, how my app will behave if I place all the images/resources in single folder like drawable-xxxhdpi. e.g. Lets say I have one application that uses 5 images. Instead of taking different sizes for different resolutions, I place all the images in single folder (drawable-xxxhdpi) assuming lets android handle it based on device resolution.



      As we know that android-app-bundle generates different different apks based on resolutions, languages and so on.



      So in that case what will happen to my app ? How APKs will be generated for different resolutions (Android itself re-scales images and generates bundle ?) What will happen to app, will it crash or working properly for smaller resolution devices ?



      I know this is non- coding question but its technical question. I tried to search for this but not able to find exact answer of it.



      I may help to others as well.







      android android-app-bundle






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Nov 20 '18 at 8:43









      SmeetSmeet

      2,0782028




      2,0782028
























          3 Answers
          3






          active

          oldest

          votes


















          2














          Your app will work the same as before: Play serves to a given device the files that the Android platform would have loaded if it had served the APK with all the files.



          In other words, if an mdpi device would have loaded the resource res/drawable-xxxhdpi/icon.png, then that's what Play will serve to that device.



          --



          Also, slightly unrelated to your question, but note that there are some downsides to providing resources only in xxxhdpi (regardless of whether you publish an APK or an Android AppBundle):




          1. The Android platform will have to rescale these images at runtime on lower resolution devices, thus taking some CPU time and making your app slightly slower.


          2. Your app is bigger than it could be on lower resolution devices. If you provided also the same resource in mdpi, it would obviously be smaller, and that's what Play would serve to an mdpi device, thus making your app smaller for those devices.







          share|improve this answer



















          • 1





            Thank you for your quick response. As you are saying that resources are rescaled at runtime, when play is generating apk for mdpi device, how play will generate apk based on different resolution/resource devices like mdpi? Then there will be no any benefit of app bundle as higher resolution image is being included in app bundle as well ?

            – Smeet
            Nov 20 '18 at 10:07











          • Play does not create new files today, so it will serve the xxxhdpi resource (in our example) to all devices. If you want to avoid the rescaling, you need to include the PNG resources for each dpi, then Play will serve the right resource to the right device.

            – Pierre
            Nov 20 '18 at 13:40



















          0














          Good and very helpful question, I think your application will work fine on xxxhdpi devices but those devices which are mdpi or hdpi will face layout issues. I don't think so there would be any other issue than this.






          share|improve this answer































            0














            Resource not found exception will be triggered in devices with lower resolutions






            share|improve this answer























              Your Answer






              StackExchange.ifUsing("editor", function () {
              StackExchange.using("externalEditor", function () {
              StackExchange.using("snippets", function () {
              StackExchange.snippets.init();
              });
              });
              }, "code-snippets");

              StackExchange.ready(function() {
              var channelOptions = {
              tags: "".split(" "),
              id: "1"
              };
              initTagRenderer("".split(" "), "".split(" "), channelOptions);

              StackExchange.using("externalEditor", function() {
              // Have to fire editor after snippets, if snippets enabled
              if (StackExchange.settings.snippets.snippetsEnabled) {
              StackExchange.using("snippets", function() {
              createEditor();
              });
              }
              else {
              createEditor();
              }
              });

              function createEditor() {
              StackExchange.prepareEditor({
              heartbeatType: 'answer',
              autoActivateHeartbeat: false,
              convertImagesToLinks: true,
              noModals: true,
              showLowRepImageUploadWarning: true,
              reputationToPostImages: 10,
              bindNavPrevention: true,
              postfix: "",
              imageUploader: {
              brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
              contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
              allowUrls: true
              },
              onDemand: true,
              discardSelector: ".discard-answer"
              ,immediatelyShowMarkdownHelp:true
              });


              }
              });














              draft saved

              draft discarded


















              StackExchange.ready(
              function () {
              StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53389150%2fwhat-if-all-resources-are-placed-in-one-resolution-for-android-app-bundle%23new-answer', 'question_page');
              }
              );

              Post as a guest















              Required, but never shown

























              3 Answers
              3






              active

              oldest

              votes








              3 Answers
              3






              active

              oldest

              votes









              active

              oldest

              votes






              active

              oldest

              votes









              2














              Your app will work the same as before: Play serves to a given device the files that the Android platform would have loaded if it had served the APK with all the files.



              In other words, if an mdpi device would have loaded the resource res/drawable-xxxhdpi/icon.png, then that's what Play will serve to that device.



              --



              Also, slightly unrelated to your question, but note that there are some downsides to providing resources only in xxxhdpi (regardless of whether you publish an APK or an Android AppBundle):




              1. The Android platform will have to rescale these images at runtime on lower resolution devices, thus taking some CPU time and making your app slightly slower.


              2. Your app is bigger than it could be on lower resolution devices. If you provided also the same resource in mdpi, it would obviously be smaller, and that's what Play would serve to an mdpi device, thus making your app smaller for those devices.







              share|improve this answer



















              • 1





                Thank you for your quick response. As you are saying that resources are rescaled at runtime, when play is generating apk for mdpi device, how play will generate apk based on different resolution/resource devices like mdpi? Then there will be no any benefit of app bundle as higher resolution image is being included in app bundle as well ?

                – Smeet
                Nov 20 '18 at 10:07











              • Play does not create new files today, so it will serve the xxxhdpi resource (in our example) to all devices. If you want to avoid the rescaling, you need to include the PNG resources for each dpi, then Play will serve the right resource to the right device.

                – Pierre
                Nov 20 '18 at 13:40
















              2














              Your app will work the same as before: Play serves to a given device the files that the Android platform would have loaded if it had served the APK with all the files.



              In other words, if an mdpi device would have loaded the resource res/drawable-xxxhdpi/icon.png, then that's what Play will serve to that device.



              --



              Also, slightly unrelated to your question, but note that there are some downsides to providing resources only in xxxhdpi (regardless of whether you publish an APK or an Android AppBundle):




              1. The Android platform will have to rescale these images at runtime on lower resolution devices, thus taking some CPU time and making your app slightly slower.


              2. Your app is bigger than it could be on lower resolution devices. If you provided also the same resource in mdpi, it would obviously be smaller, and that's what Play would serve to an mdpi device, thus making your app smaller for those devices.







              share|improve this answer



















              • 1





                Thank you for your quick response. As you are saying that resources are rescaled at runtime, when play is generating apk for mdpi device, how play will generate apk based on different resolution/resource devices like mdpi? Then there will be no any benefit of app bundle as higher resolution image is being included in app bundle as well ?

                – Smeet
                Nov 20 '18 at 10:07











              • Play does not create new files today, so it will serve the xxxhdpi resource (in our example) to all devices. If you want to avoid the rescaling, you need to include the PNG resources for each dpi, then Play will serve the right resource to the right device.

                – Pierre
                Nov 20 '18 at 13:40














              2












              2








              2







              Your app will work the same as before: Play serves to a given device the files that the Android platform would have loaded if it had served the APK with all the files.



              In other words, if an mdpi device would have loaded the resource res/drawable-xxxhdpi/icon.png, then that's what Play will serve to that device.



              --



              Also, slightly unrelated to your question, but note that there are some downsides to providing resources only in xxxhdpi (regardless of whether you publish an APK or an Android AppBundle):




              1. The Android platform will have to rescale these images at runtime on lower resolution devices, thus taking some CPU time and making your app slightly slower.


              2. Your app is bigger than it could be on lower resolution devices. If you provided also the same resource in mdpi, it would obviously be smaller, and that's what Play would serve to an mdpi device, thus making your app smaller for those devices.







              share|improve this answer













              Your app will work the same as before: Play serves to a given device the files that the Android platform would have loaded if it had served the APK with all the files.



              In other words, if an mdpi device would have loaded the resource res/drawable-xxxhdpi/icon.png, then that's what Play will serve to that device.



              --



              Also, slightly unrelated to your question, but note that there are some downsides to providing resources only in xxxhdpi (regardless of whether you publish an APK or an Android AppBundle):




              1. The Android platform will have to rescale these images at runtime on lower resolution devices, thus taking some CPU time and making your app slightly slower.


              2. Your app is bigger than it could be on lower resolution devices. If you provided also the same resource in mdpi, it would obviously be smaller, and that's what Play would serve to an mdpi device, thus making your app smaller for those devices.








              share|improve this answer












              share|improve this answer



              share|improve this answer










              answered Nov 20 '18 at 9:46









              PierrePierre

              1,976168




              1,976168








              • 1





                Thank you for your quick response. As you are saying that resources are rescaled at runtime, when play is generating apk for mdpi device, how play will generate apk based on different resolution/resource devices like mdpi? Then there will be no any benefit of app bundle as higher resolution image is being included in app bundle as well ?

                – Smeet
                Nov 20 '18 at 10:07











              • Play does not create new files today, so it will serve the xxxhdpi resource (in our example) to all devices. If you want to avoid the rescaling, you need to include the PNG resources for each dpi, then Play will serve the right resource to the right device.

                – Pierre
                Nov 20 '18 at 13:40














              • 1





                Thank you for your quick response. As you are saying that resources are rescaled at runtime, when play is generating apk for mdpi device, how play will generate apk based on different resolution/resource devices like mdpi? Then there will be no any benefit of app bundle as higher resolution image is being included in app bundle as well ?

                – Smeet
                Nov 20 '18 at 10:07











              • Play does not create new files today, so it will serve the xxxhdpi resource (in our example) to all devices. If you want to avoid the rescaling, you need to include the PNG resources for each dpi, then Play will serve the right resource to the right device.

                – Pierre
                Nov 20 '18 at 13:40








              1




              1





              Thank you for your quick response. As you are saying that resources are rescaled at runtime, when play is generating apk for mdpi device, how play will generate apk based on different resolution/resource devices like mdpi? Then there will be no any benefit of app bundle as higher resolution image is being included in app bundle as well ?

              – Smeet
              Nov 20 '18 at 10:07





              Thank you for your quick response. As you are saying that resources are rescaled at runtime, when play is generating apk for mdpi device, how play will generate apk based on different resolution/resource devices like mdpi? Then there will be no any benefit of app bundle as higher resolution image is being included in app bundle as well ?

              – Smeet
              Nov 20 '18 at 10:07













              Play does not create new files today, so it will serve the xxxhdpi resource (in our example) to all devices. If you want to avoid the rescaling, you need to include the PNG resources for each dpi, then Play will serve the right resource to the right device.

              – Pierre
              Nov 20 '18 at 13:40





              Play does not create new files today, so it will serve the xxxhdpi resource (in our example) to all devices. If you want to avoid the rescaling, you need to include the PNG resources for each dpi, then Play will serve the right resource to the right device.

              – Pierre
              Nov 20 '18 at 13:40













              0














              Good and very helpful question, I think your application will work fine on xxxhdpi devices but those devices which are mdpi or hdpi will face layout issues. I don't think so there would be any other issue than this.






              share|improve this answer




























                0














                Good and very helpful question, I think your application will work fine on xxxhdpi devices but those devices which are mdpi or hdpi will face layout issues. I don't think so there would be any other issue than this.






                share|improve this answer


























                  0












                  0








                  0







                  Good and very helpful question, I think your application will work fine on xxxhdpi devices but those devices which are mdpi or hdpi will face layout issues. I don't think so there would be any other issue than this.






                  share|improve this answer













                  Good and very helpful question, I think your application will work fine on xxxhdpi devices but those devices which are mdpi or hdpi will face layout issues. I don't think so there would be any other issue than this.







                  share|improve this answer












                  share|improve this answer



                  share|improve this answer










                  answered Nov 20 '18 at 8:48









                  Taha wakeelTaha wakeel

                  896




                  896























                      0














                      Resource not found exception will be triggered in devices with lower resolutions






                      share|improve this answer




























                        0














                        Resource not found exception will be triggered in devices with lower resolutions






                        share|improve this answer


























                          0












                          0








                          0







                          Resource not found exception will be triggered in devices with lower resolutions






                          share|improve this answer













                          Resource not found exception will be triggered in devices with lower resolutions







                          share|improve this answer












                          share|improve this answer



                          share|improve this answer










                          answered Dec 14 '18 at 16:47









                          SimonSimon

                          588619




                          588619






























                              draft saved

                              draft discarded




















































                              Thanks for contributing an answer to Stack Overflow!


                              • Please be sure to answer the question. Provide details and share your research!

                              But avoid



                              • Asking for help, clarification, or responding to other answers.

                              • Making statements based on opinion; back them up with references or personal experience.


                              To learn more, see our tips on writing great answers.




                              draft saved


                              draft discarded














                              StackExchange.ready(
                              function () {
                              StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53389150%2fwhat-if-all-resources-are-placed-in-one-resolution-for-android-app-bundle%23new-answer', 'question_page');
                              }
                              );

                              Post as a guest















                              Required, but never shown





















































                              Required, but never shown














                              Required, but never shown












                              Required, but never shown







                              Required, but never shown

































                              Required, but never shown














                              Required, but never shown












                              Required, but never shown







                              Required, but never shown







                              Popular posts from this blog

                              Guess what letter conforming each word

                              Port of Spain

                              Run scheduled task as local user group (not BUILTIN)