pixijs / pixi-compressed-textures

Compressed textures and retina support for pixijs. Loader can choose textures depends on platform and rendering mode.
MIT License
93 stars 25 forks source link

Fixing pureExt wrong for file@0.5x.ext due to dot in format specifier #16

Closed adasek closed 6 years ago

adasek commented 6 years ago

I had a problem with half-size textures @0.5x loading. It seems that pureExt determination was improperly splitting the name by the first dot it sees - "texture@0.5x.dds" was returning pureExt string "5x.dds" instead of correct "dds".

I attempt to fix it in the most backward-compatible manner - only removing /@[0-9.]x/ from filename before determining pureExt.

ivanpopelyshev commented 6 years ago

Strange, how did I not notice it before. I worked with @0.5x or may be @.5 resolutions.