summaryrefslogtreecommitdiffstats
path: root/src/openvg/qvg_symbian.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/openvg/qvg_symbian.cpp')
-rw-r--r--src/openvg/qvg_symbian.cpp31
1 files changed, 2 insertions, 29 deletions
diff --git a/src/openvg/qvg_symbian.cpp b/src/openvg/qvg_symbian.cpp
index 0d2425f..e97ade8 100644
--- a/src/openvg/qvg_symbian.cpp
+++ b/src/openvg/qvg_symbian.cpp
@@ -113,25 +113,8 @@ static VGImage sgImageToVGImage(QEglContext *context, const RSgImage &sgImage)
VGImage vgImage = VG_INVALID_HANDLE;
- TInt err = 0;
-
- RSgDriver driver;
- err = driver.Open();
- if (err != KErrNone) {
- return vgImage;
- }
-
- if (sgImage.IsNull()) {
- driver.Close();
- return vgImage;
- }
-
- TSgImageInfo sgImageInfo;
- err = sgImage.GetInfo(sgImageInfo);
- if (err != KErrNone) {
- driver.Close();
+ if (sgImage.IsNull())
return vgImage;
- }
const EGLint KEglImageAttribs[] = {EGL_IMAGE_PRESERVED_SYMBIAN, EGL_TRUE, EGL_NONE};
EGLImageKHR eglImage = QEgl::eglCreateImageKHR(QEgl::display(),
@@ -140,22 +123,12 @@ static VGImage sgImageToVGImage(QEglContext *context, const RSgImage &sgImage)
(EGLClientBuffer)&sgImage,
(EGLint*)KEglImageAttribs);
- if (!eglImage || eglGetError() != EGL_SUCCESS) {
- driver.Close();
+ if (!eglImage)
return vgImage;
- }
vgImage = QVG::vgCreateEGLImageTargetKHR(eglImage);
- if (!vgImage || vgGetError() != VG_NO_ERROR) {
- QEgl::eglDestroyImageKHR(QEgl::display(), eglImage);
- driver.Close();
- return vgImage;
- }
- //setSerialNumber(++qt_vg_pixmap_serial);
- // release stuff
QEgl::eglDestroyImageKHR(QEgl::display(), eglImage);
- driver.Close();
return vgImage;
}
#endif