Take the 2-minute tour ×
Game Development Stack Exchange is a question and answer site for professional and independent game developers. It's 100% free, no registration required.

In an article I've read that Microsoft signed GDI/GDI+ as deprecated. I was a bit frightened, I won't be able to use OpenGL in future versions of Windows. Since you need GDI ( more likely the Device Context you get through GDI's GetDC( HWND ) ) to initialize OpenGL.

I got frightened because, when MS marks something as deprecated, it's likely to be removed from the Platform SDK and later from the kernel. This means OpenGL can't be used through GDI.

The only other ways to get the Device Context would be trough WPF or DXGI. But both have their problems:

WPF -> slowly

DXGI -> Device Context shows sometimes creepy graphic bugs

So my question is: Is Microsoft killing OpenGL ? I'm asking because MS seems to make the use of OGL pretty difficult.

Thank's for reading.

share|improve this question

closed as not constructive by Patrick Hughes, Maik Semder, John McDonald, Ali.S, Anko May 26 '13 at 23:35

As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.If this question can be reworded to fit the rules in the help center, please edit the question.

    
How about using SDL with OpenGL? I know you can use SDL with OpenGL though I am not sure how SDL works in-depth... –  olevegard May 26 '13 at 17:34
    
Initialize OpenGL on in Windows you've to use Functions from wgl. These will need a DC, that you can only get from a GDI/WPF or DXGI context. :'/ –  Techie May 26 '13 at 17:36
6  
Use the available tools, there will always be a fast 3D renderer in the near future on windows. Stop complaining and choose the proper tools (or engines that do it for you). Having said that, this is a hypothetical question, we can hardly forsee the future here, hence voting to close as this is not an answerable question. –  Maik Semder May 26 '13 at 17:46
    
Ok, my question goes down like a lead balloon. Of course I didn't want to complain about MS. I think I 've incorrectly formulated my thoughts / question. –  Techie May 26 '13 at 17:50
1  
Thank you, I'll take a look on the FAQ. –  Techie May 26 '13 at 18:04

1 Answer 1

up vote 4 down vote accepted

Two things:

  1. GDI and GDI+ are not going anywhere. Deprecated and Obsolete have two very different meanings, and GDI/GDI+ are just Deprecated. This means that there are better ways to do the same things you used to do with GDI/GDI+, namely DirectX, DirectComposition and WIC, but I don't foresee Microsoft actually removing GDI/GDI+ from the kernel anywhere in the future, as there is way too much software written with these libraries, and Microsoft prides itself on its backwards compatibility (unlike a certain fruit-named company, which seems to enjoy breaking software with each update).

    To give you some perspective, OpenFile has been deprecated for almost 20 years, but you can still call it, and it still works, and it will still work for a long time. It is of course deprecated, and there are few reasons (if any) to use it instead of the newer CreateFile.

    So feel free to use GDI/GDI+ if that's what's best for your application. However, you are strongly encouraged to use the newer APIs, and hopefully in the future, there will be no reasons to use GDI/GDI+, just like today there's no reason for anybody to use OpenFile.

  2. Regarding OpenGL, I haven't done WGL recently, but you only require an hDC to create an OpenGL content, but that's all there is to it. OpenGL is not built on top of GDI, and OpenGL's relationship with GDI is so inconsequential, that even in the extremely bizarre case that GDI is actually removed from the kernel, there will be other ways to create your GL context, probably with the hWnd directly, like in DirectX.

    Microsoft certainly has lots of reasons for deprecating GDI/GDI+, but I can assure you that deprecating it with the single interest of cutting OpenGL is not one of them. If they just wanted to kill OpenGL, they would have done it long ago. And honestly, OpenGL doesn't need any help to kill themselves. They did it a long time ago.

share|improve this answer
    
Thank you for your question. As it seems I had a wrong view on microsoft and their "deprecated" sign. –  Techie May 26 '13 at 17:52
    
unlike a certain fruit-named company Hahaha :P +1 –  Doorknob May 27 '13 at 13:19
    
Oh, well I didn't ment "quesion", I actually wanted to say answer :P –  Techie Jun 27 '13 at 18:16

Not the answer you're looking for? Browse other questions tagged or ask your own question.