OpenGL Successor

Discussion in 'Planetary Annihilation General Discussion' started by blightedmythos, February 6, 2015.

  1. blightedmythos

    blightedmythos Active Member

    Messages:
    405
    Likes Received:
    202
    Have you guys heard of glNext being devoloped by Khronos and Value? I am very interested in seeing the advantages over OpenGL which has sort of been thought as a dying engine.
    http://www.pcgamer.com/opengl-successor-to-be-unveiled-at-gdc-session/

    The reason I bring it up is because (correct me if I am wrong) PA is running on OpenGL

    What improvements do you think it will bring?
  2. cola_colin

    cola_colin Moderator Alumni

    Messages:
    12,074
    Likes Received:
    16,221
    For PA? Probably none, I doubt they will update PA for that stuff.
    SXX likes this.
  3. calmesepai

    calmesepai Member

    Messages:
    180
    Likes Received:
    21
    I'll give it a few more years to mature first
  4. SXX

    SXX Post Master General

    Messages:
    6,896
    Likes Received:
    1,812
    Yep this is correct.

    It's should bring simplified work with context from within multiple threads/cores and this it's might finally bring unified shader compiler that will solve a lot of compatibility issues that GLSL had because vendors implemented things differently (e.g Nvidia allowed to compile tons of broken code).

    Though currently Uber already implemented their own threading model for GL and using GLSLang for shader validation. Still as far as I understand problem with brightness on AMD/Windows is happen because there something really wrong with AMD shader compiler on AMD proprietary drivers and if there was more strict GLSL compiler this would likely help to avoid such problems
    Remy561 and guest1 like this.
  5. blightedmythos

    blightedmythos Active Member

    Messages:
    405
    Likes Received:
    202
    Very interesting, I always liked OpenGL, I felt like I've always had higher FPS with ID software games back in the day. It's sad it doesn't get more use.
  6. bgolus

    bgolus Uber Alumni

    Messages:
    1,481
    Likes Received:
    2,299
    OpenGL isn't an engine, it's a graphics API. Graphics APIs take data and commands and passes on that data to a GPU to tell it what to render. A graphic or game engine is the thing that decides what that data is and what the commands are.

    Part of what modern graphics APIs do is help move the data where the graphics card can access it and translate the commands to a form the graphics card understands. This means that generally the commands and data we give to the API will work on different hardware even if they work very differently.

    PA is running OpenGL 3.1, even though there are tons of improvements in OpenGL from versions 3.2 through now 4.5. You can blame a combination of wanting to support a wide range of users, as well as Mac & Linux which had iffy support for OpenGL after 3.2 when we started working on PA (and in fact we dropped back down to OpenGL 3.1 because of Linux).

    One of the big problems with OpenGL and DirectX (pre version 12) is these APIs are still basically designed around how video cards theoretically worked in the late 90's. Graphics cards have changed significantly, but the APIs haven't, so there's a lot more translating happening behind the scenes. DirectX 12, Mantle (AMD), and Metal (iOS) are all looking to break with the past and present an API that is closer to how the graphics card is actually doing stuff today.

    OpenGL is funny because of a concept of extensions to the base API. Different graphics cards and drivers can support a range of features such that something that is "OpenGL 3.0" might use a feature that is consider part of OpenGL 4.4. It also allows for different graphics card vendors to have unique extensions that are closer to what the driver is sending the video card behind the scenes or features that aren't part of the base feature set. These extensions often get added back into later versions of OpenGL as part of the "core" language and made to work on different devices, though sometimes one card has to implement a bit of that translation again because that's not how their hardware works.

    The problem with this is now there's a hundred ways to skin a cat in OpenGL, and most of them are bad. I suspect nextGL will strip out most of the redundant functionality of OpenGL and try to be like DirectX 12 and Mantle being closer to the actual hardware functionality, but cross platform (unlike DirectX) and cross vendor (unlike Mantle).

    Also, yes Mantle is "open" in that AMD has offered to let Intel and Nvidia join them in supporting it, but really it exists because it's close to what runs on the Xbone and PS4.
  7. bgolus

    bgolus Uber Alumni

    Messages:
    1,481
    Likes Received:
    2,299
    We have our own threading model for setting up calls to OpenGL, but the actual API calls all have to happen on one thread. What we do is build a giant buffer of API calls that get chewed on. If we could just make the calls from all of those threads things would be even faster.

    The AMD brightness bug has nothing to do with GLSLang or strict GLSL compilers. AMD (and OSX) have very strict compilers, but sometimes stuff just doesn't work even if it should.
  8. blightedmythos

    blightedmythos Active Member

    Messages:
    405
    Likes Received:
    202
    Really enjoyed this detailed explanation, thanks for the post. I misspoke when I said engine, I misused the terminology but know the difference. Curious to know if Uber is interesting in ever upgrading to GlNext if it's successful. I also didn't know Mantle was open and the primary reason for that was Xbox1 and PS4 sharing similar AMD cards.
  9. SXX

    SXX Post Master General

    Messages:
    6,896
    Likes Received:
    1,812
    Though it's also needed for Intel Sandy Bridge (HD2000 / HD3000) on Windows. :rolleyes:

    Thanks. You're explaining it much better than me.

    Interesting... Any details on what going wrong here?
    Anyway hope you'll eventually find workaround for this one. :)
  10. SXX

    SXX Post Master General

    Messages:
    6,896
    Likes Received:
    1,812
    You may note this open is in quotes which is just about right. My personal understanding of this situation: Mantle is "open", but it's designed by one vendor to suite specific architecture their own hardware best.

    This kind of openness is opposite to Khronos standards. OpenGL/GLNext isn't just "open", but created by cooperation of multiple vendors which is main difference.
  11. bgolus

    bgolus Uber Alumni

    Messages:
    1,481
    Likes Received:
    2,299
    Will we upgrade PA? No.
    Will we upgrade the engine on some future project? Possibly (hopefully).

    None yet, though I can say for the first version of the SAO shader it had serious problems on some AMD cards. One of the ones in the office had the issue and the problem was caused by the shader getting completely junk data from an otherwise mundane and commonly used function. Specifically dFdx and dFdy were random returning infinites and nans, and when it wasn't it was returning values that were the inverse of every other video card. It wasn't any issue with the shader, the function was (and probably still is) just straight up broken.

    It could be something like this, it could be something completely different.
  12. theseeker2

    theseeker2 Well-Known Member

    Messages:
    1,613
    Likes Received:
    469
    I kind of wish there wasn't macos and linux support, just so we windows users could bask in windows 10 dx12 glory
  13. blightedmythos

    blightedmythos Active Member

    Messages:
    405
    Likes Received:
    202
    Have to say I agree. On the other hand, I think what Valve is doing, trying to push the OS monopoly off Microsoft is admirable as well.
    Last edited: February 6, 2015
    Remy561 likes this.
  14. andrehsu

    andrehsu Active Member

    Messages:
    366
    Likes Received:
    120
    ^value?
    you mean valve?
  15. theseeker2

    theseeker2 Well-Known Member

    Messages:
    1,613
    Likes Received:
    469
    I am perfectly content with the Microsoft OS monopoly.
  16. blightedmythos

    blightedmythos Active Member

    Messages:
    405
    Likes Received:
    202
    Until they start charging you $1000 per os, like many monopolies do. Pay attention to ISP's in your area lately for example?
  17. squishypon3

    squishypon3 Post Master General

    Messages:
    7,971
    Likes Received:
    4,357
    Without mac and linux the game probably would have lost a lot of funding. XP
  18. xanoxis

    xanoxis Active Member

    Messages:
    459
    Likes Received:
    238
    But can you give work to all cores and increase performance? If we want 40 player battles, we need all the juice in PC we can get.
  19. blightedmythos

    blightedmythos Active Member

    Messages:
    405
    Likes Received:
    202
    You think? I always thought of mac and linux being a very low percentage for gaming, probably less then 5% I could be wrong though.
  20. Dementiurge

    Dementiurge Post Master General

    Messages:
    1,094
    Likes Received:
    693
    Makes me wonder if Steam offers any bonuses for having a game that supports Linux/Mac.

Share This Page