summaryrefslogtreecommitdiffstats
path: root/src/gui/image
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch '4.6' of git@scm.dev.nokia.troll.no:qt/qt-s60-public into ↵axis2009-11-122-4/+10
|\ | | | | | | 4.6-staging2
| * Fix to symbian transparent window backing store format.Jani Hautakangas2009-11-112-4/+10
| | | | | | | | | | | | | | | | | | Symbian semi-transparent window surface needs backing store pixmap in argb32 format. Normally QPixmap contains only rgb32 or argb32_pre pixels. This fix locks semi-transparent window backing store pixmap to argb32 format. Reviewed-by: Shane Kearns
| * Revert "Using qreal more consistently in code (prevent misuse of double)"Aleksandar Sasha Babic2009-11-116-28/+27
| | | | | | | | | | | | | | | | This reverts commit 676780d515cedca85829ae962e4f501c5e5b6581. Conflicts: src/gui/painting/qblendfunctions.cpp
| * Merge branch '4.6' of git@scm.dev.nokia.troll.no:qt/qt into 4.6Shane Kearns2009-11-102-13/+13
| |\
| * \ Merge branch '4.6' of git@scm.dev.nokia.troll.no:qt/qt into 4.6Shane Kearns2009-11-1016-100/+155
| |\ \
| * \ \ Merge branch '4.6' of git@scm.dev.nokia.troll.no:qt/qt into 4.6-s60axis2009-11-091-2/+2
| |\ \ \ | | | | | | | | | | | | | | | | | | | | Conflicts: src/gui/painting/qblendfunctions.cpp
| * | | | Using qreal more consistently in code (prevent misuse of double)Aleksandar Sasha Babic2009-11-066-27/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We want to force use of qreal where possible. This can lead to better performance on platforms where qreal -> float (i.e. ARM). To achieve this we: 1. changed from 'double' to 'qreal', where justified 2. using qreal() to intialize constants, where justified 3. adding helper functions that are overloaded for qreal like qAtan2(), qAcos(), qFabs() ... 4. defining QT_USE_MATH_H_FLOATS for Symbian platform In addtion we used opportunity to improve code with some small things 5. converting divisions to multiplications (i.e. '/ 2.0' -> '* qreal(0.5)') 6. defining new constants (i.e. 'Q_PI / 180.0' -> 'Q_PI180') 7. declaring variables as 'const', where justified Reviewed-by: Andreas Aardal Hanssen Reviewed-by: Gunnar Sletta Reviewed-by: Jan-Arve Reviewed-by: Kim Motoyoshi Kalland Reviewed-by: Alessandro Portale Reviewed-by: Janne Koskinen
* | | | | doc: Fixed some qdoc errors, numXxx() to xxxCount(), etc.Martin Smith2009-11-111-1/+1
| |_|_|/ |/| | |
* | | | Improvements to graphics effects API after review round.Samuel Rødal2009-11-102-13/+13
| |_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Get rid of QGraphicsEffectSource from the public API, instead add convenience functions in QGraphicsEffect. This way we commit to less API, and are free to introduce a customizable QGraphicsEffectSource in a future release. * Move PixmapPadMode into QGraphicsEffect and tweak the names of the enum values. * Make QGraphicsBlurEffect::BlurHint into a bit flag, for extensibility. Reviewed-by: Bjørn Erik Nilsen
* | | API review: Rename numCols() -> colorCount()Marius Storm-Olsen2009-11-063-1/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | The name numCols is ambiguous, as sometimes it's refering to the number of columns, and sometimes the number of colors. It also does not match the typical Qt naming convention *Count(). Reviewed-by: Tom Cooksey Reviewed-by: Andreas Aardal Hanssen
* | | API review: Rename functions numColors(), setNumColors() and numBytes()Marius Storm-Olsen2009-11-0614-99/+141
| |/ |/| | | | | | | | | | | | | | | | | QPaintDevice and QImage used the functions numColors(), setNumColors(), and numBytes(). However, this is not consistent with the rest of the Qt API which uses *Count() and set*Count(). Removed all usage of these functions inside Qt and test-cases. Reviewed-by: Andreas Aardal Hanssen
* | Merge branch '4.6' of git@scm.dev.nokia.troll.no:qt/qt into 4.6Gunnar Sletta2009-11-063-1/+6
|\ \ | |/
| * Merge branch 'graphicseffect' into 4.6Jørgen Lind2009-11-052-0/+5
| |\
| | * Add QT_NO_GRAPHICSEFFECTJørgen Lind2009-11-042-0/+5
| | | | | | | | | | | | | | | | | | | | | It depends on QT_NO_GRAPHICSVIEW for now, but it is possible to remove this dependency. Reviewed-by: paul
| * | Merge branch '4.6' of git@scm.dev.nokia.troll.no:qt/qt into 4.6David Boddie2009-11-042-3/+4
| |\ \ | | |/
| * | Merge branch '4.6' of git@scm.dev.nokia.troll.no:qt/qt-doc-team into 4.6David Boddie2009-11-041-1/+1
| |\ \ | | | | | | | | | | | | | | | | | | | | Conflicts: src/gui/kernel/qevent.cpp src/gui/kernel/qgesture.cpp
| | * | Doc: fix broken link in QBitmapAndy Nichols2009-11-041-1/+1
| | | | | | | | | | | | | | | | Reviewed-by: Pierre
* | | | Fixed crash in QPixmap::resize_helper on mac and x11Gunnar Sletta2009-11-051-2/+2
| |_|/ |/| | | | | | | | Reviewed-by: Trond
* | | Merge branch '4.6' of scm.dev.nokia.troll.no:qt/qt into 4.6Eskil Abrahamsen Blomfeldt2009-11-041-12/+12
|\ \ \ | |/ /
| * | Fix compiler error.Aleksandar Sasha Babic2009-11-041-1/+1
| | | | | | | | | | | | Reviewed-by: Trust Me
| * | Merge branch '4.6-s60' into 4.6axis2009-11-041-11/+11
| |\ \
| | * | Fix crash in QApplication autotest introduced by native pixmaps (S60 3.1)Shane Kearns2009-11-031-11/+11
| | |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem was caused by S60 closing a handle under our feet when QApplication is destroyed. To avoid this, we open our own handle for the global lock instead of using the shared one inside CFbsBitmap. Also the global unlock/relock is not needed on S60 3.2 so this can be eliminated and save a few cycles (the function call was a no-op before) Reviewed-by: Jani Hautakangas
* | | Fixed crash with nullptr in QPixmapData::transformedGunnar Sletta2009-11-041-2/+2
| | | | | | | | | | | | Reviewed-By: Trond
* | | Fixed crash when QImage::createAlphaMask() runs out of memoryGunnar Sletta2009-11-041-1/+2
|/ / | | | | | | Reviewed-by: Trond
* | Merge branch '4.6' of git@scm.dev.nokia.troll.no:qt/qt into 4.6Gunnar Sletta2009-11-041-1/+0
|\ \
| * | QGtkStyle refactoringRobert Griebl2009-11-031-1/+0
| |/ | | | | | | | | | | | | | | | | | | | | | | The QGtk class has been refactored into a private d class for QGtkStyle. This allows us to re-use a lot of code for the Maemo5 style without changing a single line in QGtkStyle itself plus we can easily add virtual functions where the two styles need to behave different. There shouldn't be any new functionality added (or old functionality lost) by this commit. Reviewed-By: jbache Reviewed-By: Ralf Engels
* | Merge branch '4.6' of git@scm.dev.nokia.troll.no:qt/qt-graphics-team into 4.6Gunnar Sletta2009-11-031-4/+8
|\ \
| * \ Merge branch '4.6' of scm.dev.nokia.troll.no:qt/qt-graphics-team into 4.6Gunnar Sletta2009-11-032-8/+15
| |\ \
| * | | Fixed crash in QPixmap::fromImage with an Indexed8 without a colortable.Gunnar Sletta2009-11-031-4/+8
| | | | | | | | | | | | | | | | Reviewed-by: Trond
* | | | Merge branch '4.6' of git@scm.dev.nokia.troll.no:qt/qt into 4.6Gunnar Sletta2009-11-035-13/+26
|\ \ \ \ | |_|/ / |/| | / | | |/ | |/|
| * | Merge commit 'origin/4.6' into featureJørgen Lind2009-11-024-37/+36
| |\ \
| | * \ Merge branch '4.6-s60' into 4.6axis2009-10-301-10/+12
| | |\ \
| | | * | Fixed crash/drawing artifacts on rotation change on Symbian.axis2009-10-281-4/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On every beginDataAccess on the pixmap data, we checked the value of the pointer to the bits and only updated the image if the pointer had changed. However, we didn't take into account that the pointer could be the same, even though the dimensions were different, since malloc() could return the same memory area. This would lead to painting into an image that had the wrong dimensions, which again led to either crashes or image shearing. Fixed by checking the dimensions before deciding to update the image. Task: QTBUG-4815 RevBy: Jason Barron
| | | * | Fix EColor16M conversion in QPixmap::fromSymbianCFbsBitmap()Jani Hautakangas2009-10-281-6/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | EColor16M is in BGR format so after conversion to QImage RGB values needs to be swapped. Reviewed-by: jbarron
| * | | | Fix LIBRARY and ICONJørgen Lind2009-10-294-3/+14
| | |/ / | |/| | | | | | | | | | | | | | | | | | However, compiling with QT_NO_ICON will still not work :( Reviewed-by: tom
* | | | Moved Qt::RenderHint back into QGraphicsBlurEffect and added a hint.Samuel Rødal2009-11-022-8/+15
| |_|/ |/| | | | | | | | | | | | | | | | | | | | Added AnimationHint, which didn't make too much sense in a generic enum, so Qt::RenderHint was moved back into QGraphicsBlurEffect as QGraphicsBlurEffect::BlurHint. Reviewed-by: Gunnar Sletta
* | | Lazily construct QPixmapData's for null pixmapsGunnar Sletta2009-10-308-38/+75
| | | | | | | | | | | | Reviewed-by: Trond
* | | Added QImagePixmapCleanupHooks functions for enabling hooks.Samuel Rødal2009-10-293-3/+22
| |/ |/| | | | | | | | | | | Better than having to befriend QPixmapData and setting is_cached manually. Reviewed-by: Tom Cooksey
* | Added some optimizations to the blur and drop shadow GL filters.Samuel Rødal2009-10-291-9/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Use ExpandToTransparentBorderPadMode since we can use GL_CLAMP_TO_EDGE to clamp to the texture. * Shrink the bounding rects reported by the blur and drop shadow filters (expanding by 2 * radius isn't needed). * Use a single-pass blur for radii <= 3 to avoid the overhead of rendering to an FBO. * Made the fast blur setting generate filters for only a predefined set of radii, and then use the actual blur radius to spread the sample points outwards. * Optimized the generated program to rely less on temporary variables, as those seemed to not be handled very well by certain GLSL compilers. Reviewed-by: Gunnar Sletta
* | Use shared memory images when shared pixmaps are not available.Fredrik Höglund2009-10-271-4/+6
| | | | | | | | | | | | | | | | | | | | | | | | Modern graphics drivers tend to disable shared memory pixmaps, since rendering operations often can't be accelerated by the GPU when the pixmap data is pinned in system RAM. Use XShmPutImage() to flush the window surface when this is case, instead of falling back to the slower XPutImage() method. Merge-request: 1684 Reviewed-by: Samuel Rødal <sroedal@trolltech.com>
* | Merge branch '4.6' of git@scm.dev.nokia.troll.no:qt/qt into 4.6Gunnar Sletta2009-10-271-0/+3
|\ \ | |/
| * QPixmap::loadFromData: Do not crash on empty/invalid data/lengthMarkus Goetz2009-10-261-0/+3
| | | | | | | | | | Task-number: 262636 Reviewed-by: gunnar
* | Made blur and drop shadow APIs use qreal instead of int for blur radius.Samuel Rødal2009-10-272-14/+14
|/ | | | | | | There's no reason to lock ourselves to int in the API when some of the backend could handle floating point blur radii. Reviewed-by: Bjørn Erik Nilsen
* updated documentation for QPixmap::fromImage()Gunnar Sletta2009-10-221-5/+7
|
* Merge branch '4.6' of git@scm.dev.nokia.troll.no:qt/qt-graphics-team into 4.6Gunnar Sletta2009-10-221-7/+16
|\
| * Added doc warning about ARGB32 image drawing and fixed format docsGunnar Sletta2009-10-211-7/+16
| |
* | Merge branch '4.6' of git@scm.dev.nokia.troll.no:qt/qt into 4.6Gunnar Sletta2009-10-222-7/+13
|\ \ | |/ |/| | | | | Conflicts: src/gui/painting/qtextureglyphcache.cpp
| * Use premultiplied alpha pixel format in SymbianShane Kearns2009-10-201-7/+12
| | | | | | | | | | | | | | | | | | Gives better performance in the raster paint engine. For Symbian 9.3 onwards, this can also be used as the native pixmap format. For 9.2, conversion is required. Reviewed-by: Sami Merila Reviewed-by: Jani Hautakangas
| * Fix crash in QPixmapCache.David Faure2009-10-191-0/+1
| | | | | | | | | | | | | | QCache destruction accesses the key array that was freed in the QPixmapCache destruction, so better clear() before deleting that key. Merge-request: 1820 Reviewed-by: Alexis Menard <alexis.menard@nokia.com>
* | Add an assert testing the cleanup hooks exist before executing themTom Cooksey2009-10-191-0/+1
| | | | | | | | Reviewed-By: TrustMe