• Advertisement

Archived

This topic is now archived and is closed to further replies.

Using pre-lit vertices in D3D 7

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

Advertisement
I want to draw triangles that consist of D3DLVERTEX'es (pre-lit but untransformed). I'm having problems with lighting, I can't draw triangles with different colored vertices (whole triangle will be gouraud shaded with those colors, of course). Only color applied to triangles is ambient lighting color. If it's 0, the triangle is black.

I've tried to assign different values and 0's to different lighting settings (material, ambient, vertex diffuse and specular). I'm using D3DFVF_LVERTEX as vertex type when calling DrawPrimitive(), is that ok?

Strange thing is I can draw triangles with per-vertex lighting with D3DLTVERTEX'es but I don't want to do transformations myself. Please help!

------------------
"Tank, I need an exit. Fast!"

Share this post


Link to post
Share on other sites
Thank you! I was instead checking it was TRUE ;D

------------------
"Tank, I need an exit. Fast!"

Share this post


Link to post
Share on other sites

  • Advertisement