• Announcements

    • khawk

      Download the Game Design and Indie Game Marketing Freebook   07/19/17

      GameDev.net and CRC Press have teamed up to bring a free ebook of content curated from top titles published by CRC Press. The freebook, Practices of Game Design & Indie Game Marketing, includes chapters from The Art of Game Design: A Book of Lenses, A Practical Guide to Indie Game Marketing, and An Architectural Approach to Level Design. The GameDev.net FreeBook is relevant to game designers, developers, and those interested in learning more about the challenges in game development. We know game development can be a tough discipline and business, so we picked several chapters from CRC Press titles that we thought would be of interest to you, the GameDev.net audience, in your journey to design, develop, and market your next game. The free ebook is available through CRC Press by clicking here. The Curated Books The Art of Game Design: A Book of Lenses, Second Edition, by Jesse Schell Presents 100+ sets of questions, or different lenses, for viewing a game’s design, encompassing diverse fields such as psychology, architecture, music, film, software engineering, theme park design, mathematics, anthropology, and more. Written by one of the world's top game designers, this book describes the deepest and most fundamental principles of game design, demonstrating how tactics used in board, card, and athletic games also work in video games. It provides practical instruction on creating world-class games that will be played again and again. View it here. A Practical Guide to Indie Game Marketing, by Joel Dreskin Marketing is an essential but too frequently overlooked or minimized component of the release plan for indie games. A Practical Guide to Indie Game Marketing provides you with the tools needed to build visibility and sell your indie games. With special focus on those developers with small budgets and limited staff and resources, this book is packed with tangible recommendations and techniques that you can put to use immediately. As a seasoned professional of the indie game arena, author Joel Dreskin gives you insight into practical, real-world experiences of marketing numerous successful games and also provides stories of the failures. View it here. An Architectural Approach to Level Design This is one of the first books to integrate architectural and spatial design theory with the field of level design. The book presents architectural techniques and theories for level designers to use in their own work. It connects architecture and level design in different ways that address the practical elements of how designers construct space and the experiential elements of how and why humans interact with this space. Throughout the text, readers learn skills for spatial layout, evoking emotion through gamespaces, and creating better levels through architectural theory. View it here. Learn more and download the ebook by clicking here. Did you know? GameDev.net and CRC Press also recently teamed up to bring GDNet+ Members up to a 20% discount on all CRC Press books. Learn more about this and other benefits here.
Sign in to follow this  
Followers 0
_the_phantom_

OpenGL
OpenGL3.0.. I mean 2.2

337 posts in this topic

This is an unbelievable letdown. I kind of saw it coming, but I never expected the ARB to fail on such an immense scale. I find it astonishing how far some people can be removed from reality, and yet not be immediately fired due to overwhelming incompetence. This is the death of modern OpenGL. Thank you very much ARB. What Microsoft never managed, you did. You should be ashamed of yourselves.

After hearing these news, we will be starting the end-of-life plan for our OpenGL renderer in the very near future (XP compatibility and quad buffered stereo are the only features holding it back), and will be focusing on D3D10 exclusively from now on.

Oh, and we are a CAD software manufacturer...

I really wonder if there is some remote possibility to take legal action against the ARB / Khronos after this total fiasco.

Quote:

The intent there is to provide for an orderly simplification of the specification and drivers for upcoming releases, the next of which is scheduled for less than 12 months from now.

Haha, good one. At least they haven't lost their (very strange) sense of humour...
0

Share this post


Link to post
Share on other sites
Not that it matters much, but I'm sure the Comparison of OpenGL and Direct3D wikipage slants a certain way.

I wonder then, as Macs are becoming more popular these days... and more people play games - will Apple / Linux community implement and extend to keep up with DX? Or do something new?

I'd imagine implement + extend would fragment the platform though, potentially taking away some of the cross-platform-ness.
0

Share this post


Link to post
Share on other sites
Quote:
Original post by rbarris

BTW we have set up a mail reflector specifically for questions and suggestions specifically relating to game development using OpenGL 3.0 - if there is some piece of hardware functionality not addressed by the current 3.0 spec, now is exactly the right time to let us hear about it.

gamedev@khronos.org


Thanks for that. Though TBH I think you may be one of the few game developers with the resources to carry on using GL. It's not that anything has gotten signifantly worse, it's that not enough things have gotten better to counter the long-standing lack of freely available tools and support (compared to D3D). A fresh new API would have gone some way to countering the problem, but would still have only been a stop-gap.

For example; the company I work for refuses to consider OpenGL simply because of the percieved lack of support. OpenGL 3 wasn't going to change that, but the impression given by the recent problems is that support is getting worse not better.

I realise these aren't technical issues, sorry. Overall I think the problem here is that for a while it seemed Khronos would make OpenGL as easy to work with as Direct3D, and the long wait and shiny new version number made people hope for something bigger even than what was promised.
0

Share this post


Link to post
Share on other sites
Less than 12 months.

Deprecation model, eh? I have a much simpler deprecation model, rbarris - FREEZE GL 2.1, and design GL3 from scratch. This was promised to us. It was a lie. OpenGL died today.
0

Share this post


Link to post
Share on other sites
I wrote the gamedev@khronos.org asking where's the API that was promised and what the hell were they doing for the last year that they couldn't talk with the community about. I doubt I'll get a sincere response, but I want to know how they could catastrophically fail in moving this standard forward. I understand legacy code bases probably better than then next guy (anybody play with DIS And HLA simulations?), but this is ridiculous. Where is the progress they promised?

Bob
0

Share this post


Link to post
Share on other sites
I guess the OpenGL vs Direct3D question has finally been answered. It's Direct3D unless you need cross platform compatibility.

Very sad.

Regards
elFarto
0

Share this post


Link to post
Share on other sites
Although I can understand some of the frustration around here, I think you may be a bit too pessimistic there.

I've only skimmed over that specification for about 5 minutes, but so far it really doesn't look that grim.
Yes, there are no objects. Yes, there is still fixed functionality around. No, there has been no complete API rewrite. But hey, so what.
Look at the positive side. A good number of extensions with valuable features has been promoted to core, even some features that weren't initially announced at all. So, some stuff will be a bit less messy, which is good already.
Maybe "version 3.0" is a bit far fetched for what's in the spec, I'd rather have called it 2.2 or 2.3, but hey... what do numbers really mean. Remember when Netscape jumped from 4 to 6 in one go? :)

To be honest, this spec is a lot more than what I had expected to happen, and I see it as a very positive thing. In fact, I had expected that nothing happens at all, and I am very happy that we got at least half of what was promised, and a few goodies to comfort for the other half.
If you consider how many people/companies inside and outside of Khronos have excellent economic reasons against supporting and extending OpenGL, and how few people have a reason to support it at all, it's a miracle.
0

Share this post


Link to post
Share on other sites
WHY HAVE YOU GUY BEEN DEBATING THIS FOR SO LONG?!?! After DirectX8 came out it was clear that DirectX was the better API and anyone that thought it was not didn't use it. OpenGL is for cross platform support and not easy use.
0

Share this post


Link to post
Share on other sites
Hmmm, I must admit I was looking forward to a new streamlined OpenGL, but I don't find this new version that bad. You can see some of what they were aiming for in the new deprecation model. It does away with a lot of the cruft in OpenGL, including pretty much everything fixed-function. They've been quite brutal with what they've culled as listed in Appendix E.

I suspect this'll actually make life easier for driver writers as they'll write new drivers to support the new deprecation model with an OpenGL 2.1 emulator sitting on top of that. If the ARB is wise they'll provide the code for that emulation layer to help things along.

It's not the re-write they had promised us, but after that strange year of dead silence we kinda all knew something was up. But this just doesn't seem that bad to me. It's not a huge leap but it is a step in the right direction.

BTB, I've had the misfortune to create renderers for the Intel i915 in both GL and D3D, and their drivers stink on both. :-/
0

Share this post


Link to post
Share on other sites
LOL, problem solved. Some cad guy told everyone in the thread @ OpenGL's site to calm down, and that games are small, unimportant apps.
0

Share this post


Link to post
Share on other sites
Sounds like lots of 'The sky falling' talk but I thought the sky had fallen years ago. I am using OGL/GLSL and it has everything I need. The trick is not to read the DX SDK :)

I don't think a clean slate would help drivers out since it would likely mean a new driver from scratch plus maintaining their old one. Honestly, do you think people would just run over to the oven for the freshly baked OGL 3.0 and say 'Finally, we can all stop sitting on our hands and start witting our OGL 3.0 driver'?

I learned roughly OS/2 years ago not to take sides. Just use OGL for what it's good for and leave it at that.

0

Share this post


Link to post
Share on other sites
Wow, that is in fact a massive letdown.

Though, I interpret this as an artifact of the upcoming paradigm shift in graphics, introduced by Larrabee et al. ... Makes me think that the DirectX story is far from being told with Microsoft adding Compute Shaders to it either.

Part of the problem seems to be that there is no sufficiently good API to that future architecture yet, not even conceptually, let alone one that traditional things such as OpenGL/DX could easily be consistent with. So that no really future-proof way of evolving these is in sight atm.

[Edited by - pro_optimizer on August 11, 2008 1:47:17 PM]
0

Share this post


Link to post
Share on other sites
Extremely unprofessional job by Kronos, they took an extra year to basically just add a couple of NV extensions as ARB extensions. If they were going to go back on their original intentions they should have made it clear much earlier. Don't even see Geometry shaders mentioned either so sub sm4 levels. I'm done with OGL asap.
0

Share this post


Link to post
Share on other sites
Quote:
Original post by Tesshu
I don't think a clean slate would help drivers out since it would likely mean a new driver from scratch plus maintaining their old one. Honestly, do you think people would just run over to the oven for the freshly baked OGL 3.0 and say 'Finally, we can all stop sitting on our hands and start witting our OGL 3.0 driver'?


Given that the original re-write from scratch plans were from ATI and NV I have to call that into question. Yes, they would still have to do some mantainence on the old drivers, however for the new they have a clean slate.

Right now when functionality is added into the core they have to check how it interacts with EVERYTHING down to glVertex() and the like. Stripping all this out would have given them a clean slate to start again and not have to worry about these old, outdated methods and how they interact with the newer functionality.

As for the 'deprecation model' someone mentioned; yes because deprecation has worked so well in other cases. People keep using it (see Java) even when there is a big 'do no use!' warning slapped on it, which means it has to stay in because as soon as you remove it it breaks something and BAM! loads of complaints.

The amusing thing, from what I recall there was always plans for a backwards compatible system, with contexts being shared between GL2.x and Longs Peaks so both could operate at once. Guess that wasn't enough...
0

Share this post


Link to post
Share on other sites
Quote:
Original post by DumpAlien
Quote:
Original post by phantom

- failed to make the fast path easy to find
- failed to make the driver developers lives easier
- failed to change the API to better reflect the hardware



Sorry for asking again... but how u come to a conclusion that openGL failed on these three above? I am a little confuzed..

Thanks again!


Having worked very closely with OpenGL drivers at AMD/ATI and Qualcomm, I'll take this one.

1) Because of its long evolution, OpenGL provides many different ways to do the same thing. Typically, one of those ways is very good for performance, and the other ways are bad. In order to access the fast path as things now stand, you have to be familiar with the underlying hardware and usually write multiple paths to fully take advantage of all the hardware out there.

2) Supporting 15+ years of legacy functionality by itself significantly complicates the driver. The expectation that the driver should not just support it, but make it fast, further complicates the drivers.

3) Hardware has changed drastically since OpenGL was first introduced. Because of this, OpenGL is no longer "close to the metal" - which is what you'd expect from a low-level, high performance graphics API. This gets back to the first two points: because the API doesn't really reflect how the hardware actually works, a significant amount of optimization needs to to be done both in the driver and in applications.

As originally described, 3.0 would have fixed these things. Unfortunately, just like 2.0, it seems that 3.0 fell far short of what was initially envisioned.
0

Share this post


Link to post
Share on other sites
Quote:
Original post by Myopic Rhino
Quote:
Original post by DumpAlien
Quote:
Original post by phantom

- failed to make the fast path easy to find
- failed to make the driver developers lives easier
- failed to change the API to better reflect the hardware



Sorry for asking again... but how u come to a conclusion that openGL failed on these three above? I am a little confuzed..

Thanks again!


Having worked very closely with OpenGL drivers at AMD/ATI and Qualcomm, I'll take this one.

1) Because of its long evolution, OpenGL provides many different ways to do the same thing. Typically, one of those ways is very good for performance, and the other ways are bad. In order to access the fast path as things now stand, you have to be familiar with the underlying hardware and usually write multiple paths to fully take advantage of all the hardware out there.

2) Supporting 15+ years of legacy functionality by itself significantly complicates the driver. The expectation that the driver should not just support it, but make it fast, further complicates the drivers.

3) Hardware has changed drastically since OpenGL was first introduced. Because of this, OpenGL is no longer "close to the metal" - which is what you'd expect from a low-level, high performance graphics API. This gets back to the first two points: because the API doesn't really reflect how the hardware actually works, a significant amount of optimization needs to to be done both in the driver and in applications.

As originally described, 3.0 would have fixed these things. Unfortunately, just like 2.0, it seems that 3.0 fell far short of what was initially envisioned.


Its nice to know why, but what concerns me is what do we do next? The only alternatives to windows PC's for gaming, without a more up to date OpenGL, is Cider on apple machines, or consoles. For indie game developers, this means XNA, therefore the Xbox. Either way, MS now get a further increased share of the video game market, to the point where the effect of free market competition is non existant.

I fear that no competator to D3D means poorer quality from MS in the future. OpenGl thrived when it was a viable alternative to DX, but now it seems this is no longer the case. What other alternatives are there?
0

Share this post


Link to post
Share on other sites
Quote:
Original post by speciesUnknown
I fear that no competator to D3D means poorer quality from MS in the future. OpenGl thrived when it was a viable alternative to DX, but now it seems this is no longer the case. What other alternatives are there?


Larrabee or Larrabee-esque architectures where people don't need an API to render at high frame rates maybe?

Sigh.. are we going to have dozens of different API's now?
0

Share this post


Link to post
Share on other sites
Quote:
Original post by speciesUnknown
I fear that no competator to D3D means poorer quality from MS in the future. OpenGl thrived when it was a viable alternative to DX, but now it seems this is no longer the case. What other alternatives are there?


To be fair, OpenGL hasn't really been a viable alternative to D3D in the commerical game space for some years now. Also, MS have already been throwing more resources at XB360 as the recent GameFest showed in the presentation bias towards the 360.

For hobby developers, well, you've still got OpenGL, just not the new shiney API that was planned for.
0

Share this post


Link to post
Share on other sites
Quote:
Original post by speciesUnknown
Quote:
Original post by Myopic Rhino
Quote:
Original post by DumpAlien
Quote:
Original post by phantom

- failed to make the fast path easy to find
- failed to make the driver developers lives easier
- failed to change the API to better reflect the hardware



Sorry for asking again... but how u come to a conclusion that openGL failed on these three above? I am a little confuzed..

Thanks again!


Having worked very closely with OpenGL drivers at AMD/ATI and Qualcomm, I'll take this one.

1) Because of its long evolution, OpenGL provides many different ways to do the same thing. Typically, one of those ways is very good for performance, and the other ways are bad. In order to access the fast path as things now stand, you have to be familiar with the underlying hardware and usually write multiple paths to fully take advantage of all the hardware out there.

2) Supporting 15+ years of legacy functionality by itself significantly complicates the driver. The expectation that the driver should not just support it, but make it fast, further complicates the drivers.

3) Hardware has changed drastically since OpenGL was first introduced. Because of this, OpenGL is no longer "close to the metal" - which is what you'd expect from a low-level, high performance graphics API. This gets back to the first two points: because the API doesn't really reflect how the hardware actually works, a significant amount of optimization needs to to be done both in the driver and in applications.

As originally described, 3.0 would have fixed these things. Unfortunately, just like 2.0, it seems that 3.0 fell far short of what was initially envisioned.


Its nice to know why, but what concerns me is what do we do next? The only alternatives to windows PC's for gaming, without a more up to date OpenGL, is Cider on apple machines, or consoles. For indie game developers, this means XNA, therefore the Xbox. Either way, MS now get a further increased share of the video game market, to the point where the effect of free market competition is non existant.

I fear that no competator to D3D means poorer quality from MS in the future. OpenGl thrived when it was a viable alternative to DX, but now it seems this is no longer the case. What other alternatives are there?


Always could make a new API(The graphics API made by GameDev.net targeted at cross platform game development) But you know that would take awhile and we would need some major $$. It also would probably not work out for some reason.
0

Share this post


Link to post
Share on other sites
Quote:
Original post by phantom
Quote:
Original post by speciesUnknown
I fear that no competator to D3D means poorer quality from MS in the future. OpenGl thrived when it was a viable alternative to DX, but now it seems this is no longer the case. What other alternatives are there?


To be fair, OpenGL hasn't really been a viable alternative to D3D in the commerical game space for some years now. Also, MS have already been throwing more resources at XB360 as the recent GameFest showed in the presentation bias towards the 360.

For hobby developers, well, you've still got OpenGL, just not the new shiney API that was planned for.


Well this does not interfere with my own game concept, but in future, I will likely need to learn DX instead. If that is the case, I may as well continue my hobby on XNA; for the time being, I see little reason not to do so. I know im not the only one who thinks this way.
0

Share this post


Link to post
Share on other sites
OpenGL 3.0 lol

What is brilliant in the computing industry in general is this ability to first deliver something which is not finished yet ( beta version ...) and let the user try it for us.
The second thing is this ability to give the same deficient product again and again until one day you just need to catch up on the rest of the world, because well nobody is using it any more lol.

Anyway I was really waiting for this one, I'm disappointed they could at least explain why.
0

Share this post


Link to post
Share on other sites
Quote:
Original post by Myopic Rhino
Having worked very closely with OpenGL drivers at AMD/ATI and Qualcomm, I'll take this one.

1) Because of its long evolution, OpenGL provides many different ways to do the same thing. Typically, one of those ways is very good for performance, and the other ways are bad. In order to access the fast path as things now stand, you have to be familiar with the underlying hardware and usually write multiple paths to fully take advantage of all the hardware out there.

2) Supporting 15+ years of legacy functionality by itself significantly complicates the driver. The expectation that the driver should not just support it, but make it fast, further complicates the drivers.

3) Hardware has changed drastically since OpenGL was first introduced. Because of this, OpenGL is no longer "close to the metal" - which is what you'd expect from a low-level, high performance graphics API. This gets back to the first two points: because the API doesn't really reflect how the hardware actually works, a significant amount of optimization needs to to be done both in the driver and in applications.

Do these points also apply to OpenGL ES?
0

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0

  • Similar Content

    • By Toastmastern
      So it's been a while since I took a break from my whole creating a planet in DX11. Last time around I got stuck on fixing a nice LOD.
      A week back or so I got help to find this:
      https://github.com/sp4cerat/Planet-LOD
      In general this is what I'm trying to recreate in DX11, he that made that planet LOD uses OpenGL but that is a minor issue and something I can solve. But I have a question regarding the code
      He gets the position using this row
      vec4d pos = b.var.vec4d["position"]; Which is then used further down when he sends the variable "center" into the drawing function:
      if (pos.len() < 1) pos.norm(); world::draw(vec3d(pos.x, pos.y, pos.z));  
      Inside the draw function this happens:
      draw_recursive(p3[0], p3[1], p3[2], center); Basically the 3 vertices of the triangle and the center of details that he sent as a parameter earlier: vec3d(pos.x, pos.y, pos.z)
      Now onto my real question, he does vec3d edge_center[3] = { (p1 + p2) / 2, (p2 + p3) / 2, (p3 + p1) / 2 }; to get the edge center of each edge, nothing weird there.
      But this is used later on with:
      vec3d d = center + edge_center[i]; edge_test[i] = d.len() > ratio_size; edge_test is then used to evaluate if there should be a triangle drawn or if it should be split up into 3 new triangles instead. Why is it working for him? shouldn't it be like center - edge_center or something like that? Why adding them togheter? I asume here that the center is the center of details for the LOD. the position of the camera if stood on the ground of the planet and not up int he air like it is now.

      Full code can be seen here:
      https://github.com/sp4cerat/Planet-LOD/blob/master/src.simple/Main.cpp
      If anyone would like to take a look and try to help me understand this code I would love this person. I'm running out of ideas on how to solve this in my own head, most likely twisted it one time to many up in my head
      Thanks in advance
      Toastmastern
       
       
    • By fllwr0491
      I googled around but are unable to find source code or details of implementation.
      What keywords should I search for this topic?
      Things I would like to know:
      A. How to ensure that partially covered pixels are rasterized?
         Apparently by expanding each triangle by 1 pixel or so, rasterization problem is almost solved.
         But it will result in an unindexable triangle list without tons of overlaps. Will it incur a large performance penalty?
      B. A-buffer like bitmask needs a read-modiry-write operation.
         How to ensure proper synchronizations in GLSL?
         GLSL seems to only allow int32 atomics on image.
      C. Is there some simple ways to estimate coverage on-the-fly?
         In case I am to draw 2D shapes onto an exisitng target:
         1. A multi-pass whatever-buffer seems overkill.
         2. Multisampling could cost a lot memory though all I need is better coverage.
            Besides, I have to blit twice, if draw target is not multisampled.
       
    • By mapra99
      Hello

      I am working on a recent project and I have been learning how to code in C# using OpenGL libraries for some graphics. I have achieved some quite interesting things using TAO Framework writing in Console Applications, creating a GLUT Window. But my problem now is that I need to incorporate the Graphics in a Windows Form so I can relate the objects that I render with some .NET Controls.

      To deal with this problem, I have seen in some forums that it's better to use OpenTK instead of TAO Framework, so I can use the glControl that OpenTK libraries offer. However, I haven't found complete articles, tutorials or source codes that help using the glControl or that may insert me into de OpenTK functions. Would somebody please share in this forum some links or files where I can find good documentation about this topic? Or may I use another library different of OpenTK?

      Thanks!
    • By Solid_Spy
      Hello, I have been working on SH Irradiance map rendering, and I have been using a GLSL pixel shader to render SH irradiance to 2D irradiance maps for my static objects. I already have it working with 9 3D textures so far for the first 9 SH functions.
      In my GLSL shader, I have to send in 9 SH Coefficient 3D Texures that use RGBA8 as a pixel format. RGB being used for the coefficients for red, green, and blue, and the A for checking if the voxel is in use (for the 3D texture solidification shader to prevent bleeding).
      My problem is, I want to knock this number of textures down to something like 4 or 5. Getting even lower would be a godsend. This is because I eventually plan on adding more SH Coefficient 3D Textures for other parts of the game map (such as inside rooms, as opposed to the outside), to circumvent irradiance probe bleeding between rooms separated by walls. I don't want to reach the 32 texture limit too soon. Also, I figure that it would be a LOT faster.
      Is there a way I could, say, store 2 sets of SH Coefficients for 2 SH functions inside a texture with RGBA16 pixels? If so, how would I extract them from inside GLSL? Let me know if you have any suggestions ^^.
    • By KarimIO
      EDIT: I thought this was restricted to Attribute-Created GL contexts, but it isn't, so I rewrote the post.
      Hey guys, whenever I call SwapBuffers(hDC), I get a crash, and I get a "Too many posts were made to a semaphore." from Windows as I call SwapBuffers. What could be the cause of this?
      Update: No crash occurs if I don't draw, just clear and swap.
      static PIXELFORMATDESCRIPTOR pfd = // pfd Tells Windows How We Want Things To Be { sizeof(PIXELFORMATDESCRIPTOR), // Size Of This Pixel Format Descriptor 1, // Version Number PFD_DRAW_TO_WINDOW | // Format Must Support Window PFD_SUPPORT_OPENGL | // Format Must Support OpenGL PFD_DOUBLEBUFFER, // Must Support Double Buffering PFD_TYPE_RGBA, // Request An RGBA Format 32, // Select Our Color Depth 0, 0, 0, 0, 0, 0, // Color Bits Ignored 0, // No Alpha Buffer 0, // Shift Bit Ignored 0, // No Accumulation Buffer 0, 0, 0, 0, // Accumulation Bits Ignored 24, // 24Bit Z-Buffer (Depth Buffer) 0, // No Stencil Buffer 0, // No Auxiliary Buffer PFD_MAIN_PLANE, // Main Drawing Layer 0, // Reserved 0, 0, 0 // Layer Masks Ignored }; if (!(hDC = GetDC(windowHandle))) return false; unsigned int PixelFormat; if (!(PixelFormat = ChoosePixelFormat(hDC, &pfd))) return false; if (!SetPixelFormat(hDC, PixelFormat, &pfd)) return false; hRC = wglCreateContext(hDC); if (!hRC) { std::cout << "wglCreateContext Failed!\n"; return false; } if (wglMakeCurrent(hDC, hRC) == NULL) { std::cout << "Make Context Current Second Failed!\n"; return false; } ... // OGL Buffer Initialization glClear(GL_DEPTH_BUFFER_BIT | GL_COLOR_BUFFER_BIT); glBindVertexArray(vao); glUseProgram(myprogram); glDrawElements(GL_TRIANGLES, indexCount, GL_UNSIGNED_SHORT, (void *)indexStart); SwapBuffers(GetDC(window_handle));  
  • Popular Now