# OpenGL version printed is lower than supported by gpu/driver

## manmadescience

I'm using Gentoo on a notebook with two AMD GPUs: an integrated and a discrete card. Here's what lspci is returning:

```
00:01.0 VGA compatible controller [0300]: Advanced Micro Devices, Inc. [AMD/ATI] Richland [Radeon HD 8650G] [1002:990b]

    Subsystem: Micro-Star International Co., Ltd. [MSI] Richland [Radeon HD 8650G] [1462:10ef]

    Kernel driver in use: radeon

--

01:00.0 VGA compatible controller [0300]: Advanced Micro Devices, Inc. [AMD/ATI] Neptune XT [Radeon HD 8970M] [1002:6801] (rev ff)

    Kernel driver in use: radeon

```

According to the feature support table on Gentoo Wiki, I set in make.conf:

```
VIDEO_CARDS="radeon r600 radeonsi"
```

so both drivers are present to support both GPUs. What bothers me is the glxinfo output:

```

$ DRI_PRIME=0 glxinfo | grep -i opengl # integrated gpu

OpenGL vendor string: X.Org

OpenGL renderer string: Gallium 0.4 on AMD ARUBA

OpenGL version string: 2.1 Mesa 10.3.7

OpenGL shading language version string: 1.30

$ DRI_PRIME=1 glxinfo | grep -i opengl # discrete gpu

OpenGL vendor string: X.Org

OpenGL renderer string: Gallium 0.4 on AMD PITCAIRN

OpenGL version string: 2.1 Mesa 10.3.7

OpenGL shading language version string: 1.30

```

Again, according to the feature table from above, the drivers for both GPUs support at least OpenGL 3.3 which is obviously not the case here. Am I doing something wrong?

Edit: solved, I had bindist use flag selected. Details here: https://superuser.com/q/964099/456335Last edited by manmadescience on Thu Dec 26, 2019 1:04 am; edited 2 times in total

----------

## dufeu

The version of OpenGL reported isn't what's supported by the hardware/driver.

It's the lesser of the hardware/driver or what's supported by Mesa.

The version of Mesa you're using only supports up to OpenGL 2.1.

I just updated to 'media-libs/mesa-11.0.0_rc2'. The relevant glxinfo lines for me are:

```
OpenGL renderer string: Gallium 0.4 on llvmpipe (LLVM 3.7, 128 bits)

OpenGL version string: 3.0 Mesa 11.0.0-rc2
```

If you want to use OpenGL 3.1 and above, you'll need to set up getting Mesa from git source {media-libs/mesa-9999} for which there is no support as that's the actively developed version.

At the present time, I'm not a programmer nor am I prepared to include debug symbols for reporting problems to the developers {though I'm sure they'd appreciate as many independent testers as they can get}. Therefore I'm not enabling getting the -9999 version of Mesa on any of my systems.

YMMV and all that. 

BTW - There are resources here if you want to set up for testing from the developer's branch and all that. I'm just not knowledgable nor reliable enough to assist myself.

----------

## ct85711

There is one other thing you need to keep in mind, open source drivers is not up to what closed source drivers are on supporting opengl.

----------

## Ant P.

You might be missing USE=llvm on Mesa. The 10.x series is new enough to support OpenGL 3.x (the version numbers are based on GL+7).

Your glxinfo output shows "Gallium on $card_name", so that part is good at least — "Gallium on LLVMpipe", on the other hand, would mean you have the software renderer loaded and your card's going completely to waste!

----------

## dufeu

 *Ant P. wrote:*   

> You might be missing USE=llvm on Mesa. The 10.x series is new enough to support OpenGL 3.x (the version numbers are based on GL+7).

 

Good to know. Thanks!

 *Ant P. wrote:*   

> Your glxinfo output shows "Gallium on $card_name", so that part is good at least — "Gallium on LLVMpipe", on the other hand, would mean you have the software renderer loaded and your card's going completely to waste!

 

I've been working on a new build system for the last two months. I've just finished an @world update, yada-yada. Pertinent info:

```
emerge --info

Portage 2.2.20.1 (python 2.7.10-final-0, default/linux/amd64/13.0/desktop/kde, gcc-4.9.3, glibc-2.21-r1, 4.1.6-gentoo x86_64)

=================================================================

System uname: Linux-4.1.6-gentoo-x86_64-AMD_A10-7850K_Radeon_R7,_12_Compute_Cores_4C+8G-with-gentoo-2.2

KiB Mem:    15275720 total,    809324 free

KiB Swap:   16580604 total,  16580604 free

Timestamp of repository gentoo: Sun, 13 Sep 2015 23:00:01 +0000

..
```

```
glxinfo

..

OpenGL vendor string: X.Org

OpenGL renderer string: Gallium 0.4 on AMD KAVERI (DRM 2.42.0, LLVM 3.7.0)

OpenGL core profile version string: 4.1 (Core Profile) Mesa 11.0.0

OpenGL core profile shading language version string: 4.10

..
```

```
vdpauinfo      (I cut out most of the unsupported capabilities)

display: :0   screen: 0

API version: 1

Information string: G3DVL VDPAU Driver Shared Library version 1.0

Video surface:

name   width height types

-------------------------------------------

420    16384 16384  NV12 YV12 

422    16384 16384  UYVY YUYV 

444    16384 16384  Y8U8V8A8 V8U8Y8A8 

Decoder capabilities:

name                        level macbs width height

----------------------------------------------------

MPEG1                           0  9216  2048  1152

MPEG2_SIMPLE                    3  9216  2048  1152

MPEG2_MAIN                      3  9216  2048  1152

H264_BASELINE                  41  9216  2048  1152

H264_MAIN                      41  9216  2048  1152

H264_HIGH                      41  9216  2048  1152

VC1_ADVANCED                    4  9216  2048  1152

MPEG4_PART2_SP                  3  9216  2048  1152

MPEG4_PART2_ASP                 5  9216  2048  1152

Output surface:

name              width height nat types

----------------------------------------------------

B8G8R8A8         16384 16384    y  NV12 YV12 UYVY YUYV Y8U8V8A8 V8U8Y8A8 A8I8 I8A8 

R8G8B8A8         16384 16384    y  NV12 YV12 UYVY YUYV Y8U8V8A8 V8U8Y8A8 A8I8 I8A8 

R10G10B10A2      16384 16384    y  NV12 YV12 UYVY YUYV Y8U8V8A8 V8U8Y8A8 A8I8 I8A8 

B10G10R10A2      16384 16384    y  NV12 YV12 UYVY YUYV Y8U8V8A8 V8U8Y8A8 A8I8 I8A8 

Bitmap surface:

name              width height

------------------------------

B8G8R8A8         16384 16384

R8G8B8A8         16384 16384

R10G10B10A2      16384 16384

B10G10R10A2      16384 16384

A8               16384 16384

Video mixer:

feature name                    sup

------------------------------------

DEINTERLACE_TEMPORAL             y

DEINTERLACE_TEMPORAL_SPATIAL     -

INVERSE_TELECINE                 -

NOISE_REDUCTION                  y

SHARPNESS                        y

LUMA_KEY                         -

parameter name                  sup      min      max

-----------------------------------------------------

VIDEO_SURFACE_WIDTH              y        48     2048

VIDEO_SURFACE_HEIGHT             y        48     1152

CHROMA_TYPE                      y  

LAYERS                           y         0        4

attribute name                  sup      min      max

-----------------------------------------------------

BACKGROUND_COLOR                 y  

CSC_MATRIX                       y  

NOISE_REDUCTION_LEVEL            y      0.00     1.00

SHARPNESS_LEVEL                  y     -1.00     1.00

LUMA_KEY_MIN_LUMA                y  

LUMA_KEY_MAX_LUMA                y
```

Two weeks ago, vdpauinfo wasn't reporting anything.

Obviously, what I thought I understood I actually don't. Though I will still stand by my contention that the OP needs to upgraade X and related components before his hardware capabilities are reported as he might expect.  :Wink:  One thing I hadn't understood for my case was that I needed to update VIDEO_CARDS in /etc/portage/make.conf:

```
VIDEO_CARDS="radeon radeonsi r600 amdgpu"
```

Two weeks ago on this same system, vdpauinfo only reported failure. Now, I'm somewhat confident everything which is currently available to me in terms of the versions of kernel, drivers, software and hardware is probably being reported. Take that with a very large block of salt.

----------

