summaryrefslogtreecommitdiffstats
path: root/src/opengl/qglshaderprogram.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Merge remote branch 'origin/4.7' into qt-master-from-4.7Olivier Goffart2011-01-171-1/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: examples/webkit/imageanalyzer/imageanalyzer.h examples/webkit/imageanalyzer/mainwindow.h mkspecs/unsupported/qws/linux-x86-openkode-g++/qplatformdefs.h src/corelib/io/qfsfileengine_iterator_unix.cpp src/corelib/io/qfsfileengine_iterator_win.cpp src/corelib/kernel/qcoreapplication.cpp src/network/access/qnetworkaccessdatabackend.cpp src/plugins/bearer/connman/qconnmanservice_linux.cpp src/plugins/platforms/openvglite/qwindowsurface_vglite.h src/s60installs/bwins/QtCoreu.def src/s60installs/eabi/QtCoreu.def src/s60installs/s60installs.pro tools/assistant/tools/assistant/helpviewer_qwv.h tools/qdoc3/test/qt-html-templates.qdocconf
| * Update copyright year to 2011.Jason McDonald2011-01-101-1/+1
| | | | | | | | Reviewed-by: Trust Me
* | print out which GLSL shader that failed compilation for better debuggingGunnar Sletta2010-11-281-2/+19
|/
* Revert "Don't define highp/mediump/lowp if desktop GL has them"Trond Kjernåsen2010-10-121-8/+2
| | | | | | | | | | This reverts commit 6155050f68cc86c445552da61a5f240c16f5e2cd. The GL_ARB_ES2_compatibility extension does not mention the lowp, mediump or highp keywords. Task-number: QTBUG-14384 Reviewed-by: Samuel Reviewed-by: Prasanth
* Merge remote branch 'origin/4.6' into qt-4.7-from-4.6Thiago Macieira2010-08-261-2/+8
|\ | | | | | | | | | | | | Conflicts: bin/syncqt src/opengl/qgl.cpp tools/configure/configureapp.cpp
| * Don't define highp/mediump/lowp if desktop GL has themRhys Weatherley2010-08-131-2/+8
| | | | | | | | | | | | | | | | | | | | OpenGL 4.0 systems now have compatibility with ES2, including support for the precision qualifiers. If the GL_ARB_ES2_compatibility extension is present, then we don't define highp/mediump/lowp to the empty string. Task-number: QTBUG-12862 Reviewed-by: Sarah Smith
* | Merge remote branch 'origin/4.6' into qt-4.7-from-4.6Thiago Macieira2010-08-111-1/+1
|\ \ | |/ | | | | | | | | | | | | Conflicts: src/gui/kernel/qt_s60_p.h src/opengl/qglextensions.cpp src/opengl/qglshaderprogram.cpp tests/auto/mediaobject/tst_mediaobject.cpp
| * setUniformValue(QSize) was setting (w,w) not (w,h)Rhys Weatherley2010-08-031-1/+1
| | | | | | | | | | Task-number: QTBUG-12591 Reviewed-by: Daniel Pope
* | Normalize integers when calling glVertexAttribPointer()Rhys Weatherley2010-06-241-2/+2
| | | | | | | | | | | | | | | | | | | | When QGLShaderProgram::setAttributeArray() is used with a type like GL_UNSIGNED_BYTE, it is normally going to be a value that should be normalized to the range 0..1. But the function wasn't normalizing, which led to errors in programs that used per-vertex colors with the 4ub representation. Reviewed-by: Sarah Smith
* | Merge remote branch 'origin/4.6' into qt-4.7-from-4.6Thiago Macieira2010-04-091-6/+13
|\ \ | |/ | | | | | | Conflicts: src/multimedia/audio/qaudioinput_win32_p.h
| * Allow attributes to be bound after a QGLShaderProgram is linked.Rhys Weatherley2010-03-311-6/+13
| | | | | | | | | | Task-number: QTBUG-9450 Reviewed-by: Sarah Smith
* | Compile Qt in C++0x mode.Thiago Macieira2010-03-201-9/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | This is not valid in C++0x: char str[] = { 128, 0 }; Because 128 cannot be represented in a char. The same applies to conversion from int to qreal: it's a narrowing conversion, with possible data loss. More info: http://www2.research.att.com/~bs/C++0xFAQ.html#narrowing Reviewed-by: Trust Me
* | doc: Fixed some qdoc errors.Martin Smith2010-02-161-6/+5
| |
* | Merge branch 'master' of scm.dev.nokia.troll.no:qt/oslo-staging-1 into ↵Qt Continuous Integration System2010-02-121-1/+1
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | master-integration * 'master' of scm.dev.nokia.troll.no:qt/oslo-staging-1: (21 commits) Fix bug in QDirPrivate::setPath, affecting QDir::cd, cdUp and setPath Wrong cursor shown by the parent window after setOverrideCursor(). Fixed Mac OS X compile time error by using GLint for temp. qdoc3: Added curly braces in switch statement for braindead compiler. qdoc: Added a build rule for the documentation - disabled by default. Doc: Added the qdoc manual to the repository for future maintenance. qdoc3: Fixed bug in creation of qt.pageindex. qdoc3: Added capability to create qt.pageindex. Incorrect property setter generated by dumpcpp for Microsoft Word 2007. Cocoa: Implement our own NSApplication subclass Cocoa: Menu in menubar stays highlighted qdoc: Made a temporary fix for comment highlighting. Doc: Tidied up the class layout and removed an unnecessary image. Doc/qdoc: Use Chinese titles; canonicalize titles with non-ASCII chars. Doc/qdoc: Converted encoding of ISO-8859-1 docs to UTF-8. Output UTF-8. qdoc: Removed debugging code. Doc: Updated the configuration file for the Simplified Chinese docs. qdoc: Standardized encoding names and updated the Chinese config files. Doc: Added Simplified Chinese documents and build rules for them. qdoc: Added support for different source and output character encodings. ...
| * | Fixed Mac OS X compile time error by using GLint for temp.Martin Smith2010-02-111-1/+1
| | | | | | | | | | | | The GLint is then returned as an int, which is ok.
* | | Added \since 4.7 tagsGunnar Sletta2010-02-101-0/+14
|/ /
* | Added geometry shaders to changes-4.7.0 file + a small doc update about itGunnar Sletta2010-02-101-0/+2
| |
* | Merge branch 'geometry-shaders-to-integrate'Gunnar Sletta2010-02-081-4/+156
|\ \ | | | | | | | | | | | | Conflicts: src/opengl/qglshaderprogram.cpp
| * | Another round of Geometry shader review.Gunnar Sletta2010-02-081-13/+5
| | | | | | | | | | | | Reviewed-by: Trond
| * | Fix Geometry shaders based on reviewGunnar Sletta2010-02-041-9/+15
| | |
| * | Geometry Shader support in QGLShaderProgramGunnar Sletta2010-02-011-0/+153
| | |
* | | Merge branch 'master' of scm.dev.nokia.troll.no:qt/oslo-staging-1 into ↵Qt Continuous Integration System2010-02-051-14/+16
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | master-integration * 'master' of scm.dev.nokia.troll.no:qt/oslo-staging-1: doc: Fixed some qdoc warnings. doc: Fixed some qdoc warnings. doc: Fixed some qdoc warnings. doc: Fixed some qdoc warnings.
| * | | doc: Fixed some qdoc warnings.Martin Smith2010-02-051-14/+16
| | | |
* | | | Add QMacCompatGLenum overrides for new QGLShaderProgram functionsRhys Weatherley2010-02-051-0/+28
|/ / / | | | | | | | | | | | | Task-number: QTBUG-7391 Reviewed-by: Sarah Smith
* | | Improvements to the QGLShaderProgram APIRhys Weatherley2010-02-041-0/+183
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | GLfloat[2][2] & GLfloat[3][3] uniform setters. Generic overrides to setAttributeArray() for setting the component type to something other than GL_FLOAT. setAttributeBuffer() for specifiying offsets within vertex buffers. Task-number: QTBUG-7391 Reviewed-By: Sarah Smith
* | | Remove obsolete OpenGL/ES CommonLite (fixed-point) supportRhys Weatherley2010-02-041-2/+2
| |/ |/| | | | | | | Task-number: QTBUG-7683 Reviewed-by: Tom Cooksey
* | Better support for user-generated binary shadersRhys Weatherley2010-01-271-3/+35
|/ | | | | | | | | | | | | | | | | | | | If the user provided their own shader with glShaderBinary(), QGLShaderProgram::addShader() would refuse to add it because it wasn't marked as "compiled". According to the OpenGL/ES 2.0 specification: "It is permissible to attach a shader object to a program object before source code has been loaded into the shader object or before the shader object has been compiled." Based on this, the compile check has been removed from addShader() which should make supporting binary shaders easier. Similarly, link() and programId() have been modified to support applications that use glProgramBinaryOES() to specify program binaries. Task-number: QTBUG-7490 Reviewed-by: Tom Cooksey
* Merge branch '4.6' of scm.dev.nokia.troll.no:qt/oslo-staging-1 into ↵Qt Continuous Integration System2010-01-071-1/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 4.6-integration * '4.6' of scm.dev.nokia.troll.no:qt/oslo-staging-1: QIODevice: Fix readAll() Temporary hackiesh solution to prevent BOM in the xml data. Fixed qxmlstream autotest when using shadow builds. Attempt at readding the capital P headers for Phonon Remove special Phonon processing from syncqt. Use the lowercase/shortname.h headers for Phonon includes Fixes a crash when setting focus on a widget with a focus proxy. Update copyright year to 2010 doc: Clarified activeSubControls and subControls. Remove warning "statement with no effect" doc: Clarified that .lnk files are System files on Windows.
| * Update copyright year to 2010Jason McDonald2010-01-061-1/+1
| | | | | | | | Reviewed-by: Trust Me
* | Revert "Add GLfloat[2][2] & GLfloat[3][3] uniform setters to QGLShaderProgram"Tom Cooksey2010-01-061-67/+0
|/ | | | | | | | | | | We don't add new public methods in patch releases. This reverts commit 2b4d3391fd922dfc5ac28815bbd5f36c4041b658. This patch also fixes the paint engine to use glUniformMatrix3fv directly now it has been removed from 4.6. It is a 3 line change. Reviewed-By: Samuel
* Add GLfloat[2][2] & GLfloat[3][3] uniform setters to QGLShaderProgramTom Cooksey2009-12-221-0/+67
| | | | Reviewed-By: Rhys Weatherley
* Modify QGLShader and QGLShaderProgram in response to API reviewRhys Weatherley2009-11-051-131/+167
| | | | Reviewed-by: Sarah Smith
* Add QMacGLCompatTypes to QGLShaderProgram APITom Cooksey2009-11-041-0/+50
|
* Remove partial shader support from QGLShader/QGLShaderProgramRhys Weatherley2009-11-011-177/+5
| | | | Reviewed-by: trustme
* Remove shader/program binary support for nowRhys Weatherley2009-10-281-213/+0
| | | | | | | | | | After API review discussions, it was decided to remove shader binary support until we have a better handle on what we need. Applications can directly load shader binaries on the shaderId() using glShaderBinary() directly so they aren't prevented from using the feature. Reviewed-by: trustme
* Suppress warnings under OpenGL/ES 2.0 in QGLShaderProgramRhys Weatherley2009-10-261-0/+55
|
* Fix OpenGL/ES 2.0 bug in previous QGLShaderProgram check-inRhys Weatherley2009-10-261-1/+1
|
* Use QObjectPrivate within QGLShaderPrivate and QGLShaderProgramPrivateRhys Weatherley2009-10-261-43/+132
| | | | Reviewed-by: Sarah Smith
* Optimize concatenation of partial shadersRhys Weatherley2009-10-261-30/+93
| | | | Reviewed-by: Sarah Smith
* Issue a warning if bindAttributeLocation() is used after shaders linkedRhys Weatherley2009-10-251-3/+8
| | | | | | | | | Attribute locations must be bound before a shader program is linked according to the GLSL specification. Issue a warning to the user if they do it in the wrong order, which should help to isolate hard to find bugs much quicker. Reviewed-by: trustme
* QGLContext::areSharing() to check for GL share relationshipsRhys Weatherley2009-10-011-4/+4
| | | | Reviewed-by: Samuel
* qdoc: Shift snippets in QGLShaderProgram out into doc/src/snippetsRhys Weatherley2009-09-151-49/+3
|
* Merge branch '4.6' of git@scm.dev.nokia.troll.no:qt/qt into 4.6Rhys Weatherley2009-09-091-4/+4
|\
| * Update license headers again.Jason McDonald2009-09-091-4/+4
| | | | | | | | Reviewed-by: Trust Me
* | Clean up shader programs properlyRhys Weatherley2009-09-091-190/+117
|/ | | | | | | | | | | | | | | QGLShader and QGLShaderProgram used to delete the GL object id in the wrong context. But fixing this means we must keep track of when contexts are destroyed so that we don't try to access a context from a shader if it goes away. We also need to transfer ownership from one context to another when they are shared. This change introduces QGLSharedResourceGuard, which keeps track of a context and a GL object identifier. When the context goes away, ownership is passed to a shared context. When there are no more shared contexts, the identifier automatically zeroes. Reviewed-by: trustme
* Modify QMatrix4x4 and QQuaternion to use qreal internallyRhys Weatherley2009-09-041-105/+92
| | | | | | | | | | | | | | | | | | | | | | | | Some concerns were expressed about the float precision of QMatrix4x4, which this change addresses by using qreal instead. The QVector2D/3D/4D classes still use float internally, so that they can be used directly in large arrays of vertex values to be uploaded to an OpenGL server. QQuaternion is a client-side class, and it should produce rotations that are consistent with QMatrix4x4. So its precision was changed too. A consequence of this change is that the following no longer works in a portable fashion: QMatrix4x4 mat; ... glLoadMatrixf(mat.constData()); The caller must now repack the argument to convert from qreal to GLfloat. Reviewed-by: Michael Goddard Reviewed-by: Andreas
* Add #define's for highp/mediump after #version/#extension headersRhys Weatherley2009-09-011-1/+20
| | | | | | | | GLSL shaders require that #version and #extension must appear before any other code. The #define's we insert for highp/mediump/etc must therefore be moved down to just after them. Reviewed-by: Gunnar Sletta
* OpenGL/ES 2.0 compilation problem since QGLContextGroup changesRhys Weatherley2009-08-311-0/+12
| | | | Reviewed-by: trustme
* Added context pointer to QGLContextGroupResources.Kim Motoyoshi Kalland2009-08-311-20/+20
| | | | | | | | | | | | I renamed QGLContextGroupResources to QGLContextGroup because we are using it to identify context groups. I also added a pointer to one of the contexts in the group. Together with qgl_share_reg(), the pointer can be used to find all contexts in a group. I renamed QGLContextPrivate::qt_get_extension_funcs() to QGLContextPrivate::extensionFuncs() to follow Qt's naming convention. Reviewed-by: Trond
* doc: Fixed several qdoc errors.Martin Smith2009-08-311-1/+1
|