Movatterモバイル変換


[0]ホーム

URL:


We bake cookies in your browser for a better experience. Using this site means that you consent.Read More

Menu

Qt Documentation

QGLFunctions Class

TheQGLFunctions class provides cross-platform access to theOpenGL/ES 2.0 API.More...

Header:#include <QGLFunctions>
Since: Qt 4.8

Public Types

enumOpenGLFeature { Multitexture, Shaders, Buffers, Framebuffers, ..., NPOTTextures }
flagsOpenGLFeatures

Public Functions

QGLFunctions()
QGLFunctions(const QGLContext * context)
~QGLFunctions()
voidglActiveTexture(GLenum texture)
voidglAttachShader(GLuint program, GLuint shader)
voidglBindAttribLocation(GLuint program, GLuint index, const char * name)
voidglBindBuffer(GLenum target, GLuint buffer)
voidglBindFramebuffer(GLenum target, GLuint framebuffer)
voidglBindRenderbuffer(GLenum target, GLuint renderbuffer)
voidglBlendColor(GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha)
voidglBlendEquation(GLenum mode)
voidglBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha)
voidglBlendFuncSeparate(GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha)
voidglBufferData(GLenum target, qgl_GLsizeiptr size, const void * data, GLenum usage)
voidglBufferSubData(GLenum target, qgl_GLintptr offset, qgl_GLsizeiptr size, const void * data)
GLenumglCheckFramebufferStatus(GLenum target)
voidglClearDepthf(GLclampf depth)
voidglCompileShader(GLuint shader)
voidglCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const void * data)
voidglCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const void * data)
GLuintglCreateProgram()
GLuintglCreateShader(GLenum type)
voidglDeleteBuffers(GLsizei n, const GLuint * buffers)
voidglDeleteFramebuffers(GLsizei n, const GLuint * framebuffers)
voidglDeleteProgram(GLuint program)
voidglDeleteRenderbuffers(GLsizei n, const GLuint * renderbuffers)
voidglDeleteShader(GLuint shader)
voidglDepthRangef(GLclampf zNear, GLclampf zFar)
voidglDetachShader(GLuint program, GLuint shader)
voidglDisableVertexAttribArray(GLuint index)
voidglEnableVertexAttribArray(GLuint index)
voidglFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
voidglFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
voidglGenBuffers(GLsizei n, GLuint * buffers)
voidglGenFramebuffers(GLsizei n, GLuint * framebuffers)
voidglGenRenderbuffers(GLsizei n, GLuint * renderbuffers)
voidglGenerateMipmap(GLenum target)
voidglGetActiveAttrib(GLuint program, GLuint index, GLsizei bufsize, GLsizei * length, GLint * size, GLenum * type, char * name)
voidglGetActiveUniform(GLuint program, GLuint index, GLsizei bufsize, GLsizei * length, GLint * size, GLenum * type, char * name)
voidglGetAttachedShaders(GLuint program, GLsizei maxcount, GLsizei * count, GLuint * shaders)
intglGetAttribLocation(GLuint program, const char * name)
voidglGetBufferParameteriv(GLenum target, GLenum pname, GLint * params)
voidglGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint * params)
voidglGetProgramInfoLog(GLuint program, GLsizei bufsize, GLsizei * length, char * infolog)
voidglGetProgramiv(GLuint program, GLenum pname, GLint * params)
voidglGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint * params)
voidglGetShaderInfoLog(GLuint shader, GLsizei bufsize, GLsizei * length, char * infolog)
voidglGetShaderPrecisionFormat(GLenum shadertype, GLenum precisiontype, GLint * range, GLint * precision)
voidglGetShaderSource(GLuint shader, GLsizei bufsize, GLsizei * length, char * source)
voidglGetShaderiv(GLuint shader, GLenum pname, GLint * params)
intglGetUniformLocation(GLuint program, const char * name)
voidglGetUniformfv(GLuint program, GLint location, GLfloat * params)
voidglGetUniformiv(GLuint program, GLint location, GLint * params)
voidglGetVertexAttribPointerv(GLuint index, GLenum pname, void ** pointer)
voidglGetVertexAttribfv(GLuint index, GLenum pname, GLfloat * params)
voidglGetVertexAttribiv(GLuint index, GLenum pname, GLint * params)
GLbooleanglIsBuffer(GLuint buffer)
GLbooleanglIsFramebuffer(GLuint framebuffer)
GLbooleanglIsProgram(GLuint program)
GLbooleanglIsRenderbuffer(GLuint renderbuffer)
GLbooleanglIsShader(GLuint shader)
voidglLinkProgram(GLuint program)
voidglReleaseShaderCompiler()
voidglRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height)
voidglSampleCoverage(GLclampf value, GLboolean invert)
voidglShaderBinary(GLint n, const GLuint * shaders, GLenum binaryformat, const void * binary, GLint length)
voidglShaderSource(GLuint shader, GLsizei count, const char ** string, const GLint * length)
voidglStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask)
voidglStencilMaskSeparate(GLenum face, GLuint mask)
voidglStencilOpSeparate(GLenum face, GLenum fail, GLenum zfail, GLenum zpass)
voidglUniform1f(GLint location, GLfloat x)
voidglUniform1fv(GLint location, GLsizei count, const GLfloat * v)
voidglUniform1i(GLint location, GLint x)
voidglUniform1iv(GLint location, GLsizei count, const GLint * v)
voidglUniform2f(GLint location, GLfloat x, GLfloat y)
voidglUniform2fv(GLint location, GLsizei count, const GLfloat * v)
voidglUniform2i(GLint location, GLint x, GLint y)
voidglUniform2iv(GLint location, GLsizei count, const GLint * v)
voidglUniform3f(GLint location, GLfloat x, GLfloat y, GLfloat z)
voidglUniform3fv(GLint location, GLsizei count, const GLfloat * v)
voidglUniform3i(GLint location, GLint x, GLint y, GLint z)
voidglUniform3iv(GLint location, GLsizei count, const GLint * v)
voidglUniform4f(GLint location, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
voidglUniform4fv(GLint location, GLsizei count, const GLfloat * v)
voidglUniform4i(GLint location, GLint x, GLint y, GLint z, GLint w)
voidglUniform4iv(GLint location, GLsizei count, const GLint * v)
voidglUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat * value)
voidglUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat * value)
voidglUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat * value)
voidglUseProgram(GLuint program)
voidglValidateProgram(GLuint program)
voidglVertexAttrib1f(GLuint indx, GLfloat x)
voidglVertexAttrib1fv(GLuint indx, const GLfloat * values)
voidglVertexAttrib2f(GLuint indx, GLfloat x, GLfloat y)
voidglVertexAttrib2fv(GLuint indx, const GLfloat * values)
voidglVertexAttrib3f(GLuint indx, GLfloat x, GLfloat y, GLfloat z)
voidglVertexAttrib3fv(GLuint indx, const GLfloat * values)
voidglVertexAttrib4f(GLuint indx, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
voidglVertexAttrib4fv(GLuint indx, const GLfloat * values)
voidglVertexAttribPointer(GLuint indx, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const void * ptr)
boolhasOpenGLFeature(QGLFunctions::OpenGLFeature feature) const
voidinitializeGLFunctions(const QGLContext * context = 0)
QGLFunctions::OpenGLFeaturesopenGLFeatures() const

Detailed Description

TheQGLFunctions class provides cross-platform access to theOpenGL/ES 2.0 API.

OpenGL/ES 2.0 defines a subset of theOpenGL specification that is common across many desktop and embeddedOpenGL implementations. However, it can be difficult to use the functions from that subset because they need to be resolved manually on desktop systems.

QGLFunctions provides a guaranteed API that is available on allOpenGL systems and takes care of function resolution on systems that need it. The recommended way to useQGLFunctions is by direct inheritance:

class MyGLWidget :publicQGLWidget,protectedQGLFunctions{    Q_OBJECTpublic:    MyGLWidget(QWidget*parent=0) :QGLWidget(parent) {}protected:void initializeGL();void paintGL();};void MyGLWidget::initializeGL(){    initializeGLFunctions();}

ThepaintGL() function can then use any of theOpenGL/ES 2.0 functions without explicit resolution, such asglActiveTexture() in the following example:

void MyGLWidget::paintGL(){    glActiveTexture(GL_TEXTURE1);    glBindTexture(GL_TEXTURE_2D, textureId);...}

QGLFunctions can also be used directly for ad-hoc invocation ofOpenGL/ES 2.0 functions on all platforms:

QGLFunctions glFuncs(QGLContext::currentContext());glFuncs.glActiveTexture(GL_TEXTURE1);

QGLFunctions provides wrappers for allOpenGL/ES 2.0 functions, except those likeglDrawArrays(),glViewport(), andglBindTexture() that don't have portability issues.

Including the header forQGLFunctions will also define all of theOpenGL/ES 2.0 macro constants that are not already defined by the system'sOpenGL headers, such asGL_TEXTURE1 above.

ThehasOpenGLFeature() andopenGLFeatures() functions can be used to determine if theOpenGL implementation has a majorOpenGL/ES 2.0 feature. For example, the following checks if non power of two textures are available:

QGLFunctions funcs(QGLContext::currentContext());bool npot= funcs.hasOpenGLFeature(QGLFunctions::NPOTTextures);

Member Type Documentation

enum QGLFunctions::OpenGLFeature
flags QGLFunctions::OpenGLFeatures

This enum definesOpenGL/ES 2.0 features that may be optional on other platforms.

ConstantValueDescription
QGLFunctions::Multitexture0x0001glActiveTexture() function is available.
QGLFunctions::Shaders0x0002Shader functions are available.
QGLFunctions::Buffers0x0004Vertex and index buffer functions are available.
QGLFunctions::Framebuffers0x0008Framebuffer object functions are available.
QGLFunctions::BlendColor0x0010glBlendColor() is available.
QGLFunctions::BlendEquation0x0020glBlendEquation() is available.
QGLFunctions::BlendEquationSeparate0x0040glBlendEquationSeparate() is available.
QGLFunctions::BlendFuncSeparate0x0080glBlendFuncSeparate() is available.
QGLFunctions::BlendSubtract0x0100Blend subtract mode is available.
QGLFunctions::CompressedTextures0x0200Compressed texture functions are available.
QGLFunctions::Multisample0x0400glSampleCoverage() function is available.
QGLFunctions::StencilSeparate0x0800Separate stencil functions are available.
QGLFunctions::NPOTTextures0x1000Non power of two textures are available.

The OpenGLFeatures type is a typedef forQFlags<OpenGLFeature>. It stores an OR combination of OpenGLFeature values.

Member Function Documentation

QGLFunctions::QGLFunctions()

Constructs a default function resolver. The resolver cannot be used untilinitializeGLFunctions() is called to specify the context.

See alsoinitializeGLFunctions().

QGLFunctions::QGLFunctions(constQGLContext * context)

Constructs a function resolver forcontext. Ifcontext is null, then the resolver will be created for the currentQGLContext.

An object constructed in this way can only be used withcontext and other contexts that share with it. UseinitializeGLFunctions() to change the object's context association.

See alsoinitializeGLFunctions().

QGLFunctions::~QGLFunctions()

Destroys this function resolver.

void QGLFunctions::glActiveTexture(GLenum texture)

Convenience function that calls glActiveTexture(texture).

For more information, see theOpenGL/ES 2.0 documentation forglActiveTexture().

void QGLFunctions::glAttachShader(GLuint program,GLuint shader)

Convenience function that calls glAttachShader(program,shader).

For more information, see theOpenGL/ES 2.0 documentation forglAttachShader().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glBindAttribLocation(GLuint program,GLuint index, constchar * name)

Convenience function that calls glBindAttribLocation(program,index,name).

For more information, see theOpenGL/ES 2.0 documentation forglBindAttribLocation().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glBindBuffer(GLenum target,GLuint buffer)

Convenience function that calls glBindBuffer(target,buffer).

For more information, see theOpenGL/ES 2.0 documentation forglBindBuffer().

void QGLFunctions::glBindFramebuffer(GLenum target,GLuint framebuffer)

Convenience function that calls glBindFramebuffer(target,framebuffer).

For more information, see theOpenGL/ES 2.0 documentation forglBindFramebuffer().

void QGLFunctions::glBindRenderbuffer(GLenum target,GLuint renderbuffer)

Convenience function that calls glBindRenderbuffer(target,renderbuffer).

For more information, see theOpenGL/ES 2.0 documentation forglBindRenderbuffer().

void QGLFunctions::glBlendColor(GLclampf red,GLclampf green,GLclampf blue,GLclampf alpha)

Convenience function that calls glBlendColor(red,green,blue,alpha).

For more information, see theOpenGL/ES 2.0 documentation forglBlendColor().

void QGLFunctions::glBlendEquation(GLenum mode)

Convenience function that calls glBlendEquation(mode).

For more information, see theOpenGL/ES 2.0 documentation forglBlendEquation().

void QGLFunctions::glBlendEquationSeparate(GLenum modeRGB,GLenum modeAlpha)

Convenience function that calls glBlendEquationSeparate(modeRGB,modeAlpha).

For more information, see theOpenGL/ES 2.0 documentation forglBlendEquationSeparate().

void QGLFunctions::glBlendFuncSeparate(GLenum srcRGB,GLenum dstRGB,GLenum srcAlpha,GLenum dstAlpha)

Convenience function that calls glBlendFuncSeparate(srcRGB,dstRGB,srcAlpha,dstAlpha).

For more information, see theOpenGL/ES 2.0 documentation forglBlendFuncSeparate().

void QGLFunctions::glBufferData(GLenum target,qgl_GLsizeiptr size, constvoid * data,GLenum usage)

Convenience function that calls glBufferData(target,size,data,usage).

For more information, see theOpenGL/ES 2.0 documentation forglBufferData().

void QGLFunctions::glBufferSubData(GLenum target,qgl_GLintptr offset,qgl_GLsizeiptr size, constvoid * data)

Convenience function that calls glBufferSubData(target,offset,size,data).

For more information, see theOpenGL/ES 2.0 documentation forglBufferSubData().

GLenum QGLFunctions::glCheckFramebufferStatus(GLenum target)

Convenience function that calls glCheckFramebufferStatus(target).

For more information, see theOpenGL/ES 2.0 documentation forglCheckFramebufferStatus().

void QGLFunctions::glClearDepthf(GLclampf depth)

Convenience function that calls glClearDepth(depth) on desktopOpenGL systems and glClearDepthf(depth) on embeddedOpenGL/ES systems.

For more information, see theOpenGL/ES 2.0 documentation forglClearDepthf().

void QGLFunctions::glCompileShader(GLuint shader)

Convenience function that calls glCompileShader(shader).

For more information, see theOpenGL/ES 2.0 documentation forglCompileShader().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glCompressedTexImage2D(GLenum target,GLint level,GLenum internalformat,GLsizei width,GLsizei height,GLint border,GLsizei imageSize, constvoid * data)

Convenience function that calls glCompressedTexImage2D(target,level,internalformat,width,height,border,imageSize,data).

For more information, see theOpenGL/ES 2.0 documentation forglCompressedTexImage2D().

void QGLFunctions::glCompressedTexSubImage2D(GLenum target,GLint level,GLint xoffset,GLint yoffset,GLsizei width,GLsizei height,GLenum format,GLsizei imageSize, constvoid * data)

Convenience function that calls glCompressedTexSubImage2D(target,level,xoffset,yoffset,width,height,format,imageSize,data).

For more information, see theOpenGL/ES 2.0 documentation forglCompressedTexSubImage2D().

GLuint QGLFunctions::glCreateProgram()

Convenience function that calls glCreateProgram().

For more information, see theOpenGL/ES 2.0 documentation forglCreateProgram().

This convenience function will do nothing onOpenGL/ES 1.x systems.

GLuint QGLFunctions::glCreateShader(GLenum type)

Convenience function that calls glCreateShader(type).

For more information, see theOpenGL/ES 2.0 documentation forglCreateShader().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glDeleteBuffers(GLsizei n, constGLuint * buffers)

Convenience function that calls glDeleteBuffers(n,buffers).

For more information, see theOpenGL/ES 2.0 documentation forglDeleteBuffers().

void QGLFunctions::glDeleteFramebuffers(GLsizei n, constGLuint * framebuffers)

Convenience function that calls glDeleteFramebuffers(n,framebuffers).

For more information, see theOpenGL/ES 2.0 documentation forglDeleteFramebuffers().

void QGLFunctions::glDeleteProgram(GLuint program)

Convenience function that calls glDeleteProgram(program).

For more information, see theOpenGL/ES 2.0 documentation forglDeleteProgram().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glDeleteRenderbuffers(GLsizei n, constGLuint * renderbuffers)

Convenience function that calls glDeleteRenderbuffers(n,renderbuffers).

For more information, see theOpenGL/ES 2.0 documentation forglDeleteRenderbuffers().

void QGLFunctions::glDeleteShader(GLuint shader)

Convenience function that calls glDeleteShader(shader).

For more information, see theOpenGL/ES 2.0 documentation forglDeleteShader().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glDepthRangef(GLclampf zNear,GLclampf zFar)

Convenience function that calls glDepthRange(zNear,zFar) on desktopOpenGL systems and glDepthRangef(zNear,zFar) on embeddedOpenGL/ES systems.

For more information, see theOpenGL/ES 2.0 documentation forglDepthRangef().

void QGLFunctions::glDetachShader(GLuint program,GLuint shader)

Convenience function that calls glDetachShader(program,shader).

For more information, see theOpenGL/ES 2.0 documentation forglDetachShader().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glDisableVertexAttribArray(GLuint index)

Convenience function that calls glDisableVertexAttribArray(index).

For more information, see theOpenGL/ES 2.0 documentation forglDisableVertexAttribArray().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glEnableVertexAttribArray(GLuint index)

Convenience function that calls glEnableVertexAttribArray(index).

For more information, see theOpenGL/ES 2.0 documentation forglEnableVertexAttribArray().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glFramebufferRenderbuffer(GLenum target,GLenum attachment,GLenum renderbuffertarget,GLuint renderbuffer)

Convenience function that calls glFramebufferRenderbuffer(target,attachment,renderbuffertarget,renderbuffer).

For more information, see theOpenGL/ES 2.0 documentation forglFramebufferRenderbuffer().

void QGLFunctions::glFramebufferTexture2D(GLenum target,GLenum attachment,GLenum textarget,GLuint texture,GLint level)

Convenience function that calls glFramebufferTexture2D(target,attachment,textarget,texture,level).

For more information, see theOpenGL/ES 2.0 documentation forglFramebufferTexture2D().

void QGLFunctions::glGenBuffers(GLsizei n,GLuint * buffers)

Convenience function that calls glGenBuffers(n,buffers).

For more information, see theOpenGL/ES 2.0 documentation forglGenBuffers().

void QGLFunctions::glGenFramebuffers(GLsizei n,GLuint * framebuffers)

Convenience function that calls glGenFramebuffers(n,framebuffers).

For more information, see theOpenGL/ES 2.0 documentation forglGenFramebuffers().

void QGLFunctions::glGenRenderbuffers(GLsizei n,GLuint * renderbuffers)

Convenience function that calls glGenRenderbuffers(n,renderbuffers).

For more information, see theOpenGL/ES 2.0 documentation forglGenRenderbuffers().

void QGLFunctions::glGenerateMipmap(GLenum target)

Convenience function that calls glGenerateMipmap(target).

For more information, see theOpenGL/ES 2.0 documentation forglGenerateMipmap().

void QGLFunctions::glGetActiveAttrib(GLuint program,GLuint index,GLsizei bufsize,GLsizei * length,GLint * size,GLenum * type,char * name)

Convenience function that calls glGetActiveAttrib(program,index,bufsize,length,size,type,name).

For more information, see theOpenGL/ES 2.0 documentation forglGetActiveAttrib().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glGetActiveUniform(GLuint program,GLuint index,GLsizei bufsize,GLsizei * length,GLint * size,GLenum * type,char * name)

Convenience function that calls glGetActiveUniform(program,index,bufsize,length,size,type,name).

For more information, see theOpenGL/ES 2.0 documentation forglGetActiveUniform().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glGetAttachedShaders(GLuint program,GLsizei maxcount,GLsizei * count,GLuint * shaders)

Convenience function that calls glGetAttachedShaders(program,maxcount,count,shaders).

For more information, see theOpenGL/ES 2.0 documentation forglGetAttachedShaders().

This convenience function will do nothing onOpenGL/ES 1.x systems.

int QGLFunctions::glGetAttribLocation(GLuint program, constchar * name)

Convenience function that calls glGetAttribLocation(program,name).

For more information, see theOpenGL/ES 2.0 documentation forglGetAttribLocation().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glGetBufferParameteriv(GLenum target,GLenum pname,GLint * params)

Convenience function that calls glGetBufferParameteriv(target,pname,params).

For more information, see theOpenGL/ES 2.0 documentation forglGetBufferParameteriv().

void QGLFunctions::glGetFramebufferAttachmentParameteriv(GLenum target,GLenum attachment,GLenum pname,GLint * params)

Convenience function that calls glGetFramebufferAttachmentParameteriv(target,attachment,pname,params).

For more information, see theOpenGL/ES 2.0 documentation forglGetFramebufferAttachmentParameteriv().

void QGLFunctions::glGetProgramInfoLog(GLuint program,GLsizei bufsize,GLsizei * length,char * infolog)

Convenience function that calls glGetProgramInfoLog(program,bufsize,length,infolog).

For more information, see theOpenGL/ES 2.0 documentation forglGetProgramInfoLog().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glGetProgramiv(GLuint program,GLenum pname,GLint * params)

Convenience function that calls glGetProgramiv(program,pname,params).

For more information, see theOpenGL/ES 2.0 documentation forglGetProgramiv().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glGetRenderbufferParameteriv(GLenum target,GLenum pname,GLint * params)

Convenience function that calls glGetRenderbufferParameteriv(target,pname,params).

For more information, see theOpenGL/ES 2.0 documentation forglGetRenderbufferParameteriv().

void QGLFunctions::glGetShaderInfoLog(GLuint shader,GLsizei bufsize,GLsizei * length,char * infolog)

Convenience function that calls glGetShaderInfoLog(shader,bufsize,length,infolog).

For more information, see theOpenGL/ES 2.0 documentation forglGetShaderInfoLog().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glGetShaderPrecisionFormat(GLenum shadertype,GLenum precisiontype,GLint * range,GLint * precision)

Convenience function that calls glGetShaderPrecisionFormat(shadertype,precisiontype,range,precision).

For more information, see theOpenGL/ES 2.0 documentation forglGetShaderPrecisionFormat().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glGetShaderSource(GLuint shader,GLsizei bufsize,GLsizei * length,char * source)

Convenience function that calls glGetShaderSource(shader,bufsize,length,source).

For more information, see theOpenGL/ES 2.0 documentation forglGetShaderSource().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glGetShaderiv(GLuint shader,GLenum pname,GLint * params)

Convenience function that calls glGetShaderiv(shader,pname,params).

For more information, see theOpenGL/ES 2.0 documentation forglGetShaderiv().

This convenience function will do nothing onOpenGL/ES 1.x systems.

int QGLFunctions::glGetUniformLocation(GLuint program, constchar * name)

Convenience function that calls glGetUniformLocation(program,name).

For more information, see theOpenGL/ES 2.0 documentation forglGetUniformLocation().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glGetUniformfv(GLuint program,GLint location,GLfloat * params)

Convenience function that calls glGetUniformfv(program,location,params).

For more information, see theOpenGL/ES 2.0 documentation forglGetUniformfv().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glGetUniformiv(GLuint program,GLint location,GLint * params)

Convenience function that calls glGetUniformiv(program,location,params).

For more information, see theOpenGL/ES 2.0 documentation forglGetUniformiv().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glGetVertexAttribPointerv(GLuint index,GLenum pname,void ** pointer)

Convenience function that calls glGetVertexAttribPointerv(index,pname,pointer).

For more information, see theOpenGL/ES 2.0 documentation forglGetVertexAttribPointerv().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glGetVertexAttribfv(GLuint index,GLenum pname,GLfloat * params)

Convenience function that calls glGetVertexAttribfv(index,pname,params).

For more information, see theOpenGL/ES 2.0 documentation forglGetVertexAttribfv().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glGetVertexAttribiv(GLuint index,GLenum pname,GLint * params)

Convenience function that calls glGetVertexAttribiv(index,pname,params).

For more information, see theOpenGL/ES 2.0 documentation forglGetVertexAttribiv().

This convenience function will do nothing onOpenGL/ES 1.x systems.

GLboolean QGLFunctions::glIsBuffer(GLuint buffer)

Convenience function that calls glIsBuffer(buffer).

For more information, see theOpenGL/ES 2.0 documentation forglIsBuffer().

GLboolean QGLFunctions::glIsFramebuffer(GLuint framebuffer)

Convenience function that calls glIsFramebuffer(framebuffer).

For more information, see theOpenGL/ES 2.0 documentation forglIsFramebuffer().

GLboolean QGLFunctions::glIsProgram(GLuint program)

Convenience function that calls glIsProgram(program).

For more information, see theOpenGL/ES 2.0 documentation forglIsProgram().

This convenience function will do nothing onOpenGL/ES 1.x systems.

GLboolean QGLFunctions::glIsRenderbuffer(GLuint renderbuffer)

Convenience function that calls glIsRenderbuffer(renderbuffer).

For more information, see theOpenGL/ES 2.0 documentation forglIsRenderbuffer().

GLboolean QGLFunctions::glIsShader(GLuint shader)

Convenience function that calls glIsShader(shader).

For more information, see theOpenGL/ES 2.0 documentation forglIsShader().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glLinkProgram(GLuint program)

Convenience function that calls glLinkProgram(program).

For more information, see theOpenGL/ES 2.0 documentation forglLinkProgram().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glReleaseShaderCompiler()

Convenience function that calls glReleaseShaderCompiler().

For more information, see theOpenGL/ES 2.0 documentation forglReleaseShaderCompiler().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glRenderbufferStorage(GLenum target,GLenum internalformat,GLsizei width,GLsizei height)

Convenience function that calls glRenderbufferStorage(target,internalformat,width,height).

For more information, see theOpenGL/ES 2.0 documentation forglRenderbufferStorage().

void QGLFunctions::glSampleCoverage(GLclampf value,GLboolean invert)

Convenience function that calls glSampleCoverage(value,invert).

For more information, see theOpenGL/ES 2.0 documentation forglSampleCoverage().

void QGLFunctions::glShaderBinary(GLint n, constGLuint * shaders,GLenum binaryformat, constvoid * binary,GLint length)

Convenience function that calls glShaderBinary(n,shaders,binaryformat,binary,length).

For more information, see theOpenGL/ES 2.0 documentation forglShaderBinary().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glShaderSource(GLuint shader,GLsizei count, constchar ** string, constGLint * length)

Convenience function that calls glShaderSource(shader,count,string,length).

For more information, see theOpenGL/ES 2.0 documentation forglShaderSource().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glStencilFuncSeparate(GLenum face,GLenum func,GLint ref,GLuint mask)

Convenience function that calls glStencilFuncSeparate(face,func,ref,mask).

For more information, see theOpenGL/ES 2.0 documentation forglStencilFuncSeparate().

void QGLFunctions::glStencilMaskSeparate(GLenum face,GLuint mask)

Convenience function that calls glStencilMaskSeparate(face,mask).

For more information, see theOpenGL/ES 2.0 documentation forglStencilMaskSeparate().

void QGLFunctions::glStencilOpSeparate(GLenum face,GLenum fail,GLenum zfail,GLenum zpass)

Convenience function that calls glStencilOpSeparate(face,fail,zfail,zpass).

For more information, see theOpenGL/ES 2.0 documentation forglStencilOpSeparate().

void QGLFunctions::glUniform1f(GLint location,GLfloat x)

Convenience function that calls glUniform1f(location,x).

For more information, see theOpenGL/ES 2.0 documentation forglUniform1f().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glUniform1fv(GLint location,GLsizei count, constGLfloat * v)

Convenience function that calls glUniform1fv(location,count,v).

For more information, see theOpenGL/ES 2.0 documentation forglUniform1fv().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glUniform1i(GLint location,GLint x)

Convenience function that calls glUniform1i(location,x).

For more information, see theOpenGL/ES 2.0 documentation forglUniform1i().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glUniform1iv(GLint location,GLsizei count, constGLint * v)

Convenience function that calls glUniform1iv(location,count,v).

For more information, see theOpenGL/ES 2.0 documentation forglUniform1iv().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glUniform2f(GLint location,GLfloat x,GLfloat y)

Convenience function that calls glUniform2f(location,x,y).

For more information, see theOpenGL/ES 2.0 documentation forglUniform2f().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glUniform2fv(GLint location,GLsizei count, constGLfloat * v)

Convenience function that calls glUniform2fv(location,count,v).

For more information, see theOpenGL/ES 2.0 documentation forglUniform2fv().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glUniform2i(GLint location,GLint x,GLint y)

Convenience function that calls glUniform2i(location,x,y).

For more information, see theOpenGL/ES 2.0 documentation forglUniform2i().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glUniform2iv(GLint location,GLsizei count, constGLint * v)

Convenience function that calls glUniform2iv(location,count,v).

For more information, see theOpenGL/ES 2.0 documentation forglUniform2iv().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glUniform3f(GLint location,GLfloat x,GLfloat y,GLfloat z)

Convenience function that calls glUniform3f(location,x,y,z).

For more information, see theOpenGL/ES 2.0 documentation forglUniform3f().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glUniform3fv(GLint location,GLsizei count, constGLfloat * v)

Convenience function that calls glUniform3fv(location,count,v).

For more information, see theOpenGL/ES 2.0 documentation forglUniform3fv().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glUniform3i(GLint location,GLint x,GLint y,GLint z)

Convenience function that calls glUniform3i(location,x,y,z).

For more information, see theOpenGL/ES 2.0 documentation forglUniform3i().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glUniform3iv(GLint location,GLsizei count, constGLint * v)

Convenience function that calls glUniform3iv(location,count,v).

For more information, see theOpenGL/ES 2.0 documentation forglUniform3iv().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glUniform4f(GLint location,GLfloat x,GLfloat y,GLfloat z,GLfloat w)

Convenience function that calls glUniform4f(location,x,y,z,w).

For more information, see theOpenGL/ES 2.0 documentation forglUniform4f().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glUniform4fv(GLint location,GLsizei count, constGLfloat * v)

Convenience function that calls glUniform4fv(location,count,v).

For more information, see theOpenGL/ES 2.0 documentation forglUniform4fv().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glUniform4i(GLint location,GLint x,GLint y,GLint z,GLint w)

Convenience function that calls glUniform4i(location,x,y,z,w).

For more information, see theOpenGL/ES 2.0 documentation forglUniform4i().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glUniform4iv(GLint location,GLsizei count, constGLint * v)

Convenience function that calls glUniform4iv(location,count,v).

For more information, see theOpenGL/ES 2.0 documentation forglUniform4iv().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glUniformMatrix2fv(GLint location,GLsizei count,GLboolean transpose, constGLfloat * value)

Convenience function that calls glUniformMatrix2fv(location,count,transpose,value).

For more information, see theOpenGL/ES 2.0 documentation forglUniformMatrix2fv().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glUniformMatrix3fv(GLint location,GLsizei count,GLboolean transpose, constGLfloat * value)

Convenience function that calls glUniformMatrix3fv(location,count,transpose,value).

For more information, see theOpenGL/ES 2.0 documentation forglUniformMatrix3fv().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glUniformMatrix4fv(GLint location,GLsizei count,GLboolean transpose, constGLfloat * value)

Convenience function that calls glUniformMatrix4fv(location,count,transpose,value).

For more information, see theOpenGL/ES 2.0 documentation forglUniformMatrix4fv().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glUseProgram(GLuint program)

Convenience function that calls glUseProgram(program).

For more information, see theOpenGL/ES 2.0 documentation forglUseProgram().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glValidateProgram(GLuint program)

Convenience function that calls glValidateProgram(program).

For more information, see theOpenGL/ES 2.0 documentation forglValidateProgram().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glVertexAttrib1f(GLuint indx,GLfloat x)

Convenience function that calls glVertexAttrib1f(indx,x).

For more information, see theOpenGL/ES 2.0 documentation forglVertexAttrib1f().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glVertexAttrib1fv(GLuint indx, constGLfloat * values)

Convenience function that calls glVertexAttrib1fv(indx,values).

For more information, see theOpenGL/ES 2.0 documentation forglVertexAttrib1fv().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glVertexAttrib2f(GLuint indx,GLfloat x,GLfloat y)

Convenience function that calls glVertexAttrib2f(indx,x,y).

For more information, see theOpenGL/ES 2.0 documentation forglVertexAttrib2f().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glVertexAttrib2fv(GLuint indx, constGLfloat * values)

Convenience function that calls glVertexAttrib2fv(indx,values).

For more information, see theOpenGL/ES 2.0 documentation forglVertexAttrib2fv().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glVertexAttrib3f(GLuint indx,GLfloat x,GLfloat y,GLfloat z)

Convenience function that calls glVertexAttrib3f(indx,x,y,z).

For more information, see theOpenGL/ES 2.0 documentation forglVertexAttrib3f().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glVertexAttrib3fv(GLuint indx, constGLfloat * values)

Convenience function that calls glVertexAttrib3fv(indx,values).

For more information, see theOpenGL/ES 2.0 documentation forglVertexAttrib3fv().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glVertexAttrib4f(GLuint indx,GLfloat x,GLfloat y,GLfloat z,GLfloat w)

Convenience function that calls glVertexAttrib4f(indx,x,y,z,w).

For more information, see theOpenGL/ES 2.0 documentation forglVertexAttrib4f().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glVertexAttrib4fv(GLuint indx, constGLfloat * values)

Convenience function that calls glVertexAttrib4fv(indx,values).

For more information, see theOpenGL/ES 2.0 documentation forglVertexAttrib4fv().

This convenience function will do nothing onOpenGL/ES 1.x systems.

void QGLFunctions::glVertexAttribPointer(GLuint indx,GLint size,GLenum type,GLboolean normalized,GLsizei stride, constvoid * ptr)

Convenience function that calls glVertexAttribPointer(indx,size,type,normalized,stride,ptr).

For more information, see theOpenGL/ES 2.0 documentation forglVertexAttribPointer().

This convenience function will do nothing onOpenGL/ES 1.x systems.

bool QGLFunctions::hasOpenGLFeature(QGLFunctions::OpenGLFeature feature) const

Returns true iffeature is present on this system'sOpenGL implementation; false otherwise.

It is assumed that theQGLContext associated with this function resolver is current.

See alsoopenGLFeatures().

void QGLFunctions::initializeGLFunctions(constQGLContext * context = 0)

Initializes GL function resolution forcontext. Ifcontext is null, then the currentQGLContext will be used.

After calling this function, theQGLFunctions object can only be used withcontext and other contexts that share with it. Call initializeGLFunctions() again to change the object's context association.

QGLFunctions::OpenGLFeatures QGLFunctions::openGLFeatures() const

Returns the set of features that are present on this system'sOpenGL implementation.

It is assumed that theQGLContext associated with this function resolver is current.

See alsohasOpenGLFeature().

© 2016 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of theGNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.


[8]ページ先頭

©2009-2025 Movatter.jp