multiple uv coords in .x file?
hey guys
I want to single-pass multitexture a .x mesh using a different set of uv coordinates than that mesh defines. the goal of this is to eliminate the illusion of tiling. how could i go about drawing my second texture this way? i don't see how =/ is there a better way to multitexture?
-Sean
I had the same problem when i was working with lightmaps...create another vertex definition that includes the secondary uv channel, something like this:
then clone your mesh using this fvf and fill the texture coords :)
struct VERT{ D3DVECTOR pos; D3DVECTOR normal; float u, v; float u2, v2; };#define MESH_FVF (D3DFVF_XYZ | D3DFVF_TEX1 | D3DFVF_TEX2 | D3DFVF_NORMAL)
then clone your mesh using this fvf and fill the texture coords :)
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement