QGLShader Class
The QGLShader class allows OpenGL shaders to be compiled. More...
| Header: | #include <QGLShader> |
| qmake: | QT += opengl |
| Since: | Qt 4.6 |
| Inherits: | QObject |
This class is obsolete. It is provided to keep old source code working. We strongly advise against using it in new code.
This class was introduced in Qt 4.6.
Public Types
| enum | ShaderTypeBit { Vertex, Fragment, Geometry } |
Detailed Description
This class supports shaders written in the OpenGL Shading Language (GLSL) and in the OpenGL/ES Shading Language (GLSL/ES).
QGLShader and QGLShaderProgram shelter the programmer from the details of compiling and linking vertex and fragment shaders.
Note: This class has been deprecated in favor of QOpenGLShader.
See also QGLShaderProgram.
Member Type Documentation
enum QGLShader::ShaderTypeBit
This enum specifies the type of QGLShader that is being created.
| Constant | Value | Description |
|---|---|---|
QGLShader::Vertex | 0x0001 | Vertex shader written in the OpenGL Shading Language (GLSL). |
QGLShader::Fragment | 0x0002 | Fragment shader written in the OpenGL Shading Language (GLSL). |
QGLShader::Geometry | 0x0004 | Geometry shaders written in the OpenGL Shading Language (GLSL), based on the GL_EXT_geometry_shader4 extension. |