Jump to content
  • Advertisement

Archived

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

AndyM

Thick 3D Lines - fast

This topic is 5621 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 using DX8.1 and want to draw lines in 3D, but with >1 thickness. I think OpenGL has support for doing this - does DX 9.0 add support for this? I can do it in 8.1 by projecting the start and end points into 2D space (I use a D3DX function) and then using the line''s vector to calculate 4 corner points to draw a thick line (2polys/quad), but this is probably not so fast and if I wanted to properly join two lines to each other things get complicated. Drawing a long 3D box might be just as fast...

Share this post


Link to post
Share on other sites
Advertisement
Drawing 2-triangle quads is about the fastest way to do this, and is indeed the way OpenGL and most graphics chips achieve thick lines!

Check out the ID3DXLine stuff which does all the quad construction stuff for you.

--
Simon O''Connor
Creative Asylum Ltd
www.creative-asylum.com

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!