Which texture compression will give the fastest loading speeds?

Hi Guys,

I’m currently working on a project where we are experiencing slow scene changing on android. I have tried multiple solutions and work arounds for this problem but none have worked

I have come to conclusion that the textures in our project is biggest factor in the slow loading speeds and have been looking into multiple ways of speeding this up. So just wondering what compression format in unity will give the best quality and fastest loading speeds?

I have also come across this in unity’s best practices
“Unity takes care of compression for the output platform, so unless your source is already a JPG of the correct resolution it’s better to use a lossless format for your textures.”

We can technically use jpgs of the correct resolution but if I understand how unity works i’m not too sure how this is beneficial and if I can use jpgs of the correct resolution will this help with faster loading speeds?

Hi

In the drop down box for texture compression a rough guide is that lowest quality / smallest size at the top with the highest quality / largest size at the bottom. Using lower quality or smaller textures will improve loading times - its that simple.

This link is very handy - check out the texture section which tells you all about reducing the size of textures:

The ‘bpp’ value is the key - the smaller the better for load times. The ‘max size’ is useful as it allows you to turn down the texture resolution that gets used by unity without modifying your source asset.

The really simple rule is to use compressed textures that are as small as possible. A good guideline for texture sizes is that they shouldn’t contain more pixels than will be used on screen. For example, if a texture is unlikely to ever take up more than 128x128 pixels on screen, there’s no point in it being 256x256.

Mip-maps also take extra memory. They’re great for 3D stuff to save performance when objects are further away (so need a lower resolution texture). However for UI rendering they’re fairly pointless, as you should just be aiming to make textures that are the resolution they’ll be used at in the UI.

Just in case you weren’t aware, ‘compression’ isn’t like jpg or zip compression - the files are not ‘decompressed’ on load. They are texture compression formats that the GPU understands, so the compressed texture is directly read into memory and sent to the GPU for rendering. Hence a smaller texture generally improves disk usage, load times, and can even improve performance due to lower use of memory bandwidth.

Hope that helps!

-Chris

It doesn’t matter what texture format you use, Unity will read the textures in any supported format and then build them again. The texture format inside Unity’s binary files is something you can not choose.

You should try setting texture properties in the editor, for instance, reduce Max Size. You should also try to reduce texture number using atlases.

59246-texture-properties.png

Also, check this: Reducing the File Size of the Build