Jump to content

  • Log In with Google      Sign In   
  • Create Account


How to make DirectDraw work with OpenGL?


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
8 replies to this topic

#1 ayden   Members   -  Reputation: 122

Like
Likes
Like

Posted 12 July 2001 - 03:56 AM

Hi ppl! Does anyone know how to make DirectDraw work with OpenGL? Is it possible? Pls advise. Thanks.

Sponsor:

#2 JanneVee   Members   -  Reputation: 122

Like
Likes
Like

Posted 12 July 2001 - 06:44 AM

No you can''t get them to work together. Both API:s try to control the graphicscard.



/JanneVee
"Some People even believe that COBOL is a real programming language." Scott Meyers - Effective C++

#3 Julio   Members   -  Reputation: 116

Like
Likes
Like

Posted 12 July 2001 - 06:59 AM

actually it''s been done before.

HHSDrum@yahoo.com
Polarisoft Home Page

#4 zedzeek   Members   -  Reputation: 528

Like
Likes
Like

Posted 12 July 2001 - 04:30 PM

it is possible with certain cards but not all cards thus its not advisable to do it

http://members.xoom.com/myBollux

#5 mittens   Moderators   -  Reputation: 1315

Like
Likes
Like

Posted 12 July 2001 - 05:12 PM

Not gonna work unless you put an insane amount of work into it, and have patience... In the end, its not going to work. Don''t try, pretend that you are actually having it work though. That may ease your programming ego a bit. Sorry, I''m tired. Bye.

------------------------------
Trent (ShiningKnight)
E-mail me
OpenGL Game Programming Tutorials

#6 Sirion   Members   -  Reputation: 122

Like
Likes
Like

Posted 13 July 2001 - 09:19 AM

Isnt it possible firstly to call DDraw, use it, then release it and initialize OpenGL??? I mean firstly to call DDraw to make menus and stuff, for so to call OpenGL when the game starts... To try to make them cooperate in game would be to practicaly murder the performance

#7 brettporter   Members   -  Reputation: 122

Like
Likes
Like

Posted 14 July 2001 - 02:07 PM

1) don''t do it at the same time. you will not remain sane
2) you probably could use ddraw, draw 2d only, release and init opengl for the game, but why? You can do 2D easily in GL and at a fair performance. glDrawPixels is notoriously slow, but if you make your components all parts of an RGBA texture and use polygons in ortho mode its fine and no more difficult than regular 2d drawing. saves headaches. See PLGUI for an example (part of the portalib distribution in 0.3)

HTH...

~~~
Cheers!
Brett Porter
PortaLib3D : A portable 3D game/demo libary for OpenGL


#8 gmcbay   Members   -  Reputation: 130

Like
Likes
Like

Posted 14 July 2001 - 02:26 PM

Just popping in to reiterate what others have said above. A lot of OpenGL drivers make use of DirectDraw internally and that usage will conflict with your usage of DirectDraw causing all sorts of ugly problems. You may get it to work with your particular video card, but it will fail with others. Don't do it.

There was some push to get Microsoft to allow merging DirectDraw and OpenGL back in the DX3/OpenGL war days, but Microsoft never publically addressed the issue and let it fall by the wayside.

Of course, you can still use other DirectX components (like DirectInput and DirectSound) with OpenGL. And you can use OpenGL to do 2D rendering, using either texture mapped orthographic quads or its pixel drawing routines (which tend to be slow, I suggest looking into using the 3D texture hardware for blits). If you look around on sites like this (and search on google) for 'OpenGL and 2D' you'll find a bunch of useful information.



Edited by - gmcbay on July 14, 2001 12:44:17 AM

#9 Cyberdrek   Members   -  Reputation: 100

Like
Likes
Like

Posted 14 July 2001 - 03:13 PM

quote:
Original post by ayden
Hi ppl! Does anyone know how to make DirectDraw work with OpenGL? Is it possible? Pls advise. Thanks.


Ok, first of all, as everydoby mentioned already, it''s not going to work. It can be done, but in the end, you still have to choose between one or the other or some of the functions will clash... Anyhow, why would you need to have DirectDraw with OGL???



"And that''s the bottom line cause I said so!"

Cyberdrek
Headhunter Soft
A division of DLC Multimedia

Resist Windows XP''s Invasive Production Activation Technology!

"gitty up" -- Kramer




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS