holdingarea/serialization/Graphics/KhronosAPIWrapper/src/KhronosAPIWrapper.cpp
branchbug235_bringup_0
changeset 30 f204b762818d
parent 24 a3f46bb01be2
equal deleted inserted replaced
29:2fcf0803a8bd 30:f204b762818d
   301     TRACE("KhronosAPIWrapper::InputBufferWriteCount %u\n", val );
   301     TRACE("KhronosAPIWrapper::InputBufferWriteCount %u\n", val );
   302     return val;
   302     return val;
   303 }
   303 }
   304 
   304 
   305 
   305 
   306 KhronosAPIWrapper::KhronosAPIWrapper( MGraphicsVHWCallback* aServiceIf, void* framebuffer, void* inputdata, void* outputdata )
   306 KhronosAPIWrapper::KhronosAPIWrapper( MGraphicsVHWCallback* aServiceIf, void* surfacebuffer, void* inputdata, void* outputdata )
   307 {
   307 {
   308     TRACE("KhronosAPIWrapper::KhronosAPIWrapper()\n");
   308     TRACE("KhronosAPIWrapper::KhronosAPIWrapper()\n");
   309 	m_lastVgError = VG_NO_ERROR;
   309 	m_lastVgError = VG_NO_ERROR;
   310 	m_lastEglError = EGL_SUCCESS;
   310 	m_lastEglError = EGL_SUCCESS;
   311 
   311 
   312 	m_lastProcessId = 0;
   312 	m_lastProcessId = 0;
   313 	m_lastThreadId = 0;
   313 	m_lastThreadId = 0;
   314     m_currentInput = inputdata;
   314     m_currentInput = inputdata;
   315     m_currentResult = outputdata;
   315     m_currentResult = outputdata;
   316     m_frameBuffer = framebuffer;
   316     m_surfaceBuffer = surfacebuffer;
   317     m_exit = false;
   317     m_exit = false;
   318     iServiceIf = aServiceIf;
   318     iServiceIf = aServiceIf;
   319     m_initDone = false;
   319     m_initDone = false;
   320 	iRFCData = new RemoteFunctionCallData;
   320 	iRFCData = new RemoteFunctionCallData;
   321     m_InputRequestBuffer = new RequestBufferReader( *this, VVI_PARAMETERS_INPUT_MEMORY_SIZE );
   321     m_InputRequestBuffer = new RequestBufferReader( *this, VVI_PARAMETERS_INPUT_MEMORY_SIZE );
   331     iStack = new APIWrapperStack();
   331     iStack = new APIWrapperStack();
   332     iStack->InitStack( KMaxStackSize );
   332     iStack->InitStack( KMaxStackSize );
   333 
   333 
   334 	m_OpenVGWrapper = new OpenVGAPIWrapper( *iRFCData, iStack, m_currentResult, iServiceIf, this );
   334 	m_OpenVGWrapper = new OpenVGAPIWrapper( *iRFCData, iStack, m_currentResult, iServiceIf, this );
   335 	m_OGLESWrapper = new OGLES11Wrapper(*iRFCData, iStack, m_currentResult, iServiceIf);
   335 	m_OGLESWrapper = new OGLES11Wrapper(*iRFCData, iStack, m_currentResult, iServiceIf);
   336 	m_EGLWrapper = new EGLAPIWrapper( *iRFCData, iStack, m_currentResult, iServiceIf, m_frameBuffer, this );
   336 	m_EGLWrapper = new EGLAPIWrapper( *iRFCData, iStack, m_currentResult, iServiceIf, m_surfaceBuffer, this );
   337 	m_DriverAPIWrapper = new DriverAPIWrapper( *iRFCData, iStack, m_currentResult, iServiceIf, this );
   337 	m_DriverAPIWrapper = new DriverAPIWrapper( *iRFCData, iStack, m_currentResult, iServiceIf, this );
   338 
   338 
   339 #ifdef KHRONOS_API_W_MULTITHREAD
   339 #ifdef KHRONOS_API_W_MULTITHREAD
   340     int result = Psu::platform_create_simple_thread(&m_threadHandle,
   340     int result = Psu::platform_create_simple_thread(&m_threadHandle,
   341         &WorkerThreadFunction, this);
   341         &WorkerThreadFunction, this);