diff options
author | Rhys Weatherley <rhys.weatherley@nokia.com> | 2009-06-04 00:13:54 (GMT) |
---|---|---|
committer | Rhys Weatherley <rhys.weatherley@nokia.com> | 2009-06-04 00:13:54 (GMT) |
commit | 7010a53cbd6bc6d9cc6d63e2170a7300ce2750d8 (patch) | |
tree | 323233749dd13a97bb01272d32e3cee1f4f57d44 /src/opengl/qglshaderprogram.h | |
parent | 55148bf3c47546a93222c3e48a3e1bad062b5640 (diff) | |
download | Qt-7010a53cbd6bc6d9cc6d63e2170a7300ce2750d8.zip Qt-7010a53cbd6bc6d9cc6d63e2170a7300ce2750d8.tar.gz Qt-7010a53cbd6bc6d9cc6d63e2170a7300ce2750d8.tar.bz2 |
Improvements to shader API in response to API review
Task-number: QT-80
Reviewed-by: Ian Walters
Diffstat (limited to 'src/opengl/qglshaderprogram.h')
-rw-r--r-- | src/opengl/qglshaderprogram.h | 16 |
1 files changed, 6 insertions, 10 deletions
diff --git a/src/opengl/qglshaderprogram.h b/src/opengl/qglshaderprogram.h index b69d28e..ab30c32 100644 --- a/src/opengl/qglshaderprogram.h +++ b/src/opengl/qglshaderprogram.h @@ -79,17 +79,15 @@ public: QGLShader(const QString& fileName, QGLShader::ShaderType type, const QGLContext *context, QObject *parent = 0); virtual ~QGLShader(); - bool isValid() const; - QGLShader::ShaderType shaderType() const; - bool setSourceCode(const char *source); - bool setSourceCode(const QByteArray& source); - bool setSourceCode(const QString& source); - bool setSourceCodeFile(const QString& fileName); + bool compile(const char *source); + bool compile(const QByteArray& source); + bool compile(const QString& source); + bool compileFile(const QString& fileName); - bool setBinaryCode(GLenum format, const void *binary, int length); - bool setBinaryCode(QGLShader& otherShader, GLenum format, const void *binary, int length); + bool setShaderBinary(GLenum format, const void *binary, int length); + bool setShaderBinary(QGLShader& otherShader, GLenum format, const void *binary, int length); static QList<GLenum> shaderBinaryFormats(); @@ -118,8 +116,6 @@ public: explicit QGLShaderProgram(const QGLContext *context, QObject *parent = 0); virtual ~QGLShaderProgram(); - bool isValid() const; - bool addShader(QGLShader *shader); void removeShader(QGLShader *shader); QList<QGLShader *> shaders() const; |