• Advertisement
Sign in to follow this  

D3DX API and textures

This topic is 3679 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hello I can load static x files with pure directx and set texture using the device see: var ... TextureName: IDirect3DTexture9; with the function D3DXLoadTextureFromFile I can load it, and using the device... Direct3DDevice.SetTexture(0, TextureName); and to set the texture in other static .x file I'm using here: Direct3DDevice.SetTexture(0, nil); and after I'm using the same process again: Direct3DDevice.SetTexture(0, OtherTextureName); What is the best way to apply texture? Greets

Share this post


Link to post
Share on other sites
Advertisement
Provide texture info in your vertex :

struct Vertex
{
D3DXVECTOR3 Position; //x,y,z coords
float tu,tv; //Texture Coords for mapping
};

For a better idea, try
http://www.chadvernon.com/blog/tutorials/directx9/texture-mapping/

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement