Thanks @Anisoft for answering! Very much appreciated!
maasha yazdı
What do you mean when you say attachment textures? You mean the items/ie layers in a single PNG once you export?
And how could they be interleaved in order?
@maasha I'm sorry I somehow compacted it a bit too much. What I meant is the "texture that an attachment is in".
When your slots (with attachments) are ordered in a particular way from back to front, defining what must be on top, you dictate the required render order.
Let's say you have slots ordered as follows from back to front:
S1, S2, S3, S4, S5
Each of the slots has the following image attachment:
A1, A2, A3, A4, A5
Now imagine that the attachments are packed to atlas page textures as follows:
T1: A1, A3, A5
T2: A2, A4
Now the interleaved texture order example above becomes this:
T1, T2, T1, T2, T1
Now since every change in texture requires a new draw call to begin, you end up with 5 draw calls.
If the attachments were instead packed into a single atlas page texture:
T1: A1, A2, A3, A4, A5
This results it the following texture draw order:
T1, T1, T1, T1, T1
which requires no texture changes, and could be done in a single draw call.
So in short:
[] As @Anisoft pointed out, it is beneficial to have few atlas textures.
[*] If you need multiple, since they don't all fit into one, then it's advisible to group them by draw order (to prevent interleaved attachments from other textures). E.g. this could be one texture with the "base" of a character, which is drawn in the back, and one texture with equipment, which is typically in front.