[osg-users] OSG is unable to create 3.3 core profile context

Ashley Nielsen wyvernventures at gmail.com
Sun Jul 23 05:48:11 PDT 2017

robertosfield wrote:
> Hi Ahsley,
> What OS, GL drivers, OSG version and hardware are you using?
> Robert.
>  ------------------
> Post generated by Mail2Forum

OS: Ubuntu 17.04
GL drivers: as reported by glxinfo


server glx version string: 1.4 
client glx version string: 1.4 
GLX version: 1.4 
    Max core profile version: 4.5 
    Max compat profile version: 3.0 
    Max GLES1 profile version: 1.1 
    Max GLES[23] profile version: 3.1 
OpenGL core profile version string: 4.5 (Core Profile) Mesa 17.0.3 
OpenGL core profile shading language version string: 4.50 
OpenGL version string: 3.0 Mesa 17.0.3 
OpenGL shading language version string: 1.30 
OpenGL ES profile version string: OpenGL ES 3.1 Mesa 17.0.3 
OpenGL ES profile shading language version string: OpenGL ES GLSL ES 3.10 

OSG version: Git HEAD 0b5f45289d1c4b2de7e2e29380a1e0a3f92ac79e (Mon Jun 19 15:55:42 2017 +0100)
Hardware: Here is the output of lshw -c video, showing Radeon HD 8870M with the open-source radeon driver:


       description: VGA compatible controller
       product: Venus XT [Radeon HD 8870M / R9 M270X/M370X]
       vendor: Advanced Micro Devices, Inc. [AMD/ATI]
       physical id: 0
       bus info: pci at 0000:01:00.0
       version: 00
       width: 64 bits
       clock: 33MHz
       capabilities: pm pciexpress msi vga_controller bus_master cap_list rom
       configuration: driver=radeon latency=0
       resources: irq:28 memory:e0000000-efffffff memory:f7e00000-f7e3ffff ioport:e000(size=256) memory:c0000-dffff

The same code, unmodified, does work fine on my desktop with an Nvidia GTX 570 using the proprietary nv drivers. I can't confirm until I get back home tonight, but it looks like my desktop supports compatibility profile for version 330 shaders, while this laptop does not, as glxinfo on the laptop shows compatibility profile supports a max shader version of 130 and GL version 3.0. I mention this because it appears when using Linux/GraphicsWindowX11, OSG creates a compatibility profile if the programmer requests or intends to create a core profile. Is this intentional? Looking at line 820 in GraphicsWindowX11, I think this line might be creating the maximum compatibility profile, and "glXCreateContextAttribsARB" may be required to create core profile contexts if requested by the developer. Around line 1873 of GraphicsWindowWin32, it appears "glContextVersion" is parsed and the (Windows) ARB method is used.

Read this topic online here:

More information about the osg-users mailing list