I'm not talking about the resource files like .9.png or .xml, but rather image files for icons and backgrounds. Isn't it much easier or more reliable to create a high definition image, put it inside of the nodpi folder, and then use properties like fitXY to fit the image inside a given space? Why go through all the trouble of creating a scaled version for mdpi, hdpi, xdpi, etc?
Supported file types are PNG (preferred), JPG (acceptable), and GIF (discouraged).
nodpi : Resources for all densities. These are density-independent resources. The system does not scale resources tagged with this qualifier, regardless of the current screen's density.
An object used to create frame-by-frame animations, defined by a series of Drawable objects, which can be used as a View object's background. ClipDrawable. A Drawable that clips another Drawable based on this Drawable's current level value.
Scaling down a large image to a smaller one before using it as an ImageView's source is more computationally expensive than being able to pull a properly sized one from a proper DPI bucket.
While it may be easier to slap your resources into a single drawable folder and call it good, it will cause performance issues when rendering assets on lower DPI devices, which tend to have less powerful CPUs anyway.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With