# OpenGL Version Support Change?

**URL:** <https://forum.juce.com/t/opengl-version-support-change/46903>\
**Category:** Windows\
**Created:** [July 12, 2021, 10:29am UTC](https://forum.juce.com/t/opengl-version-support-change/46903 "2021-07-12T10:29:33Z")\
**Posts on this page:** 17\
**Page:** 1

<div class="post-metadata">

**Author:** ![dave96](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/dave96/32/8487_2.png) [@dave96](https://forum.juce.com/u/dave96)\
**Post date:** [July 12, 2021, 10:29am UTC](https://forum.juce.com/t/opengl-version-support-change/46903/1 "2021-07-12T10:29:33Z")

</div>

Did something change recently (within the past two months) with regards to OpenGL support on Windows?

I have a user with a relatively old Windows machine which says when using OpenGL, the screen is simply black for him now.

I know there was a breaking change with respect to the GLEW function loading but will this have broken existing versions? I don’t think we do any special OGL stuff, just change the top level renderer.

---

<div class="post-metadata">

**Author:** ![otristan](https://avatars.discourse-cdn.com/v4/letter/o/f0a364/32.png) [@otristan](https://forum.juce.com/u/otristan)\
**Post date:** [July 12, 2021, 11:21am UTC](https://forum.juce.com/t/opengl-version-support-change/46903/2 "2021-07-12T11:21:49Z")

</div>

> <https://github.com/juce-framework/JUCE/commit/280d97eb79f7710a6ebd03fa6551529c9447d6f5>

?

---

<div class="post-metadata">

**Author:** ![dave96](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/dave96/32/8487_2.png) [@dave96](https://forum.juce.com/u/dave96)\
**Post date:** [July 12, 2021, 12:18pm UTC](https://forum.juce.com/t/opengl-version-support-change/46903/3 "2021-07-12T12:18:44Z")

</div>

Hmm, could be. Wouldn’t that mean that a larger texture is just created and only a subview of it displayed on screen though?

---

<div class="post-metadata">

**Author:** ![reuk](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/reuk/32/21494_2.png) [@reuk](https://forum.juce.com/u/reuk)\
**Post date:** [July 12, 2021, 12:35pm UTC](https://forum.juce.com/t/opengl-version-support-change/46903/4 "2021-07-12T12:35:48Z")

</div>

I removed some of the `JUCE_OPENGL3` checks recently, so perhaps that could be causing issues on some platforms which don’t support OpenGL 3 (although I did test on Linux with GL 2.1 recently and that seemed fine). I’m currently trying to find a way to force my Windows install to use an older version of OpenGL to test out this theory.

---

<div class="post-metadata">

**Author:** ![jrlanglois](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/jrlanglois/32/21372_2.png) [@jrlanglois](https://forum.juce.com/u/jrlanglois)\
**Post date:** [July 12, 2021, 12:36pm UTC](https://forum.juce.com/t/opengl-version-support-change/46903/5 "2021-07-12T12:36:55Z")

</div>

Nothing significant has changed that should affect you this way.

> [@dave96](#):
>
> I have a user with a relatively old Windows machine which says when using OpenGL, the screen is simply black for him now.

Have you received the user’s GPU and OpenGL driver versions?

A black screen is a common result when using Intel drivers, especially old ones; they don’t properly support GL at all.

We have been using this structure to auto-detect old systems and to auto-detach the `juce::OpenGLContext` in such an event: [https://github.com/SquarePine/squarepine\_core/blob/main/modules/squarepine\_graphics/components/HighPerformanceRendererConfigurator.cpp#L126-L149](https://github.com/SquarePine/squarepine_core/blob/main/modules/squarepine_graphics/components/HighPerformanceRendererConfigurator.cpp#L126-L149)

---

<div class="post-metadata">

**Author:** ![dave96](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/dave96/32/8487_2.png) [@dave96](https://forum.juce.com/u/dave96)\
**Post date:** [July 12, 2021, 2:05pm UTC](https://forum.juce.com/t/opengl-version-support-change/46903/6 "2021-07-12T14:05:59Z")

</div>

I’ve asked for some more OpenGL details from the user.

I haven’t been able to replicate this either, even with a fairly old EliteBook I’ve got.

I might have to add in a check like you linked to disable GL if the drivers don’t support it, that would be ok for new customers but it’s odd for people who it was working for if it just suddenly stops working with an update (and we don’t have any obvious rationale).

---

<div class="post-metadata">

**Author:** ![reuk](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/reuk/32/21494_2.png) [@reuk](https://forum.juce.com/u/reuk)\
**Post date:** [July 12, 2021, 8:13pm UTC](https://forum.juce.com/t/opengl-version-support-change/46903/7 "2021-07-12T20:13:16Z")

</div>

Unfortunately I’ve not had much success reproducing this. On a VirtualBox VM with no OpenGL support, the DemoRunner displays a black screen after enabling the OpenGL renderer both with JUCE 6.0.5 and with current develop. I couldn’t find a way to create an older OpenGL context in my VMWare Fusion VM, so I haven’t been able to test with an old GL context on Windows.

---

<div class="post-metadata">

**Author:** ![dave96](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/dave96/32/8487_2.png) [@dave96](https://forum.juce.com/u/dave96)\
**Post date:** [July 13, 2021, 9:24am UTC](https://forum.juce.com/t/opengl-version-support-change/46903/8 "2021-07-13T09:24:14Z")

</div>

I got some more details back from the tester. Apparently the OpenGL version is `1.108` using a “Mobil Intel 965 Express Chipset Family”.

I’m guessing JUCE just doesn’t support versions that old? Although I would have thought that would never work… Didn’t shaders appear in OpenGL 2?

I think we might just have to put this down to his system being too old. I’ll see how many more users this affects as I push the build out to the public. 🤞

---

<div class="post-metadata">

**Author:** ![jrlanglois](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/jrlanglois/32/21372_2.png) [@jrlanglois](https://forum.juce.com/u/jrlanglois)\
**Post date:** [July 13, 2021, 6:04pm UTC](https://forum.juce.com/t/opengl-version-support-change/46903/9 "2021-07-13T18:04:18Z")

</div>

> [@dave96](#):
>
> using a “Mobil Intel 965 Express Chipset Family”.

There’s no way this ever ran anything OpenGL related from JUCE since that device is from 2007. I would suspect it’s barely getting by in plainly rendering your app!

---

<div class="post-metadata">

**Author:** ![reuk](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/reuk/32/21494_2.png) [@reuk](https://forum.juce.com/u/reuk)\
**Post date:** [July 15, 2021, 11:52am UTC](https://forum.juce.com/t/opengl-version-support-change/46903/10 "2021-07-15T11:52:11Z")

</div>

I’ve added a small change which should reinstate some behaviour which may have got broken during the function-loading update:

> <https://github.com/juce-framework/JUCE/commit/90ad1877aff6fa2e23523a93131183db156f1d2d>

I’m not sure whether this is relevant to your user on the 965 chipset, as it seems like texture copying (and possibly other bits and pieces?) would be broken on a card which doesn’t support OpenGL 2, but thought I’d let you know just in case.

---

<div class="post-metadata">

**Author:** ![dave96](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/dave96/32/8487_2.png) [@dave96](https://forum.juce.com/u/dave96)\
**Post date:** [July 15, 2021, 2:15pm UTC](https://forum.juce.com/t/opengl-version-support-change/46903/11 "2021-07-15T14:15:45Z")

</div>

Ok thanks. I’ve mentioned to the tester we don’t support chipsets that old for OpenGL but I’ll let him know this _might_ have made a difference. Cheers!

---

<div class="post-metadata">

**Author:** ![ttg](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/ttg/32/14456_2.png) [@ttg](https://forum.juce.com/u/ttg)\
**Post date:** [February 8, 2022, 10:57am UTC](https://forum.juce.com/t/opengl-version-support-change/46903/12 "2022-02-08T10:57:13Z")

</div>

(removed commits) - need to better bisect this but I see changes of profiles on OpenGL\_win32.h

On my machines I’ve noticed it’s now using a newer (latest OpenGL context).  
Meaning any older glsl/opengl pre 3.x can easily fail resulting black screen.

@dave96 - In our case I’m now able to ‘reproduce’ the black screen on macOS by explicitly enforcing `setOpenGLVersionRequired (juce::OpenGLContext::OpenGLVersion::openGL3_2)`. without this I get `GLSL #110`.  
After this I get `GLSL #150` and any removed pre-3 API breaks also on a mac.

Trying to figure out if there’s a way to enforce older opengl version on Windows.

---

<div class="post-metadata">

**Author:** ![reuk](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/reuk/32/21494_2.png) [@reuk](https://forum.juce.com/u/reuk)\
**Post date:** [February 8, 2022, 11:27am UTC](https://forum.juce.com/t/opengl-version-support-change/46903/13 "2022-02-08T11:27:22Z")

</div>

It looks like context-creation changed a few times on Windows. For a while JUCE didn’t take the requested OpenGL version into account at all. Then, it was updated to allow creating a 3.3 core profile when `openGL3_2` was requested. This was quickly adjusted to return a 3.2 core profile to match the behaviour on macOS. Shortly after that, it was updated again to return a 3.2 compatibility profile.

I’m not convinced that the latest change is correct. If we want to provide the same behaviour on macOS and Windows, then we should be creating a 3.2 core profile on Windows too. I’ll need to test a bit to find out if there are other workarounds for the issues that were mentioned in this thread:

> [@Bug on Windows with OpenGL and enabling multisampling](https://forum.juce.com/t/bug-on-windows-with-opengl-and-enabling-multisampling/49056/2):
>
> I’m also not really sure how this logic - if (version \>= openGL3\_2 - makes any sense from a user’s point of view: there aren’t any larger enum values provided. Aren’t we better off dropping the enum for explicit integers for maj and min at this point?

---

<div class="post-metadata">

**Author:** ![reuk](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/reuk/32/21494_2.png) [@reuk](https://forum.juce.com/u/reuk)\
**Post date:** [February 21, 2022, 1:06pm UTC](https://forum.juce.com/t/opengl-version-support-change/46903/14 "2022-02-21T13:06:55Z")

</div>

I’ve attempted to fix the issue here:

> <https://github.com/juce-framework/JUCE/commit/e367393a9973342d97430643dc21fb7cb21c4f52>
>
> This mirrors the behaviour on macOS.

> <https://github.com/juce-framework/JUCE/commit/199885baa8bec8e01e3fa0a528d037caf0784af6>
>
> In OpenGL 3 and up, GL\_EXTENSIONS is deprecated as an argument of
> glGetString an…d glGetStringi should be used instead.

Now, requesting an OpenGL 3.2 context will always return a Core profile rather than a Compatibility profile.

---

<div class="post-metadata">

**Author:** ![cgleo](https://avatars.discourse-cdn.com/v4/letter/c/3ec8ea/32.png) [@cgleo](https://forum.juce.com/u/cgleo)\
**Post date:** [November 15, 2022, 12:01pm UTC](https://forum.juce.com/t/opengl-version-support-change/46903/15 "2022-11-15T12:01:40Z")

</div>

Actually we have a problem with the core-profile, I pinned it down to this commit: [OpenGL: Use a core profile when OpenGL 3.2 is requested on Windows · juce-framework/JUCE@e367393 · GitHub](https://github.com/juce-framework/JUCE/commit/e367393a9973342d97430643dc21fb7cb21c4f52).

In Ableton Live (11), when using OpenGL with this commit, the hi-res scaling is broken. The UI is scaled twice as big (from the lower left corner), and clipped at the top/right edges:

 ![Capture_1](https://us1.discourse-cdn.com/flex026/uploads/juce/original/2X/4/4f17981a3505024f5c7e3bc98e84fae08cd1e446.png)

When I change the flag back to WGL\_CONTEXT\_COMPATIBILITY\_PROFILE\_BIT\_ARB, everything works fine:

 ![Capture_2](https://us1.discourse-cdn.com/flex026/uploads/juce/original/2X/7/7975bd500ffaacd1c8499cccbe6826d622dd2e3a.png)

Double checked that its only in Ableton Live. And I have an Nvidia Quadro card.

---

<div class="post-metadata">

**Author:** ![cgleo](https://avatars.discourse-cdn.com/v4/letter/c/3ec8ea/32.png) [@cgleo](https://forum.juce.com/u/cgleo)\
**Post date:** [January 19, 2023, 10:54am UTC](https://forum.juce.com/t/opengl-version-support-change/46903/16 "2023-01-19T10:54:41Z")

</div>

Hi reuk,  
are there any practial reasons for using the core profile on windows?  
Or proof that it fixes something?  
If not, I would strongly suggest to change it back to the compatibility profile (or make it selectable).  
In the meantime, I have seen the behaviour I described in my last post on some plugins from other manufacturers too, and it effectivly prevents hi-res for these plugins in Ableton (which has a very large market share).

---

<div class="post-metadata">

**Author:** ![reuk](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/reuk/32/21494_2.png) [@reuk](https://forum.juce.com/u/reuk)\
**Post date:** [January 19, 2023, 11:15am UTC](https://forum.juce.com/t/opengl-version-support-change/46903/17 "2023-01-19T11:15:57Z")

</div>

> [@cgleo](#):
>
> are there any practial reasons for using the core profile on windows?

Yes, this is consistent with the behaviour on macOS, where only the core profile is available for GL versions above 3.2. Using the same profile on each platform makes it easier for users to port their GL code between platforms.

I believe that Ableton is aware of this issue. When I investigated this previously, it appeared that the issue could be resolved by forcing Live to open in DPI-aware mode (right-click on Live.exe → properties → compatibility → change high DPI settings → check “Override high DPI scaling behaviour. Scaling performed by: Application”) which suggests that it’s probably possible for the issue to be solved in Live.
