Jump to content
  • Advertisement
Sign in to follow this  
Ben091986

how to remove Texture after SetTexture

This topic is 3869 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

Hi folks, I draw some primitives with texture xyz.bmp after that i want to draw some without texture coords and they will appear black. How can I remove the affect of SetTexture after i have drawn something. Like
 
    d3ddev->Clear(0, NULL, D3DCLEAR_TARGET, D3DCOLOR_XRGB(0, 0, 0), 1.0f, 0);
    d3ddev->BeginScene();
     
    SetTexture ...
    drawSome Triangles from Vertex 1
    ... remove texture <-- what is that functions name ??
    change streamressource and vertexformat
    draw another triangle Vertex 2
   
    d3ddev->EndScene();    


Vertex 1 is XYZ, color and texture Vertex 2 is XYZ and color If i do not set the texture, then my second triangle will be drawn correctly, but my first looks really ugly If i set the texture, then the first one is okay, but the second one is just black. I did not find any suitable help via google. I think it could be something like setRenderstate(USE_TEXTURE,FALSE) or so ...but i did not find something like that

Share this post


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

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!