Lines Matching refs:context
183 #define VALIDATE_CONTEXT_RETURN(context,ret) \ argument
184 if (!(context) || !s_display.isContext((context))) { \
765 static void s_destroyPendingSurfacesInContext(EGLContext_t* context) { in s_destroyPendingSurfacesInContext() argument
766 if (context->read == context->draw) { in s_destroyPendingSurfacesInContext()
768 s_destroyPendingSurfaceAndSetNull(&context->draw); in s_destroyPendingSurfacesInContext()
769 if (context->draw == NULL) { in s_destroyPendingSurfacesInContext()
770 context->read = NULL; in s_destroyPendingSurfacesInContext()
773 s_destroyPendingSurfaceAndSetNull(&context->draw); in s_destroyPendingSurfacesInContext()
774 s_destroyPendingSurfaceAndSetNull(&context->read); in s_destroyPendingSurfacesInContext()
1428 EGLContext_t* context = tInfo->currentContext; in s_eglReleaseThreadImpl() local
1430 if (!context || !s_display.isContext(context)) { in s_eglReleaseThreadImpl()
1442 context->flags &= ~EGLContext_t::IS_CURRENT; in s_eglReleaseThreadImpl()
1444 s_destroyPendingSurfacesInContext(context); in s_eglReleaseThreadImpl()
1446 if (context->deletePending) { in s_eglReleaseThreadImpl()
1447 if (context->rcContext) { in s_eglReleaseThreadImpl()
1448 rcEnc->rcDestroyContext(rcEnc, context->rcContext); in s_eglReleaseThreadImpl()
1449 context->rcContext = 0; in s_eglReleaseThreadImpl()
1451 delete context; in s_eglReleaseThreadImpl()
1738 EGLContext_t * context = new EGLContext_t(dpy, config, shareCtx, majorVersion, minorVersion); in eglCreateContext() local
1739 …ALOGD("%s: %p: maj %d min %d rcv %d", __FUNCTION__, context, majorVersion, minorVersion, rcMajorVe… in eglCreateContext()
1740 if (!context) { in eglCreateContext()
1745 context->rcContext = rcContext; in eglCreateContext()
1746 return context; in eglCreateContext()
1754 EGLContext_t * context = static_cast<EGLContext_t*>(ctx); in eglDestroyContext() local
1756 if (context->flags & EGLContext_t::IS_CURRENT) { in eglDestroyContext()
1757 context->deletePending = 1; in eglDestroyContext()
1761 if (context->rcContext) { in eglDestroyContext()
1763 rcEnc->rcDestroyContext(rcEnc, context->rcContext); in eglDestroyContext()
1764 context->rcContext = 0; in eglDestroyContext()
1767 delete context; in eglDestroyContext()
1786 EGLContext_t * context = static_cast<EGLContext_t*>(ctx); in eglMakeCurrent() local
1787 uint32_t ctxHandle = (context) ? context->rcContext : 0; in eglMakeCurrent()
1798 if (tInfo->currentContext == context && in eglMakeCurrent()
1799 (context == NULL || in eglMakeCurrent()
1800 (context && (context->draw == draw) && (context->read == read)))) { in eglMakeCurrent()
1816 …if (context && (context->flags & EGLContext_t::IS_CURRENT) && (context != tInfo->currentContext)) { in eglMakeCurrent()
1818 …ALOGE("%s: error: EGL_BAD_ACCESS: context %p current to another thread!\n", __FUNCTION__, context); in eglMakeCurrent()
1829 if (context) { in eglMakeCurrent()
1834 context->draw = draw; in eglMakeCurrent()
1835 context->read = read; in eglMakeCurrent()
1842 context->flags |= EGLContext_t::IS_CURRENT; in eglMakeCurrent()
1844 context->getClientState(); in eglMakeCurrent()
1849 context, context->majorVersion, context->minorVersion, tInfo); in eglMakeCurrent()
1858 context->majorVersion, in eglMakeCurrent()
1859 context->minorVersion, in eglMakeCurrent()
1860 context->deviceMajorVersion, in eglMakeCurrent()
1861 context->deviceMinorVersion); in eglMakeCurrent()
1871 if (context->majorVersion > 2) { in eglMakeCurrent()
1876 if (context->minorVersion > 0) { in eglMakeCurrent()
1900 if (context->majorVersion > 1) { in eglMakeCurrent()
1903 context->majorVersion, in eglMakeCurrent()
1904 context->minorVersion, in eglMakeCurrent()
1905 context->deviceMajorVersion, in eglMakeCurrent()
1906 context->deviceMinorVersion); in eglMakeCurrent()
1907 hostCon->gl2Encoder()->setSharedGroup(context->getSharedGroup()); in eglMakeCurrent()
1910 hostCon->glEncoder()->setClientState(context->getClientState()); in eglMakeCurrent()
1911 hostCon->glEncoder()->setSharedGroup(context->getSharedGroup()); in eglMakeCurrent()
1928 if (tInfo->currentContext && (tInfo->currentContext != context)) { in eglMakeCurrent()
1930 if (tInfo->currentContext->deletePending && tInfo->currentContext != context) { in eglMakeCurrent()
1936 tInfo->currentContext = context; in eglMakeCurrent()
1955 context, context->majorVersion, context->minorVersion, tInfo); in eglMakeCurrent()
1973 EGLContext_t * context = getEGLThreadInfo()->currentContext; in eglGetCurrentSurface() local
1974 if (!context) in eglGetCurrentSurface()
1979 return context->read; in eglGetCurrentSurface()
1981 return context->draw; in eglGetCurrentSurface()
1990 EGLContext_t * context = getEGLThreadInfo()->currentContext; in eglGetCurrentDisplay() local
1991 if (!context) in eglGetCurrentDisplay()
1994 return context->dpy; in eglGetCurrentDisplay()
2002 EGLContext_t * context = static_cast<EGLContext_t*>(ctx); in eglQueryContext() local
2007 ret = s_display.getConfigAttrib(context->config, EGL_CONFIG_ID, value); in eglQueryContext()
2013 *value = context->majorVersion; in eglQueryContext()
2016 if (!context->draw) in eglQueryContext()
2154 EGLContext_t *context = static_cast<EGLContext_t*>(ctx); in eglCreateImageKHR() local
2157 uint32_t ctxHandle = (context) ? context->rcContext : 0; in eglCreateImageKHR()