summaryrefslogtreecommitdiffstats
path: root/src/openvg
diff options
context:
space:
mode:
authorJason Barron <jbarron@trolltech.com>2010-03-18 11:58:04 (GMT)
committerJason Barron <jbarron@trolltech.com>2010-03-18 11:58:04 (GMT)
commitbfb976c4ca539c7207083aa57e3d707dcad88bd5 (patch)
tree9a1ea9a5bbe5221fcf9f2354a560724102bf1966 /src/openvg
parentd7aa84d9f4ea9f34dfcdf4409508475a11015e9f (diff)
downloadQt-bfb976c4ca539c7207083aa57e3d707dcad88bd5.zip
Qt-bfb976c4ca539c7207083aa57e3d707dcad88bd5.tar.gz
Qt-bfb976c4ca539c7207083aa57e3d707dcad88bd5.tar.bz2
Fix compilation of OpenVG.
As simple as QEglContext::display -> QEgl::display. Reviewed-by: Tom Cooksey
Diffstat (limited to 'src/openvg')
-rw-r--r--src/openvg/qpixmapdata_vg.cpp12
-rw-r--r--src/openvg/qwindowsurface_vgegl.cpp22
2 files changed, 17 insertions, 17 deletions
diff --git a/src/openvg/qpixmapdata_vg.cpp b/src/openvg/qpixmapdata_vg.cpp
index 8adf5af..53f6b4c 100644
--- a/src/openvg/qpixmapdata_vg.cpp
+++ b/src/openvg/qpixmapdata_vg.cpp
@@ -496,7 +496,7 @@ void QVGPixmapData::fromNativeType(void* pixmap, NativeType type)
}
const EGLint KEglImageAttribs[] = {EGL_IMAGE_PRESERVED_SYMBIAN, EGL_TRUE, EGL_NONE};
- EGLImageKHR eglImage = eglCreateImageKHR(QEglContext::display(),
+ EGLImageKHR eglImage = eglCreateImageKHR(QEgl::display(),
EGL_NO_CONTEXT,
EGL_NATIVE_PIXMAP_KHR,
(EGLClientBuffer)sgImage,
@@ -511,7 +511,7 @@ void QVGPixmapData::fromNativeType(void* pixmap, NativeType type)
vgImage = vgCreateEGLImageTargetKHR(eglImage);
if(vgGetError() != VG_NO_ERROR) {
cleanup();
- eglDestroyImageKHR(QEglContext::display(), eglImage);
+ eglDestroyImageKHR(QEgl::display(), eglImage);
SgDriver::Close();
return;
}
@@ -525,7 +525,7 @@ void QVGPixmapData::fromNativeType(void* pixmap, NativeType type)
prevSize = QSize(w, h);
setSerialNumber(++qt_vg_pixmap_serial);
// release stuff
- eglDestroyImageKHR(QEglContext::display(), eglImage);
+ eglDestroyImageKHR(QEgl::display(), eglImage);
SgDriver::Close();
} else if (type == QPixmapData::FbsBitmap) {
CFbsBitmap *bitmap = reinterpret_cast<CFbsBitmap*>(pixmap);
@@ -620,7 +620,7 @@ void* QVGPixmapData::toNativeType(NativeType type)
}
const EGLint KEglImageAttribs[] = {EGL_IMAGE_PRESERVED_SYMBIAN, EGL_TRUE, EGL_NONE};
- EGLImageKHR eglImage = eglCreateImageKHR(QEglContext::display(),
+ EGLImageKHR eglImage = eglCreateImageKHR(QEgl::display(),
EGL_NO_CONTEXT,
EGL_NATIVE_PIXMAP_KHR,
(EGLClientBuffer)sgImage,
@@ -633,7 +633,7 @@ void* QVGPixmapData::toNativeType(NativeType type)
VGImage dstVgImage = vgCreateEGLImageTargetKHR(eglImage);
if(vgGetError() != VG_NO_ERROR) {
- eglDestroyImageKHR(QEglContext::display(), eglImage);
+ eglDestroyImageKHR(QEgl::display(), eglImage);
sgImage->Close();
SgDriver::Close();
return 0;
@@ -649,7 +649,7 @@ void* QVGPixmapData::toNativeType(NativeType type)
}
// release stuff
vgDestroyImage(dstVgImage);
- eglDestroyImageKHR(QEglContext::display(), eglImage);
+ eglDestroyImageKHR(QEgl::display(), eglImage);
SgDriver::Close();
return reinterpret_cast<void*>(sgImage);
} else if (type == QPixmapData::FbsBitmap) {
diff --git a/src/openvg/qwindowsurface_vgegl.cpp b/src/openvg/qwindowsurface_vgegl.cpp
index f46d6c2..9b55fd2 100644
--- a/src/openvg/qwindowsurface_vgegl.cpp
+++ b/src/openvg/qwindowsurface_vgegl.cpp
@@ -230,9 +230,9 @@ static QEglContext *createContext(QPaintDevice *device)
// Set the swap interval for the display.
QByteArray interval = qgetenv("QT_VG_SWAP_INTERVAL");
if (!interval.isEmpty())
- eglSwapInterval(QEglContext::display(), interval.toInt());
+ eglSwapInterval(QEgl::display(), interval.toInt());
else
- eglSwapInterval(QEglContext::display(), 1);
+ eglSwapInterval(QEgl::display(), 1);
#ifdef EGL_RENDERABLE_TYPE
// Has the user specified an explicit EGL configuration to use?
@@ -246,16 +246,16 @@ static QEglContext *createContext(QPaintDevice *device)
EGLint matching = 0;
EGLConfig cfg;
if (eglChooseConfig
- (QEglContext::display(), properties, &cfg, 1, &matching) &&
+ (QEgl::display(), properties, &cfg, 1, &matching) &&
matching > 0) {
// Check that the selected configuration actually supports OpenVG
// and then create the context with it.
EGLint id = 0;
EGLint type = 0;
eglGetConfigAttrib
- (QEglContext::display(), cfg, EGL_CONFIG_ID, &id);
+ (QEgl::display(), cfg, EGL_CONFIG_ID, &id);
eglGetConfigAttrib
- (QEglContext::display(), cfg, EGL_RENDERABLE_TYPE, &type);
+ (QEgl::display(), cfg, EGL_RENDERABLE_TYPE, &type);
if (cfgId == id && (type & EGL_OPENVG_BIT) != 0) {
context->setConfig(cfg);
if (!context->createContext()) {
@@ -334,7 +334,7 @@ static void qt_vg_destroy_shared_context(QVGSharedContext *shared)
shared->engine = 0;
shared->context->doneCurrent();
if (shared->surface != EGL_NO_SURFACE) {
- eglDestroySurface(QEglContext::display(), shared->surface);
+ eglDestroySurface(QEgl::display(), shared->surface);
shared->surface = EGL_NO_SURFACE;
}
delete shared->context;
@@ -412,7 +412,7 @@ EGLSurface qt_vg_shared_surface(void)
attribs[4] = EGL_NONE;
}
shared->surface = eglCreatePbufferSurface
- (QEglContext::display(), shared->context->config(), attribs);
+ (QEgl::display(), shared->context->config(), attribs);
}
return shared->surface;
}
@@ -555,7 +555,7 @@ void QVGEGLWindowSurfaceVGImage::beginPaint(QWidget *widget)
context->makeCurrent(mainSurface());
recreateBackBuffer = false;
if (backBufferSurface != EGL_NO_SURFACE) {
- eglDestroySurface(QEglContext::display(), backBufferSurface);
+ eglDestroySurface(QEgl::display(), backBufferSurface);
backBufferSurface = EGL_NO_SURFACE;
}
if (backBuffer != VG_INVALID_HANDLE) {
@@ -568,7 +568,7 @@ void QVGEGLWindowSurfaceVGImage::beginPaint(QWidget *widget)
if (backBuffer != VG_INVALID_HANDLE) {
// Create an EGL surface for rendering into the VGImage.
backBufferSurface = eglCreatePbufferFromClientBuffer
- (QEglContext::display(), EGL_OPENVG_IMAGE,
+ (QEgl::display(), EGL_OPENVG_IMAGE,
(EGLClientBuffer)(backBuffer),
context->config(), NULL);
if (backBufferSurface == EGL_NO_SURFACE) {
@@ -704,7 +704,7 @@ QEglContext *QVGEGLWindowSurfaceDirect::ensureContext(QWidget *widget)
#if defined(QVG_DIRECT_TO_WINDOW)
// Did we get a direct to window rendering surface?
EGLint buffer = 0;
- if (eglQueryContext(QEglContext::display(), context->context(),
+ if (eglQueryContext(QEgl::display(), context->context(),
EGL_RENDER_BUFFER, &buffer) &&
buffer == EGL_SINGLE_BUFFER) {
needToSwap = false;
@@ -714,7 +714,7 @@ QEglContext *QVGEGLWindowSurfaceDirect::ensureContext(QWidget *widget)
// Try to force the surface back buffer to preserve its contents.
if (needToSwap) {
eglGetError(); // Clear error state first.
- eglSurfaceAttrib(QEglContext::display(), surface,
+ eglSurfaceAttrib(QEgl::display(), surface,
EGL_SWAP_BEHAVIOR, EGL_BUFFER_PRESERVED);
if (eglGetError() != EGL_SUCCESS) {
qWarning("QVG: could not enable preserved swap");