--- a/uiacceltk/hitchcock/coretoolkit/rendervg10/src/HuiVg10RenderPlugin.cpp Thu Jul 15 19:40:07 2010 +0300
+++ b/uiacceltk/hitchcock/coretoolkit/rendervg10/src/HuiVg10RenderPlugin.cpp Thu Aug 19 10:48:02 2010 +0300
@@ -565,3 +565,23 @@
#endif
}
+
+EGLSurface CHuiVg10RenderPlugin::CreatePBufferSurface(EGLDisplay aDisplay,
+ EGLenum aBuffertype, EGLClientBuffer aBuffer, EGLConfig aConfig)
+ {
+ EGLSurface newSurface = EGL_NO_SURFACE;
+ newSurface = eglCreatePbufferFromClientBuffer(aDisplay, aBuffertype, aBuffer, aConfig, NULL);
+
+ // if oom condition, free all the cached memory and try again
+ if(newSurface == EGL_NO_SURFACE)
+ {
+ if(eglGetError() == EGL_BAD_ALLOC)
+ {
+ CHuiEnv* env = CHuiEnv::Static();
+ env->HandleOutOfTextureMemory();
+ newSurface = eglCreatePbufferFromClientBuffer(aDisplay, aBuffertype, aBuffer, aConfig, NULL);
+ }
+ }
+ return newSurface;
+ }
+