Jump to content
  • Advertisement
Sign in to follow this  
zethon

Direct3D & Windows Common Controls

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

Hello, I'm fairly new to DirectX but not at all new to Win32. I'd like to use a regular windows common control on my Direct3D surface. I can use CreateWindowEx just fine to create my control, but I can't figure out how to get my Direct3D scene to stop rendering over top of it. How can this be done? I was thinking that maybe I could have the part of the screen where the common control (an edit box) is not be rendered. In Win32/MFC there are regions which you can define not to be drawn -- is there any such thing in DirectX? Or is there a better way to do this?

Share this post


Link to post
Share on other sites
Advertisement
I think you could draw a quad where you want the windows controls into the stencil buffer, then configure DX to draw only outside of the stencil buffer, so nothing will be drawn over that quad where you draw the windows control. I don't know for sure, but you might could draw the windows control itself to the stencil buffer somehow, but I couldn't tell you how. I use OpenGL, and I don't think you can use windows controls over that, but the stencil buffer stuff works the same.

Share this post


Link to post
Share on other sites
You could use siccor rects, thats a lot easier than then using stencil buffers!
I also believe you can tell directx to use win32 GDI controls on a buffer...
But I'd have to dive into that,..

GBS

Share this post


Link to post
Share on other sites

This topic is 4861 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.

Guest
This topic is now closed to further replies.
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!