Godot Version
Godot 4.4.1
Question
I have around 100 meshes (people) that are basically the same, but they each have a different texture. They will not be shown at the same time, maybe 1-3 people at the same time at most.
I was wondering if having a single material with an array of sampler2D textures, and then a per-instance uniform for the index would be ideal or a material for each person would work better.
My question is more in terms of performance, since the target is mobile. I don’t know if having an array of sampler2D textures would make it so that all of them are loaded when the material is loaded, or if the texture at a given index is loaded until it’s actually used.
Each texture is 2048x2048 so it would be awful to load ~100 images at once when the material is loaded. I would test this, but I don’t even know how to test it without creating the 100-textures material, and then what would I even look for (VRAM usage?)
Thank you in advance!