Jump to content
  • Advertisement
Sign in to follow this  
lordimmortal2

Getting Text to Render in Front of Sprites

This topic is 2539 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've been trying to make a 2D game that utilizes both sprites and text, and I haven't been able to get text to render in front of the sprites so you can actually see it. I've searched for an answer on Google, but the one thread I saw that pertained to this was too confusing for me.

Is there an easy way to render text in front of sprites? I am using DirectX.

As always, any replies and help is appreciated.

Share this post


Link to post
Share on other sites
Advertisement

If it's not hardware sprites then render the sprites first, then the text.


He is right, in addition, depending on what technology you use to do the rendering, you might also need to disable depth test before rendering the text

Share this post


Link to post
Share on other sites
Oh pfft. Can't believe I didn't mention I was using DirectX >.<. Sorry about that. I was reading that you could disable z-buffering to draw things in the order you specify but it seemed kind of a crude way to do it. Is that the only way to do and also how exactly would you disable the z-buffer?

Share this post


Link to post
Share on other sites
Sign in to follow this  

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