summaryrefslogtreecommitdiffstats
path: root/src/opengl/qgl.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Fixed an on-exit crash for apps using GL.Trond Kjernåsen2010-06-111-0/+2
| | | | | | | | | | | | If a QGLWidget is left on the heap when the QApplication destructor is called, it will leave the QGLWidget in a broken state. The widget itself is released and set to a non-created state, which the associated QGLContext doesn't get notified about. With this patch the QGLWidget knows when QWidget::destroy() is called and can act acordingly. Task-number: QT-3498, QTBUG-10995 Reviewed-by: Paul
* Added OpenGL 3.3 and 4.0 recognition to QGLFormatSebastian Hartte2010-06-031-2/+20
| | | | | Merge-request: 2404 Reviewed-by: Trond
* Fixed a problem where QPixmaps where re-bound in non-sharing contexts.Trond Kjernåsen2010-06-011-7/+44
| | | | | | | | | | If you have two non-sharing GL contexts and try to draw the same QPixmap in both of them, they will wind up competing for a spot in the texture cache. Make the context group a part of the cache key to avoid that. Task-number: QT-3462 Reviewed-by: Kim
* Added workarounds for two MBX/SGX specific GL ES bugs/problems.Trond Kjernåsen2010-05-141-0/+3
| | | | | | | | | | | | | | The workaround flags are put into the platform independent section for now, since there might be a general need for these as we expand our GL and GL ES usage. The workaround_needsFullClearOnEveryFrame flag covers the case where you get a performance penalty on PowerVR hw if all rendering buffers are not cleared. The workaround_brokenFBOReadBack flag covers the case where copying pixels from a texture (e.g. via glCopyTexSubImage2d()) bound in an FBO doesn't work. Task-number: QTBUG-10670 Reviewed-by: Gunnar
* Remove an unnecessary assert.Trond Kjernåsen2010-05-121-2/+1
| | | | Reviewed-by: Kim
* Made paint engine texture drawing work in GL ES 2 and updated docs.Samuel Rødal2010-05-101-27/+46
| | | | | | | | Now QGLWidget::drawTexture() can be used on OpenGL ES 2.0 when there's an active painter. Task-number: QTBUG-10420 Reviewed-by: Trond
* Fixed OpenGL version flags for versions > 3.2.Kim Motoyoshi Kalland2010-05-031-1/+14
| | | | | | | If the system supports an OpenGL version higher than what is recognized by Qt, all the version flags up to 3.2 should be set. Reviewed-by: Trond
* Merge branch '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2 into ↵Qt Continuous Integration System2010-05-021-8/+14
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 4.7-integration * '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2: Fix project file generation for MSVC 2010 Fix wrong translation and clip for the raster paint-engine on Mac Return the correct library name in qt_gl_library_name for GLES* qmake: remove useless evaluation of variables from VS project generators Fix QT_NO_LIBRARY Documentation for the Elastic Nodes example. qmake: fix duplicate linker options in VS project files Ensured that WA_InputMethodEnabled was set before FocusInEvent was sent. qmake: fix duplicate compiler options in VS project files Documentation for the Drag and Drop Robot example. Fix crash in styles example when running with opengl graphicssystem Fixed the sizehint for cols/rows in qtableview QUrl: parsing of host name with an undercore. Null pointer check Revert "Try to use multisampled opengl graphicssystem on all platforms" A small mistake when comparing the flag. Add unit tests covering most of QVector's API. Fix crash when CoreText fails to shape text for us Fix crash when using opengl graphicssystem on desktop Revert "Revert "Implement heightForWidth support for QTabWidget and QStackedLayout.""
| * Return the correct library name in qt_gl_library_name for GLES*Tom Cooksey2010-04-301-4/+10
| | | | | | | | Reviewed-By: Gunnar
| * Fix crash when using opengl graphicssystem on desktopTom Cooksey2010-04-271-4/+4
| | | | | | | | | | Reviewed-By: Eskil Task-number: QTBUG-10225
* | Merge remote branch 'origin/4.6' into qt-4.7-from-4.6Thiago Macieira2010-04-291-2/+10
|\ \ | |/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | All EGL-related changes from 4.6 were discarded. Conflicts: src/gui/egl/egl.pri src/gui/egl/qegl.cpp src/gui/egl/qegl_p.h src/gui/egl/qegl_stub.cpp src/gui/egl/qeglproperties_p.h src/gui/egl/qeglproperties_stub.cpp src/gui/gui.pro src/multimedia/multimedia/audio/qaudioinput_win32_p.h src/s60installs/bwins/QtGuiu.def src/s60installs/eabi/QtGuiu.def
| * Fixed QGLWidget::grabFrameBuffer() to honor the 'withAlpha' value.Trond Kjernåsen2010-04-271-2/+10
| | | | | | | | | | Task-number: QTBUG-7545 Reviewed-by: Kim
* | Make sure recreateEglSurface creates a surface if there isn't oneTom Cooksey2010-04-221-1/+1
| | | | | | | | | | | | | | | | If QGLWidgetPrivate::recreateEglSurface is called after a surface has been deleted, it should always create a new surface and ignore the fact that the window ID may not have changed. Reviewed-By: Trond
* | More adjustments to QTBUG-6800Carolina Gomes2010-04-141-7/+7
| | | | | | | | | | Merge-request: 2344 Reviewed-by: Tom Cooksey
* | Adjustments to QTBUG-6800 patch.Carolina Gomes2010-04-141-8/+6
| | | | | | | | | | Merge-request: 2344 Reviewed-by: Tom Cooksey
* | QTBUG-6800 patch included, but only for OpenGL 2.0Carolina Gomes2010-04-141-0/+27
| | | | | | | | | | Merge-request: 2344 Reviewed-by: Tom Cooksey
* | Support building with desktop OpenGL managed via EGLTom Cooksey2010-04-141-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This mostly replaces lots of QT_OPENGL_ES defines with QT_NO_EGL instead. It also switches off EGL auto-detection by default. This is to make sure we default to using GLX on systems with both EGL and desktop OpenGL. If -opengl es1|es2 or -openvg is specified, then EGL auto-detection is switched back on (as a requirement. If configure auto-detects OpenGL ES it also switches on EGL auto-detection, but failue then just disables both EGL & OpenGL. As a side effect, this patch also fixes building Qt when both EGL and glx are avaliable, as they are in Mesa >= 7.8.0. Reviewed-by: Trond Task-number: QTBUG-9691
* | Don't use texture-from-pixmap if the target isn't GL_TEXTURE_2DTom Cooksey2010-04-091-1/+2
| | | | | | | | | | Task-number: QTBUG-8546 Reviewed-By: TrustMe
* | Avoid having to create temporary QPixmaps when binding to textureTom Cooksey2010-03-261-1/+1
| | | | | | | | Reviewed-By: TrustMe
* | Make an attemt to upload QPixmap in the most optimal format on 16-bitGunnar Sletta2010-03-191-2/+9
| | | | | | | | | | | | | | | | On 16-bit configs, using 16-bit textures gives us quite a bit of performance extra, so making this extra effort prior to uploading it seems worth it. Reviewed-by: Samuel
* | Actually use GL texture cache when bindoptions are providedGunnar Sletta2010-03-191-5/+5
| | | | | | | | Reviewed-by: Trond
* | Made QGLExtensions::glExtensions() thread-safe.Trond Kjernåsen2010-03-121-19/+18
| | | | | | | | Reviewed-by: Gunnar
* | Delete the QGLContext in ~QX11GLPixmapDataTom Cooksey2010-03-111-0/+1
| | | | | | | | | | | | | | | | This also includes changes which allow QGLContext to not own it's own QEglContext. With X11GL, the QEglContext gets reused by multiple QGLContexts so it is important QGLContext doesn't delete it. Reviewed-By: TrustMe
* | Made QGLTextureCache::instance() threadsafe.Trond Kjernåsen2010-03-111-20/+7
| | | | | | | | Reviewed-by: Tom Cooksey
* | Make calls to QGLFormat::set*BufferSize also update flagsTom Cooksey2010-03-101-1/+5
| | | | | | | | Reviewed-By: Trond
* | Merge branch '4.6' of scm.dev.nokia.troll.no:qt/qt-s60-public into master-s60axis2010-02-261-1/+1
|\ \ | |/ | | | | | | | | Conflicts: qmake/generators/symbian/initprojectdeploy_symbian.cpp qmake/generators/symbian/symmake_abld.h
| * Fix off-by-one error in mipmap count when loading PVRTC filesRhys Weatherley2010-02-241-1/+1
| | | | | | | | | | Task-number: QT-2988 Reviewed-by: Julian de Bhal
* | Merge remote branch 'origin/master' into qt-master-from-4.6Thiago Macieira2010-02-201-6/+16
|\ \ | | | | | | | | | | | | | | | | | | Conflicts: configure.exe src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp src/opengl/qgl.cpp
| * | Some threading improvements to the GL moduleGunnar Sletta2010-02-171-11/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | - Make bindTexture threadsafe - Document which areas of QGLWidget needs locking in order to do out-of-gui thread rendering - Testcases to prove that these cases work Reviewed-by: Trond
* | | Merge branch '4.6' into qt-master-from-4.6Thiago Macieira2010-02-171-23/+21
|\ \ \ | |/ / |/| / | |/ | | | | | | Conflicts: mkspecs/common/symbian/symbian.conf src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp tools/assistant/tools/assistant/helpviewer.cpp
| * Fix several bugs with GL texture cacheTom Cooksey2010-02-121-23/+21
| | | | | | | | | | Reviewed-By: Trond Autotest: tst_QGL::qglContextDefaultBindTexture
* | Merge remote branch 'origin/4.6' into qt-master-from-4.6Thiago Macieira2010-02-121-1/+8
|\ \ | |/
| * Fixed drawing QPixmaps on QGLWidgets on different X11 screens.Trond Kjernåsen2010-02-101-1/+8
| | | | | | | | | | | | | | | | | | | | | | Don't try to use the texture_from_pixmap extension when drawing a pixmap from one X11 screen onto a different X11 screen in the GL 2 engine. For that to work, the pixmap will have to be re-created on the new screen, which is exactly what the default bind method does (via QImage conversion). Task-number: QTBUG-8054 Reviewed-by: Kim
* | Merge remote branch 'qt/4.6' into qt-master-from-4.6Qt Continuous Integration System2010-02-091-18/+13
|\ \ | |/ | | | | | | | | Conflicts: src/gui/kernel/qcocoapanel_mac.mm src/gui/kernel/qcocoasharedwindowmethods_mac_p.h
| * Fixed a failure in tst_qgl.Trond Kjernåsen2010-02-021-1/+0
| | | | | | | | | | | | | | The assert wrong, it may be that the texture isn't removed from the cache if it doesn't have the MemoryManaged bind option set. Reviewed-by: Samuel
| * Fix GL texture leaks when pixmaps are deletedTom Cooksey2010-01-291-18/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This fixes quite a lot of issues: * QtOpenGL only registered qpixmap destruction hooks on X11 and those only cleanup the EGL/GLX surface, not the texture object. * The QPixmap destruction hooks were only being called from the QPixmap destructor. However, this means when a QPixmap is assigned to another QPixmap, the hooks don't get called. Task-number: QTBUG-7647 Reviewed-By: Samuel Reviewed-By: Trond
* | Merge branch 'master' of scm.dev.nokia.troll.no:qt/oslo-staging-1 into ↵Qt Continuous Integration System2010-02-041-6/+8
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | master-integration * 'master' of scm.dev.nokia.troll.no:qt/oslo-staging-1: Use a shared QScriptEngine for debugger console command scripts Fix QtScript debugger hang/crash issue with updating locals model doc: Fixed some qdoc warnings. Always activate popup windows on show doc: Fixed some qdoc warnings. Add the QMAKE_FILE_EXT variable to extra compilers generation. Cocoa: Tool Windows steal focus from the main window qdoc3: Removed a debug output. Update QTestLib documentation with chart use case.
| * | doc: Fixed some qdoc warnings.Martin Smith2010-02-041-6/+8
| | |
* | | Remove obsolete OpenGL/ES CommonLite (fixed-point) supportRhys Weatherley2010-02-041-37/+32
|/ / | | | | | | | | Task-number: QTBUG-7683 Reviewed-by: Tom Cooksey
* | Merge remote branch 'qt/4.6' into qt-master-from-4.6Qt Continuous Integration System2010-02-011-2/+27
|\ \ | |/ | | | | | | | | | | | | | | | | Conflicts: src/gui/kernel/qeventdispatcher_mac.mm src/gui/kernel/qt_cocoa_helpers_mac.mm src/gui/widgets/qmenu_mac.mm tests/auto/qgraphicswidget/tst_qgraphicswidget.cpp tools/assistant/tools/assistant/centralwidget.cpp tools/linguist/lupdate/main.cpp
| * Added a warning to QGLWidget::renderText().Trond Kjernåsen2010-01-271-2/+20
| | | | | | | | | | | | | | | | | | renderText() can't be used while a GL 2 paint engine is active on the same device, because it will clash with the GL 1 engine and wreck havoc. We simply don't support that scenario. Task-number: QTBUG-7592 Reviewed-by: Samuel
| * Updated docs regarding QGLWidget::renderText() limitations.Trond Kjernåsen2010-01-251-0/+7
| | | | | | | | Reviewed-by: Trust Me
* | Merge branch '4.6'Thiago Macieira2010-01-181-29/+68
|\ \ | |/
| * Fix QGLWidget::renderPixmap() on Windows.Trond Kjernaasen2010-01-141-6/+6
| | | | | | | | | | | | | | | | Using renderPixmap() with scenes that contained textures might not work due to the wrong texture format being used under certain circumstances. Task-number: QTBUG-7213 Reviewed-by: Gunnar
| * Rework how Qt handles GL extensions.Trond Kjernåsen2010-01-131-23/+62
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Qt used to store the GL extensions a particular implementation supported in a global cache, which was initialized once and never updated. This could cause problems because different types of context might support different kinds of extensions (e.g. the difference between sw and hw contexts). With this patch, the GL extensions are cached and updated within each QGLContext. It also makes the extension initialization lazy, which saves application initialization costs for embedded platforms. The patch introduces a internal cross platform QGLTemporaryContext class that is used to create a light-weight GL context without going via QGLWidget and friends (QWS and WinCE still have QGLWidget fallbacks for now). Reviewed-by: Kim Reviewed-by: Samuel
* | Merge branch '4.6'Thiago Macieira2010-01-131-2/+2
|\ \ | |/ | | | | | | | | | | | | | | | | | | Conflicts: bin/syncqt doc/src/deployment/deployment.qdoc src/corelib/io/qfsfileengine_win.cpp src/corelib/xml/qxmlstream.cpp src/opengl/gl2paintengineex/qpaintengineex_opengl2_p.h tools/assistant/tools/assistant/centralwidget.cpp tools/linguist/lupdate/main.cpp
| * Merge remote branch 'qt/4.6' into oslo-staging-2/4.6Paul Olav Tvete2010-01-121-1/+1
| |\ | | | | | | | | | | | | Conflicts: dist/changes-4.6.1
| | * Merge branch '4.6' of scm.dev.nokia.troll.no:qt/qt into 4.6Simon Hausmann2010-01-081-2/+0
| | |\ | | | | | | | | | | | | | | | | Conflicts: src/multimedia/audio/qaudioformat.cpp
| | * \ 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