Android devices GL_MAX_TEXTURE_SIZE restriction, safe texture size

I work with AndEngine and OpenGL ES 2.0. I continue to read about GL_MAX_TEXTURE_SIZE and how I should store my texts under 1024x1024 . I started to make mistakes before and when using tile sets in the TMX extension (it doesn't really matter what it is if you don't know AndEngine), I get a tile that makes the texture wider than 1024px . I am thinking of dividing the tiles into two parts, which makes them "safe." But I can’t find any device released in the last couple of years that has this limit set to 2048x2048 . Is there a list or website that I can use to filter devices on GL_MAX_TEXTURE_SIZE ?


I read the following questions:

And I used this site to search for devices. But I can’t search on / filter GL_MAX_TEXTURE_SIZE , which makes the search tedious. I ask mainly because I started to make mistakes, this is a hobby project, and the amount of work may be too large compared to the number of possible devices that will be turned on (I expect 0 ).

+6
source share
2 answers

1024x1024 is the safest thing you can use on any device, especially old ones. The new devices should not have any problems, although I saw the latest devices (I remember that the Galaxy Nexus, the latest fixed ICS update, which nonetheless fixes this), displays white squares with texture sizes of 2048x1024.

If you target new devices and want older versions to be compatible, this should not damage the separation of your datasets. After all, you are unlikely to use too many context switches if you use two or three sprites for the background, etc.

+6
source

If you still have separate image files, splitting them into small atlases or custom atlases is easy if you use the TexturePacker2 tool from the LibGdx library.

I don’t know the exact limitation of the devices, but it’s always better to consider the lowest end of the device you want to support and build up from there. Using the LibGdx tool, you can easily change your mind later, so this is the most flexible solution.

Take a look: LibGdx TexturePacker

+1
source

Source: https://habr.com/ru/post/946559/


All Articles