Go to: Synopsis. Return value. Keywords. Flags. Python examples.

Synopsis

openGLExtension([extension=string], [renderer=boolean], [vendor=boolean], [version=boolean])

Note: Strings representing object names and arguments must be separated by commas. This is not depicted in the synopsis.

openGLExtension is NOT undoable, NOT queryable, and NOT editable.

Command returns the extension name depending on whether a given OpenGL extension is supported or not. The input is the extension string to the -extension flag. If the -extension flag is not used, or if the string argument to this flag is an empty string than all extension names are returned in a single string. If the extension exists it is not necessary true that the extension is supported. This command can only be used when a modeling view has been created. Otherwise no extensions will have been initialized and the resulting string will always be the empty string.

Return value

stringThe supported string(s)

Keywords

OpenGL, GL, extensions

Flags

extension, renderer, vendor, version
Long name (short name) Argument types Properties
extension(ext) string create
Specifies the OpenGL extension to query.
renderer(rnd) boolean create
Specifies to query the OpenGL renderer.
vendor(vnd) boolean create
Specifies to query the company responsible for the OpenGL implementation.
version(ver) boolean create
Specifies to query the OpenGL version.

Flag can appear in Create mode of command Flag can appear in Edit mode of command
Flag can appear in Query mode of command Flag can have multiple arguments, passed either as a tuple or a list.

Python examples

import maya.cmds as cmds

# Query for the multitexturing extension GL_ARB_multitexture
cmds.openGLExtension( extension='GL_ARB_multitexture' )

# Query for all the extensions
cmds.openGLExtension( extension='' )

# Query for the renderer name
cmds.openGLExtension( renderer=True )

# Query for the vendor
cmds.openGLExtension( vendor=True )

# Query for the OpenGL version
cmds.openGLExtension( version=True )