summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms/cocoa/qcocoahelpers.h
diff options
context:
space:
mode:
authorMorten Johan Sørvig <morten.sorvig@digia.com>2013-01-07 22:38:10 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-02-12 07:50:03 +0100
commit784b9655597d2c23a00d57181b1853e6df07fdf3 (patch)
tree5b0faeeae6c12abeb0a83ec1910bef26172da88b /src/plugins/platforms/cocoa/qcocoahelpers.h
parent00d8de8589fc799015af1aa9a84e268fba4d6a74 (diff)
Cocoa: Export QImage <-> CGImage conversion funcs.
For implementing to/fromMacCGImageRef in QtMacExtras. These do not depend on internal Qt state. The main reason for exporting them is to keep the implementation in one place to ease maintenance. Refactor qt_mac_cg_context to support QImage. Add qt_mac_toQImage. Change-Id: Ia9c226ed52d087b2c6b47aa8210ed8f2645b9cf2 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
Diffstat (limited to 'src/plugins/platforms/cocoa/qcocoahelpers.h')
-rw-r--r--src/plugins/platforms/cocoa/qcocoahelpers.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/plugins/platforms/cocoa/qcocoahelpers.h b/src/plugins/platforms/cocoa/qcocoahelpers.h
index b065c72e68..831ab579f5 100644
--- a/src/plugins/platforms/cocoa/qcocoahelpers.h
+++ b/src/plugins/platforms/cocoa/qcocoahelpers.h
@@ -158,8 +158,9 @@ public:
}
};
-CGContextRef qt_mac_cg_context(const QPaintDevice *pdev);
+CGContextRef qt_mac_cg_context(QPaintDevice *pdev);
CGImageRef qt_mac_toCGImage(const QImage &qImage, bool isMask, uchar **dataCopy);
+QImage qt_mac_toQImage(CGImageRef image);
QT_END_NAMESPACE