Jump to content
  • Advertisement

Archived

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

BobJelly

Using SetStreamSource() to render a lit cube

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

I''m still experimenting with DX8 and I was wondering if it was possible to render a lit cube (ie with normal data, using D3DFVF_NORMAL) using a different vertex buffer for the normals... ? I''m asking this because i would like to render my cube faces using triangle strip and only one call to DrawIndexedPrimitive(). I''ve heard that SetStreamSource() can be used to do this... but maybe i''m wrong... I would have one vertex buffer containing the position information of my 8 points, but i would need another vertex buffer with 24 elements, the normals of each of the 4 points of each faces of my cube... I don''t know if it''s possible...

Share this post


Link to post
Share on other sites
Advertisement
..Unfortunately the answer is no, it''s not currently possible to index the vertex components independently.Even with multiple vertex streams, all streams are indexed together...

(http://msdn.microsoft.com/library/default.asp?URL=/library/techart/DirectX8faq.htm)

Share this post


Link to post
Share on other sites

  • 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!