summaryrefslogtreecommitdiffstats
path: root/src/opengl/qglframebufferobject_p.h
Commit message (Collapse)AuthorAgeFilesLines
* Moved 'hasAlpha' property from GL2 engine to GL paint device.Kim Motoyoshi Kalland2010-02-121-1/+3
| | | | | | Got rid of an ugly switch statement. Reviewed-by: Tom
* Update copyright year to 2010Jason McDonald2010-01-061-1/+1
| | | | Reviewed-by: Trust Me
* Remove unnessisary QGLFBOGLPaintDevice re-implementationsTom Cooksey2009-11-051-3/+0
| | | | | | | Now QGLFBO doesn't do stacking, QGLPaintDevice's base implementation is ok to use. Reviewed-By: Trond
* Removed the FBO stacking behaviour and the test attached to it.Trond Kjernåsen2009-11-051-2/+2
| | | | | | | Having this behaviour in QGLFrameBufferObject complicates alot of things and isn't really necessary. Reviewed-by: Tom Cooksey
* Merge branch '4.6' of git@scm.dev.nokia.troll.no:qt/qt into 4.6Gunnar Sletta2009-10-191-1/+1
|\
| * Don't delete an fbo's texture if the fbo isn't using a textureRhys Weatherley2009-10-121-1/+1
| | | | | | | | | | | | Also, unbind the texture after it is initialized. Reviewed-by: Sarah Smith
* | Fixed bug when using QGLWidgets in -graphicssystem openglSamuel Rødal2009-10-121-1/+1
|/ | | | | | We need to make sure that the FBO is bound in a valid context. Reviewed-by: Tom
* Make QGLFramebufferObject crash-proof if QGLContext destroyed firstRhys Weatherley2009-10-011-3/+4
| | | | | | | | | | | | | | | | Sometimes it isn't possible to arrange for the QGLFramebufferObject to be destroyed before the QGLContext group in which it was created. Especially during application shutdown or in applications with multiple shared contexts. This change modifies QGLFramebufferObject to use QGLSharedResourceGuard, which ensures that when the last QGLContext in a sharing group is destroyed, any remaining FBO's will revert to !isValid(). It is now safe to destroy the context before the FBO, or the FBO before the context. Unit test included. Reviewed-by: Sarah Smith
* Return the correct QGLFormat to the OpenGL1 paint engine for FBO'sRhys Weatherley2009-09-101-1/+4
| | | | | | | | | | | | | QGLPaintDevice::format() was returning the context's format, not the format of the window surface's FBO. This caused the OpenGL1 paint engine to think that the window didn't have depth and stencil buffers, even though the FBO most certainly did. This change makes QGLPaintDevice::format() virtual and overrides it in QGLFBOGLPaintDevice to return an updated format that includes the context parameters plus the extra features that the FBO supports. Reviewed-by: Tom Cooksey
* Update license headers again.Jason McDonald2009-09-091-4/+4
| | | | Reviewed-by: Trust Me
* Make QGLPixmapData work with the new QGLPaintDevice APITom Cooksey2009-09-081-1/+2
| | | | | | | | | | This patch changes the ordering of QGL2PaintEngine::begin a bit because QGLPixmapData needs to use the paint engine's drawTexture method within beginPaint(). Also, this initialises needsSync to true and removes the setState call. So now all the state initialisation is done in ensureActive rather than begin.
* Make QGLFramebufferObject work again using new QGLPaintDevice APITom Cooksey2009-09-081-0/+151
This patch also refactors QGL2PaintEngineEx::ensureActive() and the logic which handles multiple paint engines rendering to the same QGLContext. In a nut-shell: * QGLPaintDevice::beginPaint() stores the currently bound FBO * QGLPaintDevice::ensureActiveTarget() makes sure that GL rendering will end up in the paint device (I.e. the right context is current and the right FBO is bound). If a different context or FBO was bound, it is _not_ remembered. * QGLPaintDevice::endPaint() restores whatever FBO was bound when beginPaint() was called. This logic allows interleaved painter rendering to multiple FBOs and contexts to work as expected. It also allows a stacked begin/end to work properly when it's mixed with native GL rendering (as far as current render target is concerened. GL state clobbering is obviously a different topic). QGLPaintDevice::context() also had to be made virtual as there's no good place to call setContext. This might be possible to change in the future though. Finally, to make this work, QGLFramebufferObjectPrivate had to be moved into it's own private header.