View Full Version : well i ask again is directdraw and opengl usable together

Starnut coder
01-18-2001, 02:13 AM
I want to run directdraw and opengl at the same time.
I managed this with opengl and directinput but is directdraw also ok.
I want to use ddraw for menus , maps, toolbars etc.
Does anybody know a way of doing this

01-18-2001, 08:30 AM

01-18-2001, 11:48 AM

My understanding is that you can mix the two, but it isn't moral.

If your only interest in DirectDraw is for 2D interfacing, then you should either:
1) Use Win32 or MFC for 2D interface management and use OpenGL in a window


2) Render your 3D scene, then change to an orthographic projection and render your 2D elements.

If standard 'windows' decorations are all you need, then the Win32/MFC solution is the way to go. If you need more 'artistic' decorations, then go with the OpenGL solution.

Oh... and keep the two systems as seperate as possible either way so that you can use one or the other component in a seperate project without pain :)

Have fun
-- Jeff

Starnut coder
01-18-2001, 08:18 PM
Im want to use directdraw only for 2d but on top of the opengl window. Its not allowed to be a window since im making a game.
now did i understand correctly that i must first draw the opnengl scene, then get rid of opengl initialize directdraw and use directdraw?
Is there no way to use both at the same time simulatiosly?

Starnut coder
01-18-2001, 08:21 PM
Oh and if i switch to ortho2d mode is Directdraw usable then?

01-19-2001, 02:20 AM
read the faq (link on the first page)

01-19-2001, 03:30 AM
Why don't u simply render to a DIB (also without using MFC if you want) and just use the DIB data with CopyPixels (slow) or as a texture for billboarding ??

Isn't it simplier and cleaner ??