switching between wireframe and texture rendering in dx8

Started by
1 comment, last by Zoney 22 years, 5 months ago
I have this d3d application that renders a simple terrain using the wireframe fill mode, and then I wanted to add som text for displaying data to render text I use textured tringlestrips so I had to change many render states when rendering the text but I figured as long as I changed every one back it wouldn''t be any problem but after I call the IDirect3DDevice8::SetTexture to set my font texture the terrain gets all screwed up and looks more like a collection of blinking dots do I have to reset the texture or something?
"If there was no god, it would be necessary to invent one" - Voltaire
Advertisement
You need to do

      DXDisplay->SetTexture( 0, NULL);  


This sets DX to use no texture, otherwise your wireframe mesh will be textured with the font texture (last texture set). Which is why it looks all weird!

[The views stated herein do not necessarily represent the view of the company Eurocom ]

Eurocom Entertainment Software
www.Eurocom.co.uk

The Jackal

Edited by - Mark Duffill on November 22, 2001 8:28:46 AM

Edited by - Mark Duffill on November 22, 2001 8:29:35 AM
hey, thanks!
worked great. why didn''t I think of that?
"If there was no god, it would be necessary to invent one" - Voltaire

This topic is closed to new replies.

Advertisement