为什么 MESA 不让我使用 OpenGL 4.5(或 3.0 以外的任何版本)?
Why won't MESA let me use OpenGL 4.5 (or anything but 3.0)?
我已经安装了最新版本的 MESA (17.0.3),这应该允许我使用高于 3.0 的 OpenGL(对吗?)
问题:我卡在了 3.0 版。 (我的意思是我不知道如何让 MESA 使用更高版本,或者即使我可以)我知道我的电脑(Chromebook 运行 crouton for linux)具有 OpenGL 4.5 功能。 .. 但我对 MESA 也一无所知 :\.
我知道您可以使用 glxinfo 获取有关 OpenGL 等的信息,所以这是我目前可以提供的最佳信息。
OpenGL vendor string: Intel Open Source Technology Center
OpenGL renderer string: Mesa DRI Intel(R) HD Graphics 400 (Braswell)
OpenGL core profile version string: 4.5 (Core Profile) Mesa 17.0.3
OpenGL core profile shading language version string: 4.50
OpenGL core profile context flags: (none)
OpenGL core profile profile mask: core profile
OpenGL core profile extensions:
OpenGL version string: 3.0 Mesa 17.0.3
OpenGL shading language version string: 1.30
OpenGL context flags: (none)
OpenGL extensions:
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
OpenGL ES profile extensions:
在此先致谢,如有任何帮助,我们将不胜感激:)
此外,对于加分,如果有人知道 'Core Profile Version' 是什么,我很想知道:)
注意版本字符串出现了3次(我们忽略着色语言版本字符串):
OpenGL core profile version string: 4.5 (Core Profile) Mesa 17.0.3
...
OpenGL version string: 3.0 Mesa 17.0.3
...
OpenGL ES profile version string: OpenGL ES 3.1 Mesa 17.0.3
因此,如果您创建核心上下文,您将获得 4.5。如果您创建一个非核心(兼容性)上下文,您将获得 3.0。如果你创建一个 ES 上下文,你会得到 3.1.
因此,如果您想使用 OpenGL 4.5,则必须请求核心上下文。兼容性上下文是默认的。关于如何创建核心上下文的信息将在您用于创建 OpenGL 上下文(GLFW、SDL 或其他)的任何 API 的文档中。
(非 Mesa)供应商驱动程序的行为方式不同,即使您 select 兼容性上下文,它们也会提供最新版本。但是,Mesa 和 macOS 驱动程序只会为您提供更新的核心上下文版本。
我已经安装了最新版本的 MESA (17.0.3),这应该允许我使用高于 3.0 的 OpenGL(对吗?)
问题:我卡在了 3.0 版。 (我的意思是我不知道如何让 MESA 使用更高版本,或者即使我可以)我知道我的电脑(Chromebook 运行 crouton for linux)具有 OpenGL 4.5 功能。 .. 但我对 MESA 也一无所知 :\.
我知道您可以使用 glxinfo 获取有关 OpenGL 等的信息,所以这是我目前可以提供的最佳信息。
OpenGL vendor string: Intel Open Source Technology Center
OpenGL renderer string: Mesa DRI Intel(R) HD Graphics 400 (Braswell)
OpenGL core profile version string: 4.5 (Core Profile) Mesa 17.0.3
OpenGL core profile shading language version string: 4.50
OpenGL core profile context flags: (none)
OpenGL core profile profile mask: core profile
OpenGL core profile extensions:
OpenGL version string: 3.0 Mesa 17.0.3
OpenGL shading language version string: 1.30
OpenGL context flags: (none)
OpenGL extensions:
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
OpenGL ES profile extensions:
在此先致谢,如有任何帮助,我们将不胜感激:)
此外,对于加分,如果有人知道 'Core Profile Version' 是什么,我很想知道:)
注意版本字符串出现了3次(我们忽略着色语言版本字符串):
OpenGL core profile version string: 4.5 (Core Profile) Mesa 17.0.3 ... OpenGL version string: 3.0 Mesa 17.0.3 ... OpenGL ES profile version string: OpenGL ES 3.1 Mesa 17.0.3
因此,如果您创建核心上下文,您将获得 4.5。如果您创建一个非核心(兼容性)上下文,您将获得 3.0。如果你创建一个 ES 上下文,你会得到 3.1.
因此,如果您想使用 OpenGL 4.5,则必须请求核心上下文。兼容性上下文是默认的。关于如何创建核心上下文的信息将在您用于创建 OpenGL 上下文(GLFW、SDL 或其他)的任何 API 的文档中。
(非 Mesa)供应商驱动程序的行为方式不同,即使您 select 兼容性上下文,它们也会提供最新版本。但是,Mesa 和 macOS 驱动程序只会为您提供更新的核心上下文版本。