Drawing interleaved arrays with multiple textures

Discuss the development of new homebrew software, tools and libraries.

Moderators: cheriff, TyRaNiD

Post Reply
masterlodi
Posts: 11
Joined: Sat Mar 04, 2006 9:35 pm

Drawing interleaved arrays with multiple textures

Post by masterlodi »

I'm using interleaved arrays to draw a box (made of triangles) using sceGumDrawArray. It all works great.

I'm setting the texture with sceGuTexImage but I need to texture each side of the box using different texture images though, how can I do this?
User avatar
Raphael
Posts: 646
Joined: Tue Jan 17, 2006 4:54 pm
Location: Germany
Contact:

Post by Raphael »

Order your triangles by texture, then set a texture and draw all triangles of that side, set the next texture and draw the next side, etc.

For this you might need to change your mesh structure though.
masterlodi
Posts: 11
Joined: Sat Mar 04, 2006 9:35 pm

Post by masterlodi »

Right, that's simple enough.

Are there any samples of loading textures for use with sceGuTexImage? I don't want to export my textures to .raw or C strings?!
Post Reply