Jump to content
  • Advertisement
Sign in to follow this  
dimovich

Advanced GDI programming

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

Advertisement
What do you mean if you say "advanced" ? GDI isn´t that complicated really. If you are interested in doing complex user interfaces you might want to have a look at MFC, VCL, qT or anything similiar.

Probably you can find all you need to know about GDI on MSDN. If not, you can surely ask for help on specific topics here.

Share this post


Link to post
Share on other sites
Tricks of the Windows Game Programming Gurus, by Andre LaMothe, has a few chapters on that topic, but quickly switches to DirectX for the rest of the book. Should be able to pick that book up pretty cheap. I think I found it for $15.

Share this post


Link to post
Share on other sites
Hmm... I think I'll stick for now with "Tricks of Win programming Gurus". If I have some questions, I will surely post them here :)...

(If you want to read, and don't feel like spending money, you can download this book, and a few others at: http://rapidshare.de/files/2506351/GameProgramming1.rar.html)

Share this post


Link to post
Share on other sites
Ok. Let me put it another way. I want to do some graphics effects in GDI ( like object burning, motion blur etc. ). I'm sure I can find decent algorithms out there, but how to implement all this as effectively as possible in GDI ?

Share this post


Link to post
Share on other sites
that means software render. gdi will only offer you in this case a canvas to draw onto. you will have to make your own software rendering library. for speed check out mmx and sse instructions.

Share this post


Link to post
Share on other sites
You're probably not gonna find resources explaining how to do those sort of effects using GDI. However the API you use is pretty irrelevant, the technique is what matters, so if you want to do motion blur, go read up on motion blur techniques and work out how to implement one using GDI.

Though GDI isn't exactly renowned for it's speed. I'd suggest dumping it and using something more suitable.

Share this post


Link to post
Share on other sites
Hmm... I'm really concerned about the game size... I try to make it under 100 KB, and I'm not sure I can do this by using OpenGL or DirectX (even DirectDraw). Though I will try. For now, I want to ask you how to make under GDI an effect of fire that gets out of the program window... ? I mean out of the rectangle that you can get with GetWindowRect(...). I know the fire algorithm, but don't know how to draw outside the window.

Share this post


Link to post
Share on other sites
You draw outside the window by getting a global device context, kinda like a screen saver might work. You will have to manage the entire screen in your code, and replace the areas that are overdrawn.

Share this post


Link to post
Share on other sites
Quote:
Original post by dimovich
Hmm... I'm really concerned about the game size... I try to make it under 100 KB, and I'm not sure I can do this by using OpenGL or DirectX (even DirectDraw).
I've got a DX9 and DirectInput 8 framework into 8kb, so I don't see your concerns

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!