Lines Matching full:thread
16 #include "libANGLE/Thread.h"
50 EGLBoolean BindAPI(Thread *thread, EGLenum api) in BindAPI() argument
52 thread->setAPI(api); in BindAPI()
54 thread->setSuccess(); in BindAPI()
58 EGLBoolean BindTexImage(Thread *thread, Display *display, egl::SurfaceID surfaceID, EGLint buffer) in BindTexImage() argument
62 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglBindTexImage", in BindTexImage()
65 gl::Context *context = thread->getContext(); in BindTexImage()
71 ANGLE_EGL_TRY_RETURN(thread, eglSurface->bindTexImage(context, textureObject, buffer), in BindTexImage()
75 thread->setSuccess(); in BindTexImage()
79 EGLBoolean ChooseConfig(Thread *thread, in ChooseConfig() argument
88 thread->setSuccess(); in ChooseConfig()
92 EGLint ClientWaitSync(Thread *thread, in ClientWaitSync() argument
98 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglClientWaitSync", in ClientWaitSync()
100 gl::Context *currentContext = thread->getContext(); in ClientWaitSync()
104 thread, syncObject->clientWait(display, currentContext, flags, timeout, &syncStatus), in ClientWaitSync()
107 thread->setSuccess(); in ClientWaitSync()
111 EGLBoolean CopyBuffers(Thread *thread, in CopyBuffers() argument
116 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglCopyBuffers", in CopyBuffers()
120 thread->setSuccess(); in CopyBuffers()
124 EGLContext CreateContext(Thread *thread, in CreateContext() argument
131 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglCreateContext", in CreateContext()
134 ANGLE_EGL_TRY_RETURN(thread, in CreateContext()
135 display->createContext(configuration, sharedGLContext, thread->getAPI(), in CreateContext()
139 thread->setSuccess(); in CreateContext()
143 EGLImage CreateImage(Thread *thread, in CreateImage() argument
152 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglCreateImage", in CreateImage()
159 thread->setError(error, "eglCreateImage", GetDisplayIfValid(display)); in CreateImage()
163 thread->setSuccess(); in CreateImage()
167 EGLSurface CreatePbufferFromClientBuffer(Thread *thread, in CreatePbufferFromClientBuffer() argument
174 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglCreatePbufferFromClientBuffer", in CreatePbufferFromClientBuffer()
177 ANGLE_EGL_TRY_RETURN(thread, in CreatePbufferFromClientBuffer()
186 EGLSurface CreatePbufferSurface(Thread *thread, in CreatePbufferSurface() argument
191 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglCreatePbufferSurface", in CreatePbufferSurface()
194 ANGLE_EGL_TRY_RETURN(thread, display->createPbufferSurface(configuration, attributes, &surface), in CreatePbufferSurface()
200 EGLSurface CreatePixmapSurface(Thread *thread, in CreatePixmapSurface() argument
206 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglCreatePixmapSurface", in CreatePixmapSurface()
209 ANGLE_EGL_TRY_RETURN(thread, in CreatePixmapSurface()
213 thread->setSuccess(); in CreatePixmapSurface()
217 EGLSurface CreatePlatformPixmapSurface(Thread *thread, in CreatePlatformPixmapSurface() argument
223 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglCreatePlatformPixmapSurface", in CreatePlatformPixmapSurface()
228 thread, display->createPixmapSurface(configuration, nativePixmap, attributes, &surface), in CreatePlatformPixmapSurface()
231 thread->setSuccess(); in CreatePlatformPixmapSurface()
235 EGLSurface CreatePlatformWindowSurface(Thread *thread, in CreatePlatformWindowSurface() argument
241 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglCreatePlatformWindowSurface", in CreatePlatformWindowSurface()
246 thread, display->createWindowSurface(configuration, nativeWindow, attributes, &surface), in CreatePlatformWindowSurface()
252 EGLSync CreateSync(Thread *thread, Display *display, EGLenum type, const AttributeMap &attributes) in CreateSync() argument
254 gl::Context *currentContext = thread->getContext(); in CreateSync()
256 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglCreateSync", in CreateSync()
259 ANGLE_EGL_TRY_RETURN(thread, display->createSync(currentContext, type, attributes, &syncObject), in CreateSync()
262 thread->setSuccess(); in CreateSync()
266 EGLSurface CreateWindowSurface(Thread *thread, in CreateWindowSurface() argument
272 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglCreateWindowSurface", in CreateWindowSurface()
276 ANGLE_EGL_TRY_RETURN(thread, in CreateWindowSurface()
283 EGLBoolean DestroyContext(Thread *thread, Display *display, gl::ContextID contextID) in DestroyContext() argument
287 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglDestroyContext", in DestroyContext()
290 ScopedSyncCurrentContextFromThread scopedSyncCurrent(thread); in DestroyContext()
292 ANGLE_EGL_TRY_RETURN(thread, display->destroyContext(thread, context), "eglDestroyContext", in DestroyContext()
294 thread->setSuccess(); in DestroyContext()
298 EGLBoolean DestroyImage(Thread *thread, Display *display, ImageID imageID) in DestroyImage() argument
301 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglDestroyImage", in DestroyImage()
305 thread->setSuccess(); in DestroyImage()
309 EGLBoolean DestroySurface(Thread *thread, Display *display, egl::SurfaceID surfaceID) in DestroySurface() argument
313 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglDestroySurface", in DestroySurface()
316 ANGLE_EGL_TRY_RETURN(thread, display->destroySurface(eglSurface), "eglDestroySurface", in DestroySurface()
319 thread->setSuccess(); in DestroySurface()
323 EGLBoolean DestroySync(Thread *thread, Display *display, SyncID syncID) in DestroySync() argument
326 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglDestroySync", in DestroySync()
330 thread->setSuccess(); in DestroySync()
334 EGLBoolean GetConfigAttrib(Thread *thread, in GetConfigAttrib() argument
342 thread->setSuccess(); in GetConfigAttrib()
346 EGLBoolean GetConfigs(Thread *thread, in GetConfigs() argument
354 thread->setSuccess(); in GetConfigs()
358 EGLContext GetCurrentContext(Thread *thread) in GetCurrentContext() argument
360 gl::Context *context = thread->getContext(); in GetCurrentContext()
362 thread->setSuccess(); in GetCurrentContext()
366 EGLDisplay GetCurrentDisplay(Thread *thread) in GetCurrentDisplay() argument
368 thread->setSuccess(); in GetCurrentDisplay()
369 if (thread->getContext() != nullptr) in GetCurrentDisplay()
371 return thread->getContext()->getDisplay(); in GetCurrentDisplay()
376 EGLSurface GetCurrentSurface(Thread *thread, EGLint readdraw) in GetCurrentSurface() argument
379 (readdraw == EGL_READ) ? thread->getCurrentReadSurface() : thread->getCurrentDrawSurface(); in GetCurrentSurface()
380 thread->setSuccess(); in GetCurrentSurface()
391 EGLDisplay GetDisplay(Thread *thread, EGLNativeDisplayType display_id) in GetDisplay() argument
397 EGLint GetError(Thread *thread) in GetError() argument
399 EGLint error = thread->getError(); in GetError()
400 thread->setSuccess(); in GetError()
404 EGLDisplay GetPlatformDisplay(Thread *thread, in GetPlatformDisplay() argument
431 __eglMustCastToProperFunctionPointerType GetProcAddress(Thread *thread, const char *procname) in GetProcAddress() argument
436 thread->setSuccess(); in GetProcAddress()
446 EGLBoolean GetSyncAttrib(Thread *thread, in GetSyncAttrib() argument
453 ANGLE_EGL_TRY_RETURN(thread, GetSyncAttrib(display, syncID, attribute, &valueExt), in GetSyncAttrib()
457 thread->setSuccess(); in GetSyncAttrib()
461 EGLBoolean Initialize(Thread *thread, Display *display, EGLint *major, EGLint *minor) in Initialize() argument
463 ANGLE_EGL_TRY_RETURN(thread, display->initialize(), "eglInitialize", GetDisplayIfValid(display), in Initialize()
475 thread->setSuccess(); in Initialize()
479 EGLBoolean MakeCurrent(Thread *thread, in MakeCurrent() argument
489 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglMakeCurrent", in MakeCurrent()
491 ScopedSyncCurrentContextFromThread scopedSyncCurrent(thread); in MakeCurrent()
493 Surface *previousDraw = thread->getCurrentDrawSurface(); in MakeCurrent()
494 Surface *previousRead = thread->getCurrentReadSurface(); in MakeCurrent()
495 gl::Context *previousContext = thread->getContext(); in MakeCurrent()
501 thread, in MakeCurrent()
502 display->makeCurrent(thread, previousContext, drawSurface, readSurface, context), in MakeCurrent()
506 thread->setSuccess(); in MakeCurrent()
510 EGLenum QueryAPI(Thread *thread) in QueryAPI() argument
512 EGLenum API = thread->getAPI(); in QueryAPI()
514 thread->setSuccess(); in QueryAPI()
518 EGLBoolean QueryContext(Thread *thread, in QueryContext() argument
526 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglQueryContext", in QueryContext()
530 thread->setSuccess(); in QueryContext()
534 const char *QueryString(Thread *thread, Display *display, EGLint name) in QueryString() argument
538 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglQueryString", in QueryString()
573 thread->setSuccess(); in QueryString()
577 EGLBoolean QuerySurface(Thread *thread, in QuerySurface() argument
585 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglQuerySurface", in QuerySurface()
595 context = thread->getContext(); in QuerySurface()
603 ANGLE_EGL_TRY_RETURN(thread, QuerySurfaceAttrib(display, context, eglSurface, attribute, value), in QuerySurface()
606 thread->setSuccess(); in QuerySurface()
610 EGLBoolean ReleaseTexImage(Thread *thread, in ReleaseTexImage() argument
617 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglReleaseTexImage", in ReleaseTexImage()
619 gl::Context *context = thread->getContext(); in ReleaseTexImage()
626 ANGLE_EGL_TRY_RETURN(thread, eglSurface->releaseTexImage(thread->getContext(), buffer), in ReleaseTexImage()
631 thread->setSuccess(); in ReleaseTexImage()
635 EGLBoolean ReleaseThread(Thread *thread) in ReleaseThread() argument
637 ScopedSyncCurrentContextFromThread scopedSyncCurrent(thread); in ReleaseThread()
639 Surface *previousDraw = thread->getCurrentDrawSurface(); in ReleaseThread()
640 Surface *previousRead = thread->getCurrentReadSurface(); in ReleaseThread()
641 gl::Context *previousContext = thread->getContext(); in ReleaseThread()
642 Display *previousDisplay = thread->getDisplay(); in ReleaseThread()
646 ANGLE_EGL_TRY_RETURN(thread, previousDisplay->prepareForCall(), "eglReleaseThread", in ReleaseThread()
653 thread, in ReleaseThread()
654 previousDisplay->makeCurrent(thread, previousContext, nullptr, nullptr, nullptr), in ReleaseThread()
657 ANGLE_EGL_TRY_RETURN(thread, previousDisplay->releaseThread(), "eglReleaseThread", in ReleaseThread()
661 thread->setSuccess(); in ReleaseThread()
665 EGLBoolean SurfaceAttrib(Thread *thread, in SurfaceAttrib() argument
673 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglSurfaceAttrib", in SurfaceAttrib()
676 ANGLE_EGL_TRY_RETURN(thread, SetSurfaceAttrib(eglSurface, attribute, value), "eglSurfaceAttrib", in SurfaceAttrib()
679 thread->setSuccess(); in SurfaceAttrib()
683 EGLBoolean SwapBuffers(Thread *thread, Display *display, egl::SurfaceID surfaceID) in SwapBuffers() argument
687 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglSwapBuffers", in SwapBuffers()
690 ANGLE_EGL_TRY_RETURN(thread, eglSurface->swap(thread->getContext()), "eglSwapBuffers", in SwapBuffers()
693 thread->setSuccess(); in SwapBuffers()
697 EGLBoolean SwapInterval(Thread *thread, Display *display, EGLint interval) in SwapInterval() argument
699 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglSwapInterval", in SwapInterval()
702 Surface *drawSurface = static_cast<Surface *>(thread->getCurrentDrawSurface()); in SwapInterval()
709 thread->setSuccess(); in SwapInterval()
713 EGLBoolean Terminate(Thread *thread, Display *display) in Terminate() argument
715 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglTerminate", in Terminate()
718 ScopedSyncCurrentContextFromThread scopedSyncCurrent(thread); in Terminate()
720 ANGLE_EGL_TRY_RETURN(thread, display->terminate(thread, Display::TerminateReason::Api), in Terminate()
723 thread->setSuccess(); in Terminate()
727 EGLBoolean WaitClient(Thread *thread) in WaitClient() argument
729 Display *display = thread->getDisplay(); in WaitClient()
738 gl::Context *context = thread->getContext(); in WaitClient()
740 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglWaitClient", in WaitClient()
742 ANGLE_EGL_TRY_RETURN(thread, display->waitClient(context), "eglWaitClient", in WaitClient()
745 thread->setSuccess(); in WaitClient()
749 EGLBoolean WaitGL(Thread *thread) in WaitGL() argument
751 Display *display = thread->getDisplay(); in WaitGL()
759 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglWaitGL", GetDisplayIfValid(display), in WaitGL()
764 ANGLE_EGL_TRY_RETURN(thread, display->waitClient(thread->getContext()), "eglWaitGL", in WaitGL()
767 thread->setSuccess(); in WaitGL()
771 EGLBoolean WaitNative(Thread *thread, EGLint engine) in WaitNative() argument
773 Display *display = thread->getDisplay(); in WaitNative()
781 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglWaitNative", in WaitNative()
783 ANGLE_EGL_TRY_RETURN(thread, display->waitNative(thread->getContext(), engine), "eglWaitNative", in WaitNative()
784 GetThreadIfValid(thread), EGL_FALSE); in WaitNative()
786 thread->setSuccess(); in WaitNative()
790 EGLBoolean WaitSync(Thread *thread, Display *display, SyncID syncID, EGLint flags) in WaitSync() argument
792 ANGLE_EGL_TRY_RETURN(thread, display->prepareForCall(), "eglWaitSync", in WaitSync()
794 gl::Context *currentContext = thread->getContext(); in WaitSync()
796 ANGLE_EGL_TRY_RETURN(thread, syncObject->serverWait(display, currentContext, flags), in WaitSync()
799 thread->setSuccess(); in WaitSync()