Jump to content
  • Advertisement

Archived

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

nickwinters

Trouble with designing graphics output

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

The initial design of the program I''m writing is that the user can use an add function that passes an array of vertices, and and array of ints which will be put into an index buffer. All the code works fine, until I notices these two lines in sample code: device.SetStreamSource(0, vb, 0); device.indeces=ib; Does this mean every time I paint the screen, I can only have one vertex buffer, and one index buffer? Or is there a way where I can create a new vertex and index buffer everytime my add function is called, and they''ll all be drawn when paint is called? Thanks. -Nick

Share this post


Link to post
Share on other sites
Advertisement
''basically'' you get one vb to use at a time although you can have another stream that your vshader might use. Just create the VBs ahead of time and during rendering, loop through them, setting the device''s stream to each, render, repeat.

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!