Hello all!
I’m utilizing Cocos Creator model 3.8.8.
The construct will probably be completed for the next platforms: web-desktop, web-mobile and Android (probably additionally iOS). Mainly, I need to help a variety of gadgets. This raises a number of questions:
What’s the most texture decision I ought to use? I can’t resolve between 2048×2048 and 4096×4096. It looks like 4096×4096 ought to theoretically work in every single place, however the suggestion within the Phaser.js documentation is alarming:
2048px for cell and 4096px for desktop ought to be protected.
Does the feel measurement essentially need to be an influence of two? So far as I perceive, this isn’t crucial, however fascinating for higher efficiency.
Ought to the feel be sq.? So far as I perceive, the edges wouldn’t have to be the identical measurement and this doesn’t have an effect on efficiency.
Normally, I actually have at all times leaned in the direction of 2048×2048 as the utmost texture measurement (nevertheless, on this undertaking I used to be given very giant textures).
For initiatives focusing on net, Android, and iOS, I typically deal with 2048×2048 because the most secure default most texture measurement, particularly if compatibility with older or mid-range cell gadgets is necessary. Whereas many trendy GPUs help 4096×4096, bigger textures improve reminiscence utilization and will negatively have an effect on loading occasions or efficiency on lower-end {hardware}. Cocos builders have additionally famous that sticking to 4096 or under is the safer alternative for Internet, relying on the goal platform.
Relating to the opposite questions, power-of-two (POT) textures are now not a strict requirement on trendy {hardware}, however they’ll nonetheless provide higher compatibility and are helpful for options like mipmaps and texture compression. Non-square textures are additionally completely acceptable, supplied the size are acceptable for the content material. General, I’d optimize textures based mostly on their precise on-screen measurement fairly than at all times utilizing the very best potential decision.

