Jump to content
  • Advertisement


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


Help with 2D in 3D using DirectX 8

This topic is 6117 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 hope someone out there has run into this problem, and can give me a hand. I made a very basic 3D engine in DirectX 8 (Visual C). I now want to create HUD''s Menu boxes and displays, and have failed pretty bad so far. My three methods: 1. Try to get sprite''s to display as if the screen is a 2D area. 2. Try to arrange a 6-vertex Plane plane To always be infront of camera. 3. Trying to use BillBoard, at exactly .1 distance from camera. I can''t get sprites to even appear, The planes mat is always getting screwed up when the camera starts to turn in a complex matter. Finally Billboard I had the most success with, It just gets awkward in scaling situations. Has anyone found a better way that they are willing to share, or got one of the methods I''m try to use to work very nicely? Thank for any assistance you can give.

Share this post

Link to post
Share on other sites
Read the 2D article on this site.

The short story - don''t try to align the HUD as a billboard in front of the camera. Do this:

Draw 3D stuff
Switch to ortho matrix
Draw 2D stuff (as 2D, not billboarded 3D)
Switch back to 3D proj. matrix

rinse and 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!