Dividing Texture 2D

Hi,

I heard that if I put all the texture 2D into one big texture 2D and dividing them would make it faster since it's only one draw call. If so, how can I divide one Texture 2D into multiple Texture2Ds?

Thank you very much.

there are 3 ways to do that. 1 atlas textures. 2 using getpixels and setpixels 3 use one texture for all models the second way is not fast because you need to create new textures and set their pixels but the first way is actually faster. before describing it i should say it's not always a good idea to pack all textures together. you should pack those ones that they are visible together or always visible. see the optimization video of unite 07 to find out more. joachin ante describe things well for you

now let's see how to pack textures together and how to use them. you should use this function to pack textures and then it will return an array of floats that tell you the position of each texture. you can use getpixels and setpixels methods of Texture2D to get them and set other textures to them. the third way is what you want most of the times. use a big texture containing all textures in your modeler and in UV mapping just map those parts that you want. then in unity you can use one texture for all of the models materials. let's say you have a car and a cycle and you have a big texture of a car and a cycle. in your modeler (max, maya etc) map the car parts of the texture to your car and the cycle parts to the cycle. then in unity use the same texture for both materials.