Jump to content
  • Advertisement


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



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

What technique can i use for game for creating menu such as in WarCraft III? Any suggestions.

Share this post

Link to post
Share on other sites
Here is what I do. I make a quad that is rendered in ortho mode. I have one texture that I use on the quad.

On the side I have two images, the first has the menu with transparency (A), that is my base menu. I also have another texture with all my buttons text etc... (B)

What I do is A to my texture, and blit on all the buttons etc... from B. If a button is pressed, I blit the pressed button from A into the appropriate rectangle.

But say you render something dynamic, or with transparency etc... If you simply blit on your texture you will see the previous modifications. So if you want to blit to some rect R on your texture, first blit from A using rect R, and then blit from B. This covers up your dirty region with the original menu, and then alows you to replace your button, etc...

You will want to only modify what changes, and only when you need it, as blitting takes a long time if you did it every frame.

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!