[About] [News] [Documentation] [Screenshots]
Name
bugle-contextattribs — override attributes during context creation
Synopsis
filterset contextattribs { major 3 minor 3 flag "debug" flag "robust" profile "core" profile "!compatibility" }
Description
The GLX_ARB_context_create and GLX_ARB_context_create_profile extensions allow applications extra control over how contexts are created. Applications can specify a GL version, select flags that modify the operation of the context, or specify which GL profiles they wish to use.
The contextattribs
filter-set allows these
attributes to be overridden on an existing application. There are
a number of reasons this might be desirable:
If the application is using a framework that does not allow these attributes to be specified, this may be the easiest way to do so.
Forcing the core profile can be used to identify areas of the application that rely on the compatibility profile.
Forcing a debug context will allow the bugle-logdebug(7) filter-set to record debugging information from the driver.
The interface provided is fairly low-level. The major version, the minor version, and each bit in the flags and the profile mask can be either left alone or set to a specific value. There are no checks that the requested combination makes sense e.g., versions of GL before 3.2 did not have profiles.
Options
major
Specifies a value for GLX_CONTEXT_MAJOR_VERSION_ARB.
minor
Specifies a value for GLX_CONTEXT_MINOR_VERSION_ARB.
flag
Specifies a flag to be added or removed from GLX_CONTEXT_FLAGS_ARB. The available flags are
debug
,forward
androbust
. By default a flag is added to the flag mask, but if preceeded by a!
it is removed.This option may be given multiple times to override multiple flags. Specifying that a flag should be both added and removed has undefined results.
profile
This option works similarly to
flag
except that it affects GLX_CONTEXT_PROFILE_MASK_ARB. The available profiles arecore
,compatibility
andes2
.Note that because this is a mask, the correct way to force core profile is to specify both
core
and!compatibility
.