Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(255)

Unified Diff: ui/gl/gl_bindings_autogen_egl.cc

Issue 2629633003: Refactor GL bindings so there is no global GLApi or DriverGL. (Closed)
Patch Set: rebase Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/gl/gl_bindings.h ('k') | ui/gl/gl_bindings_autogen_gl0.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/gl/gl_bindings_autogen_egl.cc
diff --git a/ui/gl/gl_bindings_autogen_egl.cc b/ui/gl/gl_bindings_autogen_egl.cc
index ed0a6cf5ab84bf78c54aa0e6066100373ac3928f..79cc51cc5badb9bdb9fedf9b187b3c8910756426 100644
--- a/ui/gl/gl_bindings_autogen_egl.cc
+++ b/ui/gl/gl_bindings_autogen_egl.cc
@@ -20,7 +20,6 @@
namespace gl {
-static bool g_debugBindingsInitialized;
DriverEGL g_driver_egl;
void DriverEGL::InitializeStaticBindings() {
@@ -131,7 +130,6 @@ void DriverEGL::InitializeClientExtensionBindings() {
ext.b_EGL_EXT_platform_base =
client_extensions.find("EGL_EXT_platform_base ") != std::string::npos;
- debug_fn.eglGetPlatformDisplayEXTFn = 0;
if (ext.b_EGL_EXT_platform_base) {
fn.eglGetPlatformDisplayEXTFn =
reinterpret_cast<eglGetPlatformDisplayEXTProc>(
@@ -186,1884 +184,1520 @@ void DriverEGL::InitializeExtensionBindings() {
extensions.find("GL_CHROMIUM_egl_khr_fence_sync_hack ") !=
std::string::npos;
- debug_fn.eglCreateImageKHRFn = 0;
if (ext.b_EGL_KHR_image || ext.b_EGL_KHR_image_base ||
ext.b_EGL_KHR_gl_texture_2D_image) {
fn.eglCreateImageKHRFn = reinterpret_cast<eglCreateImageKHRProc>(
GetGLProcAddress("eglCreateImageKHR"));
}
- debug_fn.eglCreateStreamKHRFn = 0;
if (ext.b_EGL_KHR_stream) {
fn.eglCreateStreamKHRFn = reinterpret_cast<eglCreateStreamKHRProc>(
GetGLProcAddress("eglCreateStreamKHR"));
}
- debug_fn.eglCreateStreamProducerD3DTextureNV12ANGLEFn = 0;
if (ext.b_EGL_ANGLE_stream_producer_d3d_texture_nv12) {
fn.eglCreateStreamProducerD3DTextureNV12ANGLEFn =
reinterpret_cast<eglCreateStreamProducerD3DTextureNV12ANGLEProc>(
GetGLProcAddress("eglCreateStreamProducerD3DTextureNV12ANGLE"));
}
- debug_fn.eglDestroyImageKHRFn = 0;
if (ext.b_EGL_KHR_image || ext.b_EGL_KHR_image_base) {
fn.eglDestroyImageKHRFn = reinterpret_cast<eglDestroyImageKHRProc>(
GetGLProcAddress("eglDestroyImageKHR"));
}
- debug_fn.eglDestroyStreamKHRFn = 0;
if (ext.b_EGL_KHR_stream) {
fn.eglDestroyStreamKHRFn = reinterpret_cast<eglDestroyStreamKHRProc>(
GetGLProcAddress("eglDestroyStreamKHR"));
}
- debug_fn.eglGetSyncValuesCHROMIUMFn = 0;
if (ext.b_EGL_CHROMIUM_sync_control) {
fn.eglGetSyncValuesCHROMIUMFn =
reinterpret_cast<eglGetSyncValuesCHROMIUMProc>(
GetGLProcAddress("eglGetSyncValuesCHROMIUM"));
}
- debug_fn.eglImageFlushExternalEXTFn = 0;
if (ext.b_EGL_EXT_image_flush_external) {
fn.eglImageFlushExternalEXTFn =
reinterpret_cast<eglImageFlushExternalEXTProc>(
GetGLProcAddress("eglImageFlushExternalEXT"));
}
- debug_fn.eglPostSubBufferNVFn = 0;
if (ext.b_EGL_NV_post_sub_buffer) {
fn.eglPostSubBufferNVFn = reinterpret_cast<eglPostSubBufferNVProc>(
GetGLProcAddress("eglPostSubBufferNV"));
}
- debug_fn.eglQueryStreamKHRFn = 0;
if (ext.b_EGL_KHR_stream) {
fn.eglQueryStreamKHRFn = reinterpret_cast<eglQueryStreamKHRProc>(
GetGLProcAddress("eglQueryStreamKHR"));
}
- debug_fn.eglQueryStreamu64KHRFn = 0;
if (ext.b_EGL_KHR_stream) {
fn.eglQueryStreamu64KHRFn = reinterpret_cast<eglQueryStreamu64KHRProc>(
GetGLProcAddress("eglQueryStreamu64KHR"));
}
- debug_fn.eglQuerySurfacePointerANGLEFn = 0;
if (ext.b_EGL_ANGLE_query_surface_pointer) {
fn.eglQuerySurfacePointerANGLEFn =
reinterpret_cast<eglQuerySurfacePointerANGLEProc>(
GetGLProcAddress("eglQuerySurfacePointerANGLE"));
}
- debug_fn.eglStreamAttribKHRFn = 0;
if (ext.b_EGL_KHR_stream) {
fn.eglStreamAttribKHRFn = reinterpret_cast<eglStreamAttribKHRProc>(
GetGLProcAddress("eglStreamAttribKHR"));
}
- debug_fn.eglStreamConsumerAcquireKHRFn = 0;
if (ext.b_EGL_KHR_stream_consumer_gltexture) {
fn.eglStreamConsumerAcquireKHRFn =
reinterpret_cast<eglStreamConsumerAcquireKHRProc>(
GetGLProcAddress("eglStreamConsumerAcquireKHR"));
}
- debug_fn.eglStreamConsumerGLTextureExternalAttribsNVFn = 0;
if (ext.b_EGL_NV_stream_consumer_gltexture_yuv) {
fn.eglStreamConsumerGLTextureExternalAttribsNVFn =
reinterpret_cast<eglStreamConsumerGLTextureExternalAttribsNVProc>(
GetGLProcAddress("eglStreamConsumerGLTextureExternalAttribsNV"));
}
- debug_fn.eglStreamConsumerGLTextureExternalKHRFn = 0;
if (ext.b_EGL_KHR_stream_consumer_gltexture) {
fn.eglStreamConsumerGLTextureExternalKHRFn =
reinterpret_cast<eglStreamConsumerGLTextureExternalKHRProc>(
GetGLProcAddress("eglStreamConsumerGLTextureExternalKHR"));
}
- debug_fn.eglStreamConsumerReleaseKHRFn = 0;
if (ext.b_EGL_KHR_stream_consumer_gltexture) {
fn.eglStreamConsumerReleaseKHRFn =
reinterpret_cast<eglStreamConsumerReleaseKHRProc>(
GetGLProcAddress("eglStreamConsumerReleaseKHR"));
}
- debug_fn.eglStreamPostD3DTextureNV12ANGLEFn = 0;
if (ext.b_EGL_ANGLE_stream_producer_d3d_texture_nv12) {
fn.eglStreamPostD3DTextureNV12ANGLEFn =
reinterpret_cast<eglStreamPostD3DTextureNV12ANGLEProc>(
GetGLProcAddress("eglStreamPostD3DTextureNV12ANGLE"));
}
- debug_fn.eglSwapBuffersWithDamageKHRFn = 0;
if (ext.b_EGL_KHR_swap_buffers_with_damage) {
fn.eglSwapBuffersWithDamageKHRFn =
reinterpret_cast<eglSwapBuffersWithDamageKHRProc>(
GetGLProcAddress("eglSwapBuffersWithDamageKHR"));
}
- debug_fn.eglWaitSyncKHRFn = 0;
if (ext.b_EGL_KHR_wait_sync) {
fn.eglWaitSyncKHRFn = reinterpret_cast<eglWaitSyncKHRProc>(
GetGLProcAddress("eglWaitSyncKHR"));
}
-
- if (g_debugBindingsInitialized)
- InitializeDebugBindings();
}
-extern "C" {
+void DriverEGL::ClearBindings() {
+ memset(this, 0, sizeof(*this));
+}
-static EGLBoolean GL_BINDING_CALL Debug_eglBindAPI(EGLenum api) {
- GL_SERVICE_LOG("eglBindAPI"
- << "(" << api << ")");
- DCHECK(g_driver_egl.debug_fn.eglBindAPIFn != nullptr);
- EGLBoolean result = g_driver_egl.debug_fn.eglBindAPIFn(api);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglBindAPIFn(EGLenum api) {
+ return driver_->fn.eglBindAPIFn(api);
}
-static EGLBoolean GL_BINDING_CALL Debug_eglBindTexImage(EGLDisplay dpy,
- EGLSurface surface,
- EGLint buffer) {
- GL_SERVICE_LOG("eglBindTexImage"
- << "(" << dpy << ", " << surface << ", " << buffer << ")");
- DCHECK(g_driver_egl.debug_fn.eglBindTexImageFn != nullptr);
- EGLBoolean result =
- g_driver_egl.debug_fn.eglBindTexImageFn(dpy, surface, buffer);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglBindTexImageFn(EGLDisplay dpy,
+ EGLSurface surface,
+ EGLint buffer) {
+ return driver_->fn.eglBindTexImageFn(dpy, surface, buffer);
}
-static EGLBoolean GL_BINDING_CALL
-Debug_eglChooseConfig(EGLDisplay dpy,
- const EGLint* attrib_list,
- EGLConfig* configs,
- EGLint config_size,
- EGLint* num_config) {
- GL_SERVICE_LOG("eglChooseConfig"
- << "(" << dpy << ", " << static_cast<const void*>(attrib_list)
- << ", " << static_cast<const void*>(configs) << ", "
- << config_size << ", " << static_cast<const void*>(num_config)
- << ")");
- DCHECK(g_driver_egl.debug_fn.eglChooseConfigFn != nullptr);
- EGLBoolean result = g_driver_egl.debug_fn.eglChooseConfigFn(
- dpy, attrib_list, configs, config_size, num_config);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglChooseConfigFn(EGLDisplay dpy,
+ const EGLint* attrib_list,
+ EGLConfig* configs,
+ EGLint config_size,
+ EGLint* num_config) {
+ return driver_->fn.eglChooseConfigFn(dpy, attrib_list, configs, config_size,
+ num_config);
}
-static EGLint GL_BINDING_CALL Debug_eglClientWaitSyncKHR(EGLDisplay dpy,
- EGLSyncKHR sync,
- EGLint flags,
- EGLTimeKHR timeout) {
- GL_SERVICE_LOG("eglClientWaitSyncKHR"
- << "(" << dpy << ", " << sync << ", " << flags << ", "
- << timeout << ")");
- DCHECK(g_driver_egl.debug_fn.eglClientWaitSyncKHRFn != nullptr);
- EGLint result =
- g_driver_egl.debug_fn.eglClientWaitSyncKHRFn(dpy, sync, flags, timeout);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLint EGLApiBase::eglClientWaitSyncKHRFn(EGLDisplay dpy,
+ EGLSyncKHR sync,
+ EGLint flags,
+ EGLTimeKHR timeout) {
+ return driver_->fn.eglClientWaitSyncKHRFn(dpy, sync, flags, timeout);
}
-static EGLBoolean GL_BINDING_CALL
-Debug_eglCopyBuffers(EGLDisplay dpy,
- EGLSurface surface,
- EGLNativePixmapType target) {
- GL_SERVICE_LOG("eglCopyBuffers"
- << "(" << dpy << ", " << surface << ", " << target << ")");
- DCHECK(g_driver_egl.debug_fn.eglCopyBuffersFn != nullptr);
- EGLBoolean result =
- g_driver_egl.debug_fn.eglCopyBuffersFn(dpy, surface, target);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglCopyBuffersFn(EGLDisplay dpy,
+ EGLSurface surface,
+ EGLNativePixmapType target) {
+ return driver_->fn.eglCopyBuffersFn(dpy, surface, target);
}
-static EGLContext GL_BINDING_CALL
-Debug_eglCreateContext(EGLDisplay dpy,
- EGLConfig config,
- EGLContext share_context,
- const EGLint* attrib_list) {
- GL_SERVICE_LOG("eglCreateContext"
- << "(" << dpy << ", " << config << ", " << share_context
- << ", " << static_cast<const void*>(attrib_list) << ")");
- DCHECK(g_driver_egl.debug_fn.eglCreateContextFn != nullptr);
- EGLContext result = g_driver_egl.debug_fn.eglCreateContextFn(
- dpy, config, share_context, attrib_list);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLContext EGLApiBase::eglCreateContextFn(EGLDisplay dpy,
+ EGLConfig config,
+ EGLContext share_context,
+ const EGLint* attrib_list) {
+ return driver_->fn.eglCreateContextFn(dpy, config, share_context,
+ attrib_list);
}
-static EGLImageKHR GL_BINDING_CALL
-Debug_eglCreateImageKHR(EGLDisplay dpy,
- EGLContext ctx,
- EGLenum target,
- EGLClientBuffer buffer,
- const EGLint* attrib_list) {
- GL_SERVICE_LOG("eglCreateImageKHR"
- << "(" << dpy << ", " << ctx << ", " << target << ", "
- << buffer << ", " << static_cast<const void*>(attrib_list)
- << ")");
- DCHECK(g_driver_egl.debug_fn.eglCreateImageKHRFn != nullptr);
- EGLImageKHR result = g_driver_egl.debug_fn.eglCreateImageKHRFn(
- dpy, ctx, target, buffer, attrib_list);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLImageKHR EGLApiBase::eglCreateImageKHRFn(EGLDisplay dpy,
+ EGLContext ctx,
+ EGLenum target,
+ EGLClientBuffer buffer,
+ const EGLint* attrib_list) {
+ return driver_->fn.eglCreateImageKHRFn(dpy, ctx, target, buffer, attrib_list);
}
-static EGLSurface GL_BINDING_CALL
-Debug_eglCreatePbufferFromClientBuffer(EGLDisplay dpy,
- EGLenum buftype,
- void* buffer,
- EGLConfig config,
- const EGLint* attrib_list) {
- GL_SERVICE_LOG("eglCreatePbufferFromClientBuffer"
- << "(" << dpy << ", " << buftype << ", "
- << static_cast<const void*>(buffer) << ", " << config << ", "
- << static_cast<const void*>(attrib_list) << ")");
- DCHECK(g_driver_egl.debug_fn.eglCreatePbufferFromClientBufferFn != nullptr);
- EGLSurface result = g_driver_egl.debug_fn.eglCreatePbufferFromClientBufferFn(
- dpy, buftype, buffer, config, attrib_list);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLSurface EGLApiBase::eglCreatePbufferFromClientBufferFn(
+ EGLDisplay dpy,
+ EGLenum buftype,
+ void* buffer,
+ EGLConfig config,
+ const EGLint* attrib_list) {
+ return driver_->fn.eglCreatePbufferFromClientBufferFn(dpy, buftype, buffer,
+ config, attrib_list);
}
-static EGLSurface GL_BINDING_CALL
-Debug_eglCreatePbufferSurface(EGLDisplay dpy,
- EGLConfig config,
- const EGLint* attrib_list) {
- GL_SERVICE_LOG("eglCreatePbufferSurface"
- << "(" << dpy << ", " << config << ", "
- << static_cast<const void*>(attrib_list) << ")");
- DCHECK(g_driver_egl.debug_fn.eglCreatePbufferSurfaceFn != nullptr);
- EGLSurface result =
- g_driver_egl.debug_fn.eglCreatePbufferSurfaceFn(dpy, config, attrib_list);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLSurface EGLApiBase::eglCreatePbufferSurfaceFn(EGLDisplay dpy,
+ EGLConfig config,
+ const EGLint* attrib_list) {
+ return driver_->fn.eglCreatePbufferSurfaceFn(dpy, config, attrib_list);
}
-static EGLSurface GL_BINDING_CALL
-Debug_eglCreatePixmapSurface(EGLDisplay dpy,
- EGLConfig config,
- EGLNativePixmapType pixmap,
- const EGLint* attrib_list) {
- GL_SERVICE_LOG("eglCreatePixmapSurface"
- << "(" << dpy << ", " << config << ", " << pixmap << ", "
- << static_cast<const void*>(attrib_list) << ")");
- DCHECK(g_driver_egl.debug_fn.eglCreatePixmapSurfaceFn != nullptr);
- EGLSurface result = g_driver_egl.debug_fn.eglCreatePixmapSurfaceFn(
- dpy, config, pixmap, attrib_list);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLSurface EGLApiBase::eglCreatePixmapSurfaceFn(EGLDisplay dpy,
+ EGLConfig config,
+ EGLNativePixmapType pixmap,
+ const EGLint* attrib_list) {
+ return driver_->fn.eglCreatePixmapSurfaceFn(dpy, config, pixmap, attrib_list);
}
-static EGLStreamKHR GL_BINDING_CALL
-Debug_eglCreateStreamKHR(EGLDisplay dpy, const EGLint* attrib_list) {
- GL_SERVICE_LOG("eglCreateStreamKHR"
- << "(" << dpy << ", " << static_cast<const void*>(attrib_list)
- << ")");
- DCHECK(g_driver_egl.debug_fn.eglCreateStreamKHRFn != nullptr);
- EGLStreamKHR result =
- g_driver_egl.debug_fn.eglCreateStreamKHRFn(dpy, attrib_list);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLStreamKHR EGLApiBase::eglCreateStreamKHRFn(EGLDisplay dpy,
+ const EGLint* attrib_list) {
+ return driver_->fn.eglCreateStreamKHRFn(dpy, attrib_list);
}
-static EGLBoolean GL_BINDING_CALL
-Debug_eglCreateStreamProducerD3DTextureNV12ANGLE(EGLDisplay dpy,
- EGLStreamKHR stream,
- EGLAttrib* attrib_list) {
- GL_SERVICE_LOG("eglCreateStreamProducerD3DTextureNV12ANGLE"
- << "(" << dpy << ", " << stream << ", "
- << static_cast<const void*>(attrib_list) << ")");
- DCHECK(g_driver_egl.debug_fn.eglCreateStreamProducerD3DTextureNV12ANGLEFn !=
- nullptr);
- EGLBoolean result =
- g_driver_egl.debug_fn.eglCreateStreamProducerD3DTextureNV12ANGLEFn(
- dpy, stream, attrib_list);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglCreateStreamProducerD3DTextureNV12ANGLEFn(
+ EGLDisplay dpy,
+ EGLStreamKHR stream,
+ EGLAttrib* attrib_list) {
+ return driver_->fn.eglCreateStreamProducerD3DTextureNV12ANGLEFn(dpy, stream,
+ attrib_list);
}
-static EGLSyncKHR GL_BINDING_CALL
-Debug_eglCreateSyncKHR(EGLDisplay dpy,
- EGLenum type,
- const EGLint* attrib_list) {
- GL_SERVICE_LOG("eglCreateSyncKHR"
- << "(" << dpy << ", " << type << ", "
- << static_cast<const void*>(attrib_list) << ")");
- DCHECK(g_driver_egl.debug_fn.eglCreateSyncKHRFn != nullptr);
- EGLSyncKHR result =
- g_driver_egl.debug_fn.eglCreateSyncKHRFn(dpy, type, attrib_list);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLSyncKHR EGLApiBase::eglCreateSyncKHRFn(EGLDisplay dpy,
+ EGLenum type,
+ const EGLint* attrib_list) {
+ return driver_->fn.eglCreateSyncKHRFn(dpy, type, attrib_list);
}
-static EGLSurface GL_BINDING_CALL
-Debug_eglCreateWindowSurface(EGLDisplay dpy,
- EGLConfig config,
- EGLNativeWindowType win,
- const EGLint* attrib_list) {
- GL_SERVICE_LOG("eglCreateWindowSurface"
- << "(" << dpy << ", " << config << ", " << win << ", "
- << static_cast<const void*>(attrib_list) << ")");
- DCHECK(g_driver_egl.debug_fn.eglCreateWindowSurfaceFn != nullptr);
- EGLSurface result = g_driver_egl.debug_fn.eglCreateWindowSurfaceFn(
- dpy, config, win, attrib_list);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLSurface EGLApiBase::eglCreateWindowSurfaceFn(EGLDisplay dpy,
+ EGLConfig config,
+ EGLNativeWindowType win,
+ const EGLint* attrib_list) {
+ return driver_->fn.eglCreateWindowSurfaceFn(dpy, config, win, attrib_list);
}
-static EGLBoolean GL_BINDING_CALL Debug_eglDestroyContext(EGLDisplay dpy,
- EGLContext ctx) {
- GL_SERVICE_LOG("eglDestroyContext"
- << "(" << dpy << ", " << ctx << ")");
- DCHECK(g_driver_egl.debug_fn.eglDestroyContextFn != nullptr);
- EGLBoolean result = g_driver_egl.debug_fn.eglDestroyContextFn(dpy, ctx);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglDestroyContextFn(EGLDisplay dpy, EGLContext ctx) {
+ return driver_->fn.eglDestroyContextFn(dpy, ctx);
}
-static EGLBoolean GL_BINDING_CALL Debug_eglDestroyImageKHR(EGLDisplay dpy,
- EGLImageKHR image) {
- GL_SERVICE_LOG("eglDestroyImageKHR"
- << "(" << dpy << ", " << image << ")");
- DCHECK(g_driver_egl.debug_fn.eglDestroyImageKHRFn != nullptr);
- EGLBoolean result = g_driver_egl.debug_fn.eglDestroyImageKHRFn(dpy, image);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglDestroyImageKHRFn(EGLDisplay dpy, EGLImageKHR image) {
+ return driver_->fn.eglDestroyImageKHRFn(dpy, image);
}
-static EGLBoolean GL_BINDING_CALL
-Debug_eglDestroyStreamKHR(EGLDisplay dpy, EGLStreamKHR stream) {
- GL_SERVICE_LOG("eglDestroyStreamKHR"
- << "(" << dpy << ", " << stream << ")");
- DCHECK(g_driver_egl.debug_fn.eglDestroyStreamKHRFn != nullptr);
- EGLBoolean result = g_driver_egl.debug_fn.eglDestroyStreamKHRFn(dpy, stream);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglDestroyStreamKHRFn(EGLDisplay dpy,
+ EGLStreamKHR stream) {
+ return driver_->fn.eglDestroyStreamKHRFn(dpy, stream);
}
-static EGLBoolean GL_BINDING_CALL Debug_eglDestroySurface(EGLDisplay dpy,
- EGLSurface surface) {
- GL_SERVICE_LOG("eglDestroySurface"
- << "(" << dpy << ", " << surface << ")");
- DCHECK(g_driver_egl.debug_fn.eglDestroySurfaceFn != nullptr);
- EGLBoolean result = g_driver_egl.debug_fn.eglDestroySurfaceFn(dpy, surface);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglDestroySurfaceFn(EGLDisplay dpy, EGLSurface surface) {
+ return driver_->fn.eglDestroySurfaceFn(dpy, surface);
}
-static EGLBoolean GL_BINDING_CALL Debug_eglDestroySyncKHR(EGLDisplay dpy,
- EGLSyncKHR sync) {
- GL_SERVICE_LOG("eglDestroySyncKHR"
- << "(" << dpy << ", " << sync << ")");
- DCHECK(g_driver_egl.debug_fn.eglDestroySyncKHRFn != nullptr);
- EGLBoolean result = g_driver_egl.debug_fn.eglDestroySyncKHRFn(dpy, sync);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglDestroySyncKHRFn(EGLDisplay dpy, EGLSyncKHR sync) {
+ return driver_->fn.eglDestroySyncKHRFn(dpy, sync);
}
-static EGLBoolean GL_BINDING_CALL Debug_eglGetConfigAttrib(EGLDisplay dpy,
- EGLConfig config,
- EGLint attribute,
- EGLint* value) {
- GL_SERVICE_LOG("eglGetConfigAttrib"
- << "(" << dpy << ", " << config << ", " << attribute << ", "
- << static_cast<const void*>(value) << ")");
- DCHECK(g_driver_egl.debug_fn.eglGetConfigAttribFn != nullptr);
- EGLBoolean result =
- g_driver_egl.debug_fn.eglGetConfigAttribFn(dpy, config, attribute, value);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglGetConfigAttribFn(EGLDisplay dpy,
+ EGLConfig config,
+ EGLint attribute,
+ EGLint* value) {
+ return driver_->fn.eglGetConfigAttribFn(dpy, config, attribute, value);
}
-static EGLBoolean GL_BINDING_CALL Debug_eglGetConfigs(EGLDisplay dpy,
- EGLConfig* configs,
- EGLint config_size,
- EGLint* num_config) {
- GL_SERVICE_LOG("eglGetConfigs"
- << "(" << dpy << ", " << static_cast<const void*>(configs)
- << ", " << config_size << ", "
- << static_cast<const void*>(num_config) << ")");
- DCHECK(g_driver_egl.debug_fn.eglGetConfigsFn != nullptr);
- EGLBoolean result = g_driver_egl.debug_fn.eglGetConfigsFn(
- dpy, configs, config_size, num_config);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglGetConfigsFn(EGLDisplay dpy,
+ EGLConfig* configs,
+ EGLint config_size,
+ EGLint* num_config) {
+ return driver_->fn.eglGetConfigsFn(dpy, configs, config_size, num_config);
}
-static EGLContext GL_BINDING_CALL Debug_eglGetCurrentContext(void) {
- GL_SERVICE_LOG("eglGetCurrentContext"
- << "("
- << ")");
- DCHECK(g_driver_egl.debug_fn.eglGetCurrentContextFn != nullptr);
- EGLContext result = g_driver_egl.debug_fn.eglGetCurrentContextFn();
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLContext EGLApiBase::eglGetCurrentContextFn(void) {
+ return driver_->fn.eglGetCurrentContextFn();
}
-static EGLDisplay GL_BINDING_CALL Debug_eglGetCurrentDisplay(void) {
- GL_SERVICE_LOG("eglGetCurrentDisplay"
- << "("
- << ")");
- DCHECK(g_driver_egl.debug_fn.eglGetCurrentDisplayFn != nullptr);
- EGLDisplay result = g_driver_egl.debug_fn.eglGetCurrentDisplayFn();
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLDisplay EGLApiBase::eglGetCurrentDisplayFn(void) {
+ return driver_->fn.eglGetCurrentDisplayFn();
}
-static EGLSurface GL_BINDING_CALL Debug_eglGetCurrentSurface(EGLint readdraw) {
- GL_SERVICE_LOG("eglGetCurrentSurface"
- << "(" << readdraw << ")");
- DCHECK(g_driver_egl.debug_fn.eglGetCurrentSurfaceFn != nullptr);
- EGLSurface result = g_driver_egl.debug_fn.eglGetCurrentSurfaceFn(readdraw);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLSurface EGLApiBase::eglGetCurrentSurfaceFn(EGLint readdraw) {
+ return driver_->fn.eglGetCurrentSurfaceFn(readdraw);
}
-static EGLDisplay GL_BINDING_CALL
-Debug_eglGetDisplay(EGLNativeDisplayType display_id) {
- GL_SERVICE_LOG("eglGetDisplay"
- << "(" << display_id << ")");
- DCHECK(g_driver_egl.debug_fn.eglGetDisplayFn != nullptr);
- EGLDisplay result = g_driver_egl.debug_fn.eglGetDisplayFn(display_id);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLDisplay EGLApiBase::eglGetDisplayFn(EGLNativeDisplayType display_id) {
+ return driver_->fn.eglGetDisplayFn(display_id);
}
-static EGLint GL_BINDING_CALL Debug_eglGetError(void) {
- GL_SERVICE_LOG("eglGetError"
- << "("
- << ")");
- DCHECK(g_driver_egl.debug_fn.eglGetErrorFn != nullptr);
- EGLint result = g_driver_egl.debug_fn.eglGetErrorFn();
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLint EGLApiBase::eglGetErrorFn(void) {
+ return driver_->fn.eglGetErrorFn();
}
-static EGLDisplay GL_BINDING_CALL
-Debug_eglGetPlatformDisplayEXT(EGLenum platform,
- void* native_display,
- const EGLint* attrib_list) {
- GL_SERVICE_LOG("eglGetPlatformDisplayEXT"
- << "(" << platform << ", "
- << static_cast<const void*>(native_display) << ", "
- << static_cast<const void*>(attrib_list) << ")");
- DCHECK(g_driver_egl.debug_fn.eglGetPlatformDisplayEXTFn != nullptr);
- EGLDisplay result = g_driver_egl.debug_fn.eglGetPlatformDisplayEXTFn(
- platform, native_display, attrib_list);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLDisplay EGLApiBase::eglGetPlatformDisplayEXTFn(EGLenum platform,
+ void* native_display,
+ const EGLint* attrib_list) {
+ return driver_->fn.eglGetPlatformDisplayEXTFn(platform, native_display,
+ attrib_list);
}
-static __eglMustCastToProperFunctionPointerType GL_BINDING_CALL
-Debug_eglGetProcAddress(const char* procname) {
- GL_SERVICE_LOG("eglGetProcAddress"
- << "(" << procname << ")");
- DCHECK(g_driver_egl.debug_fn.eglGetProcAddressFn != nullptr);
- __eglMustCastToProperFunctionPointerType result =
- g_driver_egl.debug_fn.eglGetProcAddressFn(procname);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+__eglMustCastToProperFunctionPointerType EGLApiBase::eglGetProcAddressFn(
+ const char* procname) {
+ return driver_->fn.eglGetProcAddressFn(procname);
}
-static EGLBoolean GL_BINDING_CALL Debug_eglGetSyncAttribKHR(EGLDisplay dpy,
- EGLSyncKHR sync,
- EGLint attribute,
- EGLint* value) {
- GL_SERVICE_LOG("eglGetSyncAttribKHR"
- << "(" << dpy << ", " << sync << ", " << attribute << ", "
- << static_cast<const void*>(value) << ")");
- DCHECK(g_driver_egl.debug_fn.eglGetSyncAttribKHRFn != nullptr);
- EGLBoolean result =
- g_driver_egl.debug_fn.eglGetSyncAttribKHRFn(dpy, sync, attribute, value);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
-}
-
-static EGLBoolean GL_BINDING_CALL
-Debug_eglGetSyncValuesCHROMIUM(EGLDisplay dpy,
- EGLSurface surface,
- EGLuint64CHROMIUM* ust,
- EGLuint64CHROMIUM* msc,
- EGLuint64CHROMIUM* sbc) {
- GL_SERVICE_LOG("eglGetSyncValuesCHROMIUM"
- << "(" << dpy << ", " << surface << ", "
- << static_cast<const void*>(ust) << ", "
- << static_cast<const void*>(msc) << ", "
- << static_cast<const void*>(sbc) << ")");
- DCHECK(g_driver_egl.debug_fn.eglGetSyncValuesCHROMIUMFn != nullptr);
- EGLBoolean result = g_driver_egl.debug_fn.eglGetSyncValuesCHROMIUMFn(
- dpy, surface, ust, msc, sbc);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
-}
-
-static EGLBoolean GL_BINDING_CALL
-Debug_eglImageFlushExternalEXT(EGLDisplay dpy,
- EGLImageKHR image,
- const EGLAttrib* attrib_list) {
- GL_SERVICE_LOG("eglImageFlushExternalEXT"
- << "(" << dpy << ", " << image << ", "
- << static_cast<const void*>(attrib_list) << ")");
- DCHECK(g_driver_egl.debug_fn.eglImageFlushExternalEXTFn != nullptr);
- EGLBoolean result =
- g_driver_egl.debug_fn.eglImageFlushExternalEXTFn(dpy, image, attrib_list);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
-}
-
-static EGLBoolean GL_BINDING_CALL Debug_eglInitialize(EGLDisplay dpy,
- EGLint* major,
- EGLint* minor) {
- GL_SERVICE_LOG("eglInitialize"
- << "(" << dpy << ", " << static_cast<const void*>(major)
- << ", " << static_cast<const void*>(minor) << ")");
- DCHECK(g_driver_egl.debug_fn.eglInitializeFn != nullptr);
- EGLBoolean result = g_driver_egl.debug_fn.eglInitializeFn(dpy, major, minor);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
-}
-
-static EGLBoolean GL_BINDING_CALL Debug_eglMakeCurrent(EGLDisplay dpy,
- EGLSurface draw,
- EGLSurface read,
- EGLContext ctx) {
- GL_SERVICE_LOG("eglMakeCurrent"
- << "(" << dpy << ", " << draw << ", " << read << ", " << ctx
- << ")");
- DCHECK(g_driver_egl.debug_fn.eglMakeCurrentFn != nullptr);
- EGLBoolean result =
- g_driver_egl.debug_fn.eglMakeCurrentFn(dpy, draw, read, ctx);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
-}
-
-static EGLBoolean GL_BINDING_CALL Debug_eglPostSubBufferNV(EGLDisplay dpy,
- EGLSurface surface,
- EGLint x,
- EGLint y,
- EGLint width,
- EGLint height) {
- GL_SERVICE_LOG("eglPostSubBufferNV"
- << "(" << dpy << ", " << surface << ", " << x << ", " << y
- << ", " << width << ", " << height << ")");
- DCHECK(g_driver_egl.debug_fn.eglPostSubBufferNVFn != nullptr);
- EGLBoolean result = g_driver_egl.debug_fn.eglPostSubBufferNVFn(
- dpy, surface, x, y, width, height);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
-}
-
-static EGLenum GL_BINDING_CALL Debug_eglQueryAPI(void) {
- GL_SERVICE_LOG("eglQueryAPI"
- << "("
- << ")");
- DCHECK(g_driver_egl.debug_fn.eglQueryAPIFn != nullptr);
- EGLenum result = g_driver_egl.debug_fn.eglQueryAPIFn();
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
-}
-
-static EGLBoolean GL_BINDING_CALL Debug_eglQueryContext(EGLDisplay dpy,
- EGLContext ctx,
- EGLint attribute,
- EGLint* value) {
- GL_SERVICE_LOG("eglQueryContext"
- << "(" << dpy << ", " << ctx << ", " << attribute << ", "
- << static_cast<const void*>(value) << ")");
- DCHECK(g_driver_egl.debug_fn.eglQueryContextFn != nullptr);
- EGLBoolean result =
- g_driver_egl.debug_fn.eglQueryContextFn(dpy, ctx, attribute, value);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
-}
-
-static EGLBoolean GL_BINDING_CALL Debug_eglQueryStreamKHR(EGLDisplay dpy,
- EGLStreamKHR stream,
- EGLenum attribute,
- EGLint* value) {
- GL_SERVICE_LOG("eglQueryStreamKHR"
- << "(" << dpy << ", " << stream << ", " << attribute << ", "
- << static_cast<const void*>(value) << ")");
- DCHECK(g_driver_egl.debug_fn.eglQueryStreamKHRFn != nullptr);
- EGLBoolean result =
- g_driver_egl.debug_fn.eglQueryStreamKHRFn(dpy, stream, attribute, value);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
-}
-
-static EGLBoolean GL_BINDING_CALL
-Debug_eglQueryStreamu64KHR(EGLDisplay dpy,
- EGLStreamKHR stream,
- EGLenum attribute,
- EGLuint64KHR* value) {
- GL_SERVICE_LOG("eglQueryStreamu64KHR"
- << "(" << dpy << ", " << stream << ", " << attribute << ", "
- << static_cast<const void*>(value) << ")");
- DCHECK(g_driver_egl.debug_fn.eglQueryStreamu64KHRFn != nullptr);
- EGLBoolean result = g_driver_egl.debug_fn.eglQueryStreamu64KHRFn(
- dpy, stream, attribute, value);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
-}
-
-static const char* GL_BINDING_CALL Debug_eglQueryString(EGLDisplay dpy,
- EGLint name) {
- GL_SERVICE_LOG("eglQueryString"
- << "(" << dpy << ", " << name << ")");
- DCHECK(g_driver_egl.debug_fn.eglQueryStringFn != nullptr);
- const char* result = g_driver_egl.debug_fn.eglQueryStringFn(dpy, name);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglGetSyncAttribKHRFn(EGLDisplay dpy,
+ EGLSyncKHR sync,
+ EGLint attribute,
+ EGLint* value) {
+ return driver_->fn.eglGetSyncAttribKHRFn(dpy, sync, attribute, value);
}
-static EGLBoolean GL_BINDING_CALL Debug_eglQuerySurface(EGLDisplay dpy,
- EGLSurface surface,
- EGLint attribute,
- EGLint* value) {
- GL_SERVICE_LOG("eglQuerySurface"
- << "(" << dpy << ", " << surface << ", " << attribute << ", "
- << static_cast<const void*>(value) << ")");
- DCHECK(g_driver_egl.debug_fn.eglQuerySurfaceFn != nullptr);
- EGLBoolean result =
- g_driver_egl.debug_fn.eglQuerySurfaceFn(dpy, surface, attribute, value);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglGetSyncValuesCHROMIUMFn(EGLDisplay dpy,
+ EGLSurface surface,
+ EGLuint64CHROMIUM* ust,
+ EGLuint64CHROMIUM* msc,
+ EGLuint64CHROMIUM* sbc) {
+ return driver_->fn.eglGetSyncValuesCHROMIUMFn(dpy, surface, ust, msc, sbc);
}
-static EGLBoolean GL_BINDING_CALL
-Debug_eglQuerySurfacePointerANGLE(EGLDisplay dpy,
- EGLSurface surface,
- EGLint attribute,
- void** value) {
- GL_SERVICE_LOG("eglQuerySurfacePointerANGLE"
- << "(" << dpy << ", " << surface << ", " << attribute << ", "
- << value << ")");
- DCHECK(g_driver_egl.debug_fn.eglQuerySurfacePointerANGLEFn != nullptr);
- EGLBoolean result = g_driver_egl.debug_fn.eglQuerySurfacePointerANGLEFn(
- dpy, surface, attribute, value);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglImageFlushExternalEXTFn(
+ EGLDisplay dpy,
+ EGLImageKHR image,
+ const EGLAttrib* attrib_list) {
+ return driver_->fn.eglImageFlushExternalEXTFn(dpy, image, attrib_list);
}
-static EGLBoolean GL_BINDING_CALL Debug_eglReleaseTexImage(EGLDisplay dpy,
- EGLSurface surface,
- EGLint buffer) {
- GL_SERVICE_LOG("eglReleaseTexImage"
- << "(" << dpy << ", " << surface << ", " << buffer << ")");
- DCHECK(g_driver_egl.debug_fn.eglReleaseTexImageFn != nullptr);
- EGLBoolean result =
- g_driver_egl.debug_fn.eglReleaseTexImageFn(dpy, surface, buffer);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglInitializeFn(EGLDisplay dpy,
+ EGLint* major,
+ EGLint* minor) {
+ return driver_->fn.eglInitializeFn(dpy, major, minor);
}
-static EGLBoolean GL_BINDING_CALL Debug_eglReleaseThread(void) {
- GL_SERVICE_LOG("eglReleaseThread"
- << "("
- << ")");
- DCHECK(g_driver_egl.debug_fn.eglReleaseThreadFn != nullptr);
- EGLBoolean result = g_driver_egl.debug_fn.eglReleaseThreadFn();
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglMakeCurrentFn(EGLDisplay dpy,
+ EGLSurface draw,
+ EGLSurface read,
+ EGLContext ctx) {
+ return driver_->fn.eglMakeCurrentFn(dpy, draw, read, ctx);
}
-static EGLBoolean GL_BINDING_CALL Debug_eglStreamAttribKHR(EGLDisplay dpy,
- EGLStreamKHR stream,
- EGLenum attribute,
- EGLint value) {
- GL_SERVICE_LOG("eglStreamAttribKHR"
- << "(" << dpy << ", " << stream << ", " << attribute << ", "
- << value << ")");
- DCHECK(g_driver_egl.debug_fn.eglStreamAttribKHRFn != nullptr);
- EGLBoolean result =
- g_driver_egl.debug_fn.eglStreamAttribKHRFn(dpy, stream, attribute, value);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglPostSubBufferNVFn(EGLDisplay dpy,
+ EGLSurface surface,
+ EGLint x,
+ EGLint y,
+ EGLint width,
+ EGLint height) {
+ return driver_->fn.eglPostSubBufferNVFn(dpy, surface, x, y, width, height);
}
-static EGLBoolean GL_BINDING_CALL
-Debug_eglStreamConsumerAcquireKHR(EGLDisplay dpy, EGLStreamKHR stream) {
- GL_SERVICE_LOG("eglStreamConsumerAcquireKHR"
- << "(" << dpy << ", " << stream << ")");
- DCHECK(g_driver_egl.debug_fn.eglStreamConsumerAcquireKHRFn != nullptr);
- EGLBoolean result =
- g_driver_egl.debug_fn.eglStreamConsumerAcquireKHRFn(dpy, stream);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLenum EGLApiBase::eglQueryAPIFn(void) {
+ return driver_->fn.eglQueryAPIFn();
}
-static EGLBoolean GL_BINDING_CALL
-Debug_eglStreamConsumerGLTextureExternalAttribsNV(EGLDisplay dpy,
- EGLStreamKHR stream,
- EGLAttrib* attrib_list) {
- GL_SERVICE_LOG("eglStreamConsumerGLTextureExternalAttribsNV"
- << "(" << dpy << ", " << stream << ", "
- << static_cast<const void*>(attrib_list) << ")");
- DCHECK(g_driver_egl.debug_fn.eglStreamConsumerGLTextureExternalAttribsNVFn !=
- nullptr);
- EGLBoolean result =
- g_driver_egl.debug_fn.eglStreamConsumerGLTextureExternalAttribsNVFn(
- dpy, stream, attrib_list);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglQueryContextFn(EGLDisplay dpy,
+ EGLContext ctx,
+ EGLint attribute,
+ EGLint* value) {
+ return driver_->fn.eglQueryContextFn(dpy, ctx, attribute, value);
}
-static EGLBoolean GL_BINDING_CALL
-Debug_eglStreamConsumerGLTextureExternalKHR(EGLDisplay dpy,
- EGLStreamKHR stream) {
- GL_SERVICE_LOG("eglStreamConsumerGLTextureExternalKHR"
- << "(" << dpy << ", " << stream << ")");
- DCHECK(g_driver_egl.debug_fn.eglStreamConsumerGLTextureExternalKHRFn !=
- nullptr);
- EGLBoolean result =
- g_driver_egl.debug_fn.eglStreamConsumerGLTextureExternalKHRFn(dpy,
- stream);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglQueryStreamKHRFn(EGLDisplay dpy,
+ EGLStreamKHR stream,
+ EGLenum attribute,
+ EGLint* value) {
+ return driver_->fn.eglQueryStreamKHRFn(dpy, stream, attribute, value);
}
-static EGLBoolean GL_BINDING_CALL
-Debug_eglStreamConsumerReleaseKHR(EGLDisplay dpy, EGLStreamKHR stream) {
- GL_SERVICE_LOG("eglStreamConsumerReleaseKHR"
- << "(" << dpy << ", " << stream << ")");
- DCHECK(g_driver_egl.debug_fn.eglStreamConsumerReleaseKHRFn != nullptr);
- EGLBoolean result =
- g_driver_egl.debug_fn.eglStreamConsumerReleaseKHRFn(dpy, stream);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglQueryStreamu64KHRFn(EGLDisplay dpy,
+ EGLStreamKHR stream,
+ EGLenum attribute,
+ EGLuint64KHR* value) {
+ return driver_->fn.eglQueryStreamu64KHRFn(dpy, stream, attribute, value);
}
-static EGLBoolean GL_BINDING_CALL
-Debug_eglStreamPostD3DTextureNV12ANGLE(EGLDisplay dpy,
- EGLStreamKHR stream,
- void* texture,
- const EGLAttrib* attrib_list) {
- GL_SERVICE_LOG("eglStreamPostD3DTextureNV12ANGLE"
- << "(" << dpy << ", " << stream << ", "
- << static_cast<const void*>(texture) << ", "
- << static_cast<const void*>(attrib_list) << ")");
- DCHECK(g_driver_egl.debug_fn.eglStreamPostD3DTextureNV12ANGLEFn != nullptr);
- EGLBoolean result = g_driver_egl.debug_fn.eglStreamPostD3DTextureNV12ANGLEFn(
- dpy, stream, texture, attrib_list);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+const char* EGLApiBase::eglQueryStringFn(EGLDisplay dpy, EGLint name) {
+ return driver_->fn.eglQueryStringFn(dpy, name);
}
-static EGLBoolean GL_BINDING_CALL Debug_eglSurfaceAttrib(EGLDisplay dpy,
- EGLSurface surface,
- EGLint attribute,
- EGLint value) {
- GL_SERVICE_LOG("eglSurfaceAttrib"
- << "(" << dpy << ", " << surface << ", " << attribute << ", "
- << value << ")");
- DCHECK(g_driver_egl.debug_fn.eglSurfaceAttribFn != nullptr);
- EGLBoolean result =
- g_driver_egl.debug_fn.eglSurfaceAttribFn(dpy, surface, attribute, value);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglQuerySurfaceFn(EGLDisplay dpy,
+ EGLSurface surface,
+ EGLint attribute,
+ EGLint* value) {
+ return driver_->fn.eglQuerySurfaceFn(dpy, surface, attribute, value);
}
-static EGLBoolean GL_BINDING_CALL Debug_eglSwapBuffers(EGLDisplay dpy,
- EGLSurface surface) {
- GL_SERVICE_LOG("eglSwapBuffers"
- << "(" << dpy << ", " << surface << ")");
- DCHECK(g_driver_egl.debug_fn.eglSwapBuffersFn != nullptr);
- EGLBoolean result = g_driver_egl.debug_fn.eglSwapBuffersFn(dpy, surface);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglQuerySurfacePointerANGLEFn(EGLDisplay dpy,
+ EGLSurface surface,
+ EGLint attribute,
+ void** value) {
+ return driver_->fn.eglQuerySurfacePointerANGLEFn(dpy, surface, attribute,
+ value);
}
-static EGLBoolean GL_BINDING_CALL
-Debug_eglSwapBuffersWithDamageKHR(EGLDisplay dpy,
- EGLSurface surface,
- EGLint* rects,
- EGLint n_rects) {
- GL_SERVICE_LOG("eglSwapBuffersWithDamageKHR"
- << "(" << dpy << ", " << surface << ", "
- << static_cast<const void*>(rects) << ", " << n_rects << ")");
- DCHECK(g_driver_egl.debug_fn.eglSwapBuffersWithDamageKHRFn != nullptr);
- EGLBoolean result = g_driver_egl.debug_fn.eglSwapBuffersWithDamageKHRFn(
- dpy, surface, rects, n_rects);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglReleaseTexImageFn(EGLDisplay dpy,
+ EGLSurface surface,
+ EGLint buffer) {
+ return driver_->fn.eglReleaseTexImageFn(dpy, surface, buffer);
}
-static EGLBoolean GL_BINDING_CALL Debug_eglSwapInterval(EGLDisplay dpy,
- EGLint interval) {
- GL_SERVICE_LOG("eglSwapInterval"
- << "(" << dpy << ", " << interval << ")");
- DCHECK(g_driver_egl.debug_fn.eglSwapIntervalFn != nullptr);
- EGLBoolean result = g_driver_egl.debug_fn.eglSwapIntervalFn(dpy, interval);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglReleaseThreadFn(void) {
+ return driver_->fn.eglReleaseThreadFn();
}
-static EGLBoolean GL_BINDING_CALL Debug_eglTerminate(EGLDisplay dpy) {
- GL_SERVICE_LOG("eglTerminate"
- << "(" << dpy << ")");
- DCHECK(g_driver_egl.debug_fn.eglTerminateFn != nullptr);
- EGLBoolean result = g_driver_egl.debug_fn.eglTerminateFn(dpy);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglStreamAttribKHRFn(EGLDisplay dpy,
+ EGLStreamKHR stream,
+ EGLenum attribute,
+ EGLint value) {
+ return driver_->fn.eglStreamAttribKHRFn(dpy, stream, attribute, value);
}
-static EGLBoolean GL_BINDING_CALL Debug_eglWaitClient(void) {
- GL_SERVICE_LOG("eglWaitClient"
- << "("
- << ")");
- DCHECK(g_driver_egl.debug_fn.eglWaitClientFn != nullptr);
- EGLBoolean result = g_driver_egl.debug_fn.eglWaitClientFn();
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglStreamConsumerAcquireKHRFn(EGLDisplay dpy,
+ EGLStreamKHR stream) {
+ return driver_->fn.eglStreamConsumerAcquireKHRFn(dpy, stream);
}
-static EGLBoolean GL_BINDING_CALL Debug_eglWaitGL(void) {
- GL_SERVICE_LOG("eglWaitGL"
- << "("
- << ")");
- DCHECK(g_driver_egl.debug_fn.eglWaitGLFn != nullptr);
- EGLBoolean result = g_driver_egl.debug_fn.eglWaitGLFn();
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglStreamConsumerGLTextureExternalAttribsNVFn(
+ EGLDisplay dpy,
+ EGLStreamKHR stream,
+ EGLAttrib* attrib_list) {
+ return driver_->fn.eglStreamConsumerGLTextureExternalAttribsNVFn(dpy, stream,
+ attrib_list);
}
-static EGLBoolean GL_BINDING_CALL Debug_eglWaitNative(EGLint engine) {
- GL_SERVICE_LOG("eglWaitNative"
- << "(" << engine << ")");
- DCHECK(g_driver_egl.debug_fn.eglWaitNativeFn != nullptr);
- EGLBoolean result = g_driver_egl.debug_fn.eglWaitNativeFn(engine);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglStreamConsumerGLTextureExternalKHRFn(
+ EGLDisplay dpy,
+ EGLStreamKHR stream) {
+ return driver_->fn.eglStreamConsumerGLTextureExternalKHRFn(dpy, stream);
}
-static EGLint GL_BINDING_CALL Debug_eglWaitSyncKHR(EGLDisplay dpy,
- EGLSyncKHR sync,
- EGLint flags) {
- GL_SERVICE_LOG("eglWaitSyncKHR"
- << "(" << dpy << ", " << sync << ", " << flags << ")");
- DCHECK(g_driver_egl.debug_fn.eglWaitSyncKHRFn != nullptr);
- EGLint result = g_driver_egl.debug_fn.eglWaitSyncKHRFn(dpy, sync, flags);
- GL_SERVICE_LOG("GL_RESULT: " << result);
- return result;
+EGLBoolean EGLApiBase::eglStreamConsumerReleaseKHRFn(EGLDisplay dpy,
+ EGLStreamKHR stream) {
+ return driver_->fn.eglStreamConsumerReleaseKHRFn(dpy, stream);
}
-} // extern "C"
-void DriverEGL::InitializeDebugBindings() {
- if (!debug_fn.eglBindAPIFn) {
- debug_fn.eglBindAPIFn = fn.eglBindAPIFn;
- fn.eglBindAPIFn = Debug_eglBindAPI;
- }
- if (!debug_fn.eglBindTexImageFn) {
- debug_fn.eglBindTexImageFn = fn.eglBindTexImageFn;
- fn.eglBindTexImageFn = Debug_eglBindTexImage;
- }
- if (!debug_fn.eglChooseConfigFn) {
- debug_fn.eglChooseConfigFn = fn.eglChooseConfigFn;
- fn.eglChooseConfigFn = Debug_eglChooseConfig;
- }
- if (!debug_fn.eglClientWaitSyncKHRFn) {
- debug_fn.eglClientWaitSyncKHRFn = fn.eglClientWaitSyncKHRFn;
- fn.eglClientWaitSyncKHRFn = Debug_eglClientWaitSyncKHR;
- }
- if (!debug_fn.eglCopyBuffersFn) {
- debug_fn.eglCopyBuffersFn = fn.eglCopyBuffersFn;
- fn.eglCopyBuffersFn = Debug_eglCopyBuffers;
- }
- if (!debug_fn.eglCreateContextFn) {
- debug_fn.eglCreateContextFn = fn.eglCreateContextFn;
- fn.eglCreateContextFn = Debug_eglCreateContext;
- }
- if (!debug_fn.eglCreateImageKHRFn) {
- debug_fn.eglCreateImageKHRFn = fn.eglCreateImageKHRFn;
- fn.eglCreateImageKHRFn = Debug_eglCreateImageKHR;
- }
- if (!debug_fn.eglCreatePbufferFromClientBufferFn) {
- debug_fn.eglCreatePbufferFromClientBufferFn =
- fn.eglCreatePbufferFromClientBufferFn;
- fn.eglCreatePbufferFromClientBufferFn =
- Debug_eglCreatePbufferFromClientBuffer;
- }
- if (!debug_fn.eglCreatePbufferSurfaceFn) {
- debug_fn.eglCreatePbufferSurfaceFn = fn.eglCreatePbufferSurfaceFn;
- fn.eglCreatePbufferSurfaceFn = Debug_eglCreatePbufferSurface;
- }
- if (!debug_fn.eglCreatePixmapSurfaceFn) {
- debug_fn.eglCreatePixmapSurfaceFn = fn.eglCreatePixmapSurfaceFn;
- fn.eglCreatePixmapSurfaceFn = Debug_eglCreatePixmapSurface;
- }
- if (!debug_fn.eglCreateStreamKHRFn) {
- debug_fn.eglCreateStreamKHRFn = fn.eglCreateStreamKHRFn;
- fn.eglCreateStreamKHRFn = Debug_eglCreateStreamKHR;
- }
- if (!debug_fn.eglCreateStreamProducerD3DTextureNV12ANGLEFn) {
- debug_fn.eglCreateStreamProducerD3DTextureNV12ANGLEFn =
- fn.eglCreateStreamProducerD3DTextureNV12ANGLEFn;
- fn.eglCreateStreamProducerD3DTextureNV12ANGLEFn =
- Debug_eglCreateStreamProducerD3DTextureNV12ANGLE;
- }
- if (!debug_fn.eglCreateSyncKHRFn) {
- debug_fn.eglCreateSyncKHRFn = fn.eglCreateSyncKHRFn;
- fn.eglCreateSyncKHRFn = Debug_eglCreateSyncKHR;
- }
- if (!debug_fn.eglCreateWindowSurfaceFn) {
- debug_fn.eglCreateWindowSurfaceFn = fn.eglCreateWindowSurfaceFn;
- fn.eglCreateWindowSurfaceFn = Debug_eglCreateWindowSurface;
- }
- if (!debug_fn.eglDestroyContextFn) {
- debug_fn.eglDestroyContextFn = fn.eglDestroyContextFn;
- fn.eglDestroyContextFn = Debug_eglDestroyContext;
- }
- if (!debug_fn.eglDestroyImageKHRFn) {
- debug_fn.eglDestroyImageKHRFn = fn.eglDestroyImageKHRFn;
- fn.eglDestroyImageKHRFn = Debug_eglDestroyImageKHR;
- }
- if (!debug_fn.eglDestroyStreamKHRFn) {
- debug_fn.eglDestroyStreamKHRFn = fn.eglDestroyStreamKHRFn;
- fn.eglDestroyStreamKHRFn = Debug_eglDestroyStreamKHR;
- }
- if (!debug_fn.eglDestroySurfaceFn) {
- debug_fn.eglDestroySurfaceFn = fn.eglDestroySurfaceFn;
- fn.eglDestroySurfaceFn = Debug_eglDestroySurface;
- }
- if (!debug_fn.eglDestroySyncKHRFn) {
- debug_fn.eglDestroySyncKHRFn = fn.eglDestroySyncKHRFn;
- fn.eglDestroySyncKHRFn = Debug_eglDestroySyncKHR;
- }
- if (!debug_fn.eglGetConfigAttribFn) {
- debug_fn.eglGetConfigAttribFn = fn.eglGetConfigAttribFn;
- fn.eglGetConfigAttribFn = Debug_eglGetConfigAttrib;
- }
- if (!debug_fn.eglGetConfigsFn) {
- debug_fn.eglGetConfigsFn = fn.eglGetConfigsFn;
- fn.eglGetConfigsFn = Debug_eglGetConfigs;
- }
- if (!debug_fn.eglGetCurrentContextFn) {
- debug_fn.eglGetCurrentContextFn = fn.eglGetCurrentContextFn;
- fn.eglGetCurrentContextFn = Debug_eglGetCurrentContext;
- }
- if (!debug_fn.eglGetCurrentDisplayFn) {
- debug_fn.eglGetCurrentDisplayFn = fn.eglGetCurrentDisplayFn;
- fn.eglGetCurrentDisplayFn = Debug_eglGetCurrentDisplay;
- }
- if (!debug_fn.eglGetCurrentSurfaceFn) {
- debug_fn.eglGetCurrentSurfaceFn = fn.eglGetCurrentSurfaceFn;
- fn.eglGetCurrentSurfaceFn = Debug_eglGetCurrentSurface;
- }
- if (!debug_fn.eglGetDisplayFn) {
- debug_fn.eglGetDisplayFn = fn.eglGetDisplayFn;
- fn.eglGetDisplayFn = Debug_eglGetDisplay;
- }
- if (!debug_fn.eglGetErrorFn) {
- debug_fn.eglGetErrorFn = fn.eglGetErrorFn;
- fn.eglGetErrorFn = Debug_eglGetError;
- }
- if (!debug_fn.eglGetPlatformDisplayEXTFn) {
- debug_fn.eglGetPlatformDisplayEXTFn = fn.eglGetPlatformDisplayEXTFn;
- fn.eglGetPlatformDisplayEXTFn = Debug_eglGetPlatformDisplayEXT;
- }
- if (!debug_fn.eglGetProcAddressFn) {
- debug_fn.eglGetProcAddressFn = fn.eglGetProcAddressFn;
- fn.eglGetProcAddressFn = Debug_eglGetProcAddress;
- }
- if (!debug_fn.eglGetSyncAttribKHRFn) {
- debug_fn.eglGetSyncAttribKHRFn = fn.eglGetSyncAttribKHRFn;
- fn.eglGetSyncAttribKHRFn = Debug_eglGetSyncAttribKHR;
- }
- if (!debug_fn.eglGetSyncValuesCHROMIUMFn) {
- debug_fn.eglGetSyncValuesCHROMIUMFn = fn.eglGetSyncValuesCHROMIUMFn;
- fn.eglGetSyncValuesCHROMIUMFn = Debug_eglGetSyncValuesCHROMIUM;
- }
- if (!debug_fn.eglImageFlushExternalEXTFn) {
- debug_fn.eglImageFlushExternalEXTFn = fn.eglImageFlushExternalEXTFn;
- fn.eglImageFlushExternalEXTFn = Debug_eglImageFlushExternalEXT;
- }
- if (!debug_fn.eglInitializeFn) {
- debug_fn.eglInitializeFn = fn.eglInitializeFn;
- fn.eglInitializeFn = Debug_eglInitialize;
- }
- if (!debug_fn.eglMakeCurrentFn) {
- debug_fn.eglMakeCurrentFn = fn.eglMakeCurrentFn;
- fn.eglMakeCurrentFn = Debug_eglMakeCurrent;
- }
- if (!debug_fn.eglPostSubBufferNVFn) {
- debug_fn.eglPostSubBufferNVFn = fn.eglPostSubBufferNVFn;
- fn.eglPostSubBufferNVFn = Debug_eglPostSubBufferNV;
- }
- if (!debug_fn.eglQueryAPIFn) {
- debug_fn.eglQueryAPIFn = fn.eglQueryAPIFn;
- fn.eglQueryAPIFn = Debug_eglQueryAPI;
- }
- if (!debug_fn.eglQueryContextFn) {
- debug_fn.eglQueryContextFn = fn.eglQueryContextFn;
- fn.eglQueryContextFn = Debug_eglQueryContext;
- }
- if (!debug_fn.eglQueryStreamKHRFn) {
- debug_fn.eglQueryStreamKHRFn = fn.eglQueryStreamKHRFn;
- fn.eglQueryStreamKHRFn = Debug_eglQueryStreamKHR;
- }
- if (!debug_fn.eglQueryStreamu64KHRFn) {
- debug_fn.eglQueryStreamu64KHRFn = fn.eglQueryStreamu64KHRFn;
- fn.eglQueryStreamu64KHRFn = Debug_eglQueryStreamu64KHR;
- }
- if (!debug_fn.eglQueryStringFn) {
- debug_fn.eglQueryStringFn = fn.eglQueryStringFn;
- fn.eglQueryStringFn = Debug_eglQueryString;
- }
- if (!debug_fn.eglQuerySurfaceFn) {
- debug_fn.eglQuerySurfaceFn = fn.eglQuerySurfaceFn;
- fn.eglQuerySurfaceFn = Debug_eglQuerySurface;
- }
- if (!debug_fn.eglQuerySurfacePointerANGLEFn) {
- debug_fn.eglQuerySurfacePointerANGLEFn = fn.eglQuerySurfacePointerANGLEFn;
- fn.eglQuerySurfacePointerANGLEFn = Debug_eglQuerySurfacePointerANGLE;
- }
- if (!debug_fn.eglReleaseTexImageFn) {
- debug_fn.eglReleaseTexImageFn = fn.eglReleaseTexImageFn;
- fn.eglReleaseTexImageFn = Debug_eglReleaseTexImage;
- }
- if (!debug_fn.eglReleaseThreadFn) {
- debug_fn.eglReleaseThreadFn = fn.eglReleaseThreadFn;
- fn.eglReleaseThreadFn = Debug_eglReleaseThread;
- }
- if (!debug_fn.eglStreamAttribKHRFn) {
- debug_fn.eglStreamAttribKHRFn = fn.eglStreamAttribKHRFn;
- fn.eglStreamAttribKHRFn = Debug_eglStreamAttribKHR;
- }
- if (!debug_fn.eglStreamConsumerAcquireKHRFn) {
- debug_fn.eglStreamConsumerAcquireKHRFn = fn.eglStreamConsumerAcquireKHRFn;
- fn.eglStreamConsumerAcquireKHRFn = Debug_eglStreamConsumerAcquireKHR;
- }
- if (!debug_fn.eglStreamConsumerGLTextureExternalAttribsNVFn) {
- debug_fn.eglStreamConsumerGLTextureExternalAttribsNVFn =
- fn.eglStreamConsumerGLTextureExternalAttribsNVFn;
- fn.eglStreamConsumerGLTextureExternalAttribsNVFn =
- Debug_eglStreamConsumerGLTextureExternalAttribsNV;
- }
- if (!debug_fn.eglStreamConsumerGLTextureExternalKHRFn) {
- debug_fn.eglStreamConsumerGLTextureExternalKHRFn =
- fn.eglStreamConsumerGLTextureExternalKHRFn;
- fn.eglStreamConsumerGLTextureExternalKHRFn =
- Debug_eglStreamConsumerGLTextureExternalKHR;
- }
- if (!debug_fn.eglStreamConsumerReleaseKHRFn) {
- debug_fn.eglStreamConsumerReleaseKHRFn = fn.eglStreamConsumerReleaseKHRFn;
- fn.eglStreamConsumerReleaseKHRFn = Debug_eglStreamConsumerReleaseKHR;
- }
- if (!debug_fn.eglStreamPostD3DTextureNV12ANGLEFn) {
- debug_fn.eglStreamPostD3DTextureNV12ANGLEFn =
- fn.eglStreamPostD3DTextureNV12ANGLEFn;
- fn.eglStreamPostD3DTextureNV12ANGLEFn =
- Debug_eglStreamPostD3DTextureNV12ANGLE;
- }
- if (!debug_fn.eglSurfaceAttribFn) {
- debug_fn.eglSurfaceAttribFn = fn.eglSurfaceAttribFn;
- fn.eglSurfaceAttribFn = Debug_eglSurfaceAttrib;
- }
- if (!debug_fn.eglSwapBuffersFn) {
- debug_fn.eglSwapBuffersFn = fn.eglSwapBuffersFn;
- fn.eglSwapBuffersFn = Debug_eglSwapBuffers;
- }
- if (!debug_fn.eglSwapBuffersWithDamageKHRFn) {
- debug_fn.eglSwapBuffersWithDamageKHRFn = fn.eglSwapBuffersWithDamageKHRFn;
- fn.eglSwapBuffersWithDamageKHRFn = Debug_eglSwapBuffersWithDamageKHR;
- }
- if (!debug_fn.eglSwapIntervalFn) {
- debug_fn.eglSwapIntervalFn = fn.eglSwapIntervalFn;
- fn.eglSwapIntervalFn = Debug_eglSwapInterval;
- }
- if (!debug_fn.eglTerminateFn) {
- debug_fn.eglTerminateFn = fn.eglTerminateFn;
- fn.eglTerminateFn = Debug_eglTerminate;
- }
- if (!debug_fn.eglWaitClientFn) {
- debug_fn.eglWaitClientFn = fn.eglWaitClientFn;
- fn.eglWaitClientFn = Debug_eglWaitClient;
- }
- if (!debug_fn.eglWaitGLFn) {
- debug_fn.eglWaitGLFn = fn.eglWaitGLFn;
- fn.eglWaitGLFn = Debug_eglWaitGL;
- }
- if (!debug_fn.eglWaitNativeFn) {
- debug_fn.eglWaitNativeFn = fn.eglWaitNativeFn;
- fn.eglWaitNativeFn = Debug_eglWaitNative;
- }
- if (!debug_fn.eglWaitSyncKHRFn) {
- debug_fn.eglWaitSyncKHRFn = fn.eglWaitSyncKHRFn;
- fn.eglWaitSyncKHRFn = Debug_eglWaitSyncKHR;
- }
- g_debugBindingsInitialized = true;
+EGLBoolean EGLApiBase::eglStreamPostD3DTextureNV12ANGLEFn(
+ EGLDisplay dpy,
+ EGLStreamKHR stream,
+ void* texture,
+ const EGLAttrib* attrib_list) {
+ return driver_->fn.eglStreamPostD3DTextureNV12ANGLEFn(dpy, stream, texture,
+ attrib_list);
}
-void DriverEGL::ClearBindings() {
- memset(this, 0, sizeof(*this));
+EGLBoolean EGLApiBase::eglSurfaceAttribFn(EGLDisplay dpy,
+ EGLSurface surface,
+ EGLint attribute,
+ EGLint value) {
+ return driver_->fn.eglSurfaceAttribFn(dpy, surface, attribute, value);
}
-EGLBoolean EGLApiBase::eglBindAPIFn(EGLenum api) {
- return driver_->fn.eglBindAPIFn(api);
+EGLBoolean EGLApiBase::eglSwapBuffersFn(EGLDisplay dpy, EGLSurface surface) {
+ return driver_->fn.eglSwapBuffersFn(dpy, surface);
}
-EGLBoolean EGLApiBase::eglBindTexImageFn(EGLDisplay dpy,
- EGLSurface surface,
- EGLint buffer) {
- return driver_->fn.eglBindTexImageFn(dpy, surface, buffer);
+EGLBoolean EGLApiBase::eglSwapBuffersWithDamageKHRFn(EGLDisplay dpy,
+ EGLSurface surface,
+ EGLint* rects,
+ EGLint n_rects) {
+ return driver_->fn.eglSwapBuffersWithDamageKHRFn(dpy, surface, rects,
+ n_rects);
}
-EGLBoolean EGLApiBase::eglChooseConfigFn(EGLDisplay dpy,
- const EGLint* attrib_list,
- EGLConfig* configs,
- EGLint config_size,
- EGLint* num_config) {
- return driver_->fn.eglChooseConfigFn(dpy, attrib_list, configs, config_size,
- num_config);
+EGLBoolean EGLApiBase::eglSwapIntervalFn(EGLDisplay dpy, EGLint interval) {
+ return driver_->fn.eglSwapIntervalFn(dpy, interval);
}
-EGLint EGLApiBase::eglClientWaitSyncKHRFn(EGLDisplay dpy,
- EGLSyncKHR sync,
- EGLint flags,
- EGLTimeKHR timeout) {
- return driver_->fn.eglClientWaitSyncKHRFn(dpy, sync, flags, timeout);
+EGLBoolean EGLApiBase::eglTerminateFn(EGLDisplay dpy) {
+ return driver_->fn.eglTerminateFn(dpy);
}
-EGLBoolean EGLApiBase::eglCopyBuffersFn(EGLDisplay dpy,
- EGLSurface surface,
- EGLNativePixmapType target) {
- return driver_->fn.eglCopyBuffersFn(dpy, surface, target);
+EGLBoolean EGLApiBase::eglWaitClientFn(void) {
+ return driver_->fn.eglWaitClientFn();
}
-EGLContext EGLApiBase::eglCreateContextFn(EGLDisplay dpy,
- EGLConfig config,
- EGLContext share_context,
- const EGLint* attrib_list) {
- return driver_->fn.eglCreateContextFn(dpy, config, share_context,
- attrib_list);
+EGLBoolean EGLApiBase::eglWaitGLFn(void) {
+ return driver_->fn.eglWaitGLFn();
}
-EGLImageKHR EGLApiBase::eglCreateImageKHRFn(EGLDisplay dpy,
- EGLContext ctx,
- EGLenum target,
- EGLClientBuffer buffer,
- const EGLint* attrib_list) {
- return driver_->fn.eglCreateImageKHRFn(dpy, ctx, target, buffer, attrib_list);
+EGLBoolean EGLApiBase::eglWaitNativeFn(EGLint engine) {
+ return driver_->fn.eglWaitNativeFn(engine);
}
-EGLSurface EGLApiBase::eglCreatePbufferFromClientBufferFn(
+EGLint EGLApiBase::eglWaitSyncKHRFn(EGLDisplay dpy,
+ EGLSyncKHR sync,
+ EGLint flags) {
+ return driver_->fn.eglWaitSyncKHRFn(dpy, sync, flags);
+}
+
+EGLBoolean TraceEGLApi::eglBindAPIFn(EGLenum api) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglBindAPI")
+ return egl_api_->eglBindAPIFn(api);
+}
+
+EGLBoolean TraceEGLApi::eglBindTexImageFn(EGLDisplay dpy,
+ EGLSurface surface,
+ EGLint buffer) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglBindTexImage")
+ return egl_api_->eglBindTexImageFn(dpy, surface, buffer);
+}
+
+EGLBoolean TraceEGLApi::eglChooseConfigFn(EGLDisplay dpy,
+ const EGLint* attrib_list,
+ EGLConfig* configs,
+ EGLint config_size,
+ EGLint* num_config) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglChooseConfig")
+ return egl_api_->eglChooseConfigFn(dpy, attrib_list, configs, config_size,
+ num_config);
+}
+
+EGLint TraceEGLApi::eglClientWaitSyncKHRFn(EGLDisplay dpy,
+ EGLSyncKHR sync,
+ EGLint flags,
+ EGLTimeKHR timeout) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglClientWaitSyncKHR")
+ return egl_api_->eglClientWaitSyncKHRFn(dpy, sync, flags, timeout);
+}
+
+EGLBoolean TraceEGLApi::eglCopyBuffersFn(EGLDisplay dpy,
+ EGLSurface surface,
+ EGLNativePixmapType target) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglCopyBuffers")
+ return egl_api_->eglCopyBuffersFn(dpy, surface, target);
+}
+
+EGLContext TraceEGLApi::eglCreateContextFn(EGLDisplay dpy,
+ EGLConfig config,
+ EGLContext share_context,
+ const EGLint* attrib_list) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglCreateContext")
+ return egl_api_->eglCreateContextFn(dpy, config, share_context, attrib_list);
+}
+
+EGLImageKHR TraceEGLApi::eglCreateImageKHRFn(EGLDisplay dpy,
+ EGLContext ctx,
+ EGLenum target,
+ EGLClientBuffer buffer,
+ const EGLint* attrib_list) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglCreateImageKHR")
+ return egl_api_->eglCreateImageKHRFn(dpy, ctx, target, buffer, attrib_list);
+}
+
+EGLSurface TraceEGLApi::eglCreatePbufferFromClientBufferFn(
EGLDisplay dpy,
EGLenum buftype,
void* buffer,
EGLConfig config,
const EGLint* attrib_list) {
- return driver_->fn.eglCreatePbufferFromClientBufferFn(dpy, buftype, buffer,
- config, attrib_list);
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu",
+ "TraceGLAPI::eglCreatePbufferFromClientBuffer")
+ return egl_api_->eglCreatePbufferFromClientBufferFn(dpy, buftype, buffer,
+ config, attrib_list);
}
-EGLSurface EGLApiBase::eglCreatePbufferSurfaceFn(EGLDisplay dpy,
- EGLConfig config,
- const EGLint* attrib_list) {
- return driver_->fn.eglCreatePbufferSurfaceFn(dpy, config, attrib_list);
+EGLSurface TraceEGLApi::eglCreatePbufferSurfaceFn(EGLDisplay dpy,
+ EGLConfig config,
+ const EGLint* attrib_list) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglCreatePbufferSurface")
+ return egl_api_->eglCreatePbufferSurfaceFn(dpy, config, attrib_list);
}
-EGLSurface EGLApiBase::eglCreatePixmapSurfaceFn(EGLDisplay dpy,
- EGLConfig config,
- EGLNativePixmapType pixmap,
- const EGLint* attrib_list) {
- return driver_->fn.eglCreatePixmapSurfaceFn(dpy, config, pixmap, attrib_list);
+EGLSurface TraceEGLApi::eglCreatePixmapSurfaceFn(EGLDisplay dpy,
+ EGLConfig config,
+ EGLNativePixmapType pixmap,
+ const EGLint* attrib_list) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglCreatePixmapSurface")
+ return egl_api_->eglCreatePixmapSurfaceFn(dpy, config, pixmap, attrib_list);
}
-EGLStreamKHR EGLApiBase::eglCreateStreamKHRFn(EGLDisplay dpy,
- const EGLint* attrib_list) {
- return driver_->fn.eglCreateStreamKHRFn(dpy, attrib_list);
+EGLStreamKHR TraceEGLApi::eglCreateStreamKHRFn(EGLDisplay dpy,
+ const EGLint* attrib_list) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglCreateStreamKHR")
+ return egl_api_->eglCreateStreamKHRFn(dpy, attrib_list);
}
-EGLBoolean EGLApiBase::eglCreateStreamProducerD3DTextureNV12ANGLEFn(
+EGLBoolean TraceEGLApi::eglCreateStreamProducerD3DTextureNV12ANGLEFn(
EGLDisplay dpy,
EGLStreamKHR stream,
EGLAttrib* attrib_list) {
- return driver_->fn.eglCreateStreamProducerD3DTextureNV12ANGLEFn(dpy, stream,
- attrib_list);
+ TRACE_EVENT_BINARY_EFFICIENT0(
+ "gpu", "TraceGLAPI::eglCreateStreamProducerD3DTextureNV12ANGLE")
+ return egl_api_->eglCreateStreamProducerD3DTextureNV12ANGLEFn(dpy, stream,
+ attrib_list);
}
-EGLSyncKHR EGLApiBase::eglCreateSyncKHRFn(EGLDisplay dpy,
- EGLenum type,
- const EGLint* attrib_list) {
- return driver_->fn.eglCreateSyncKHRFn(dpy, type, attrib_list);
+EGLSyncKHR TraceEGLApi::eglCreateSyncKHRFn(EGLDisplay dpy,
+ EGLenum type,
+ const EGLint* attrib_list) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglCreateSyncKHR")
+ return egl_api_->eglCreateSyncKHRFn(dpy, type, attrib_list);
}
-EGLSurface EGLApiBase::eglCreateWindowSurfaceFn(EGLDisplay dpy,
- EGLConfig config,
- EGLNativeWindowType win,
- const EGLint* attrib_list) {
- return driver_->fn.eglCreateWindowSurfaceFn(dpy, config, win, attrib_list);
+EGLSurface TraceEGLApi::eglCreateWindowSurfaceFn(EGLDisplay dpy,
+ EGLConfig config,
+ EGLNativeWindowType win,
+ const EGLint* attrib_list) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglCreateWindowSurface")
+ return egl_api_->eglCreateWindowSurfaceFn(dpy, config, win, attrib_list);
}
-EGLBoolean EGLApiBase::eglDestroyContextFn(EGLDisplay dpy, EGLContext ctx) {
- return driver_->fn.eglDestroyContextFn(dpy, ctx);
+EGLBoolean TraceEGLApi::eglDestroyContextFn(EGLDisplay dpy, EGLContext ctx) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglDestroyContext")
+ return egl_api_->eglDestroyContextFn(dpy, ctx);
}
-EGLBoolean EGLApiBase::eglDestroyImageKHRFn(EGLDisplay dpy, EGLImageKHR image) {
- return driver_->fn.eglDestroyImageKHRFn(dpy, image);
+EGLBoolean TraceEGLApi::eglDestroyImageKHRFn(EGLDisplay dpy,
+ EGLImageKHR image) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglDestroyImageKHR")
+ return egl_api_->eglDestroyImageKHRFn(dpy, image);
}
-EGLBoolean EGLApiBase::eglDestroyStreamKHRFn(EGLDisplay dpy,
- EGLStreamKHR stream) {
- return driver_->fn.eglDestroyStreamKHRFn(dpy, stream);
+EGLBoolean TraceEGLApi::eglDestroyStreamKHRFn(EGLDisplay dpy,
+ EGLStreamKHR stream) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglDestroyStreamKHR")
+ return egl_api_->eglDestroyStreamKHRFn(dpy, stream);
}
-EGLBoolean EGLApiBase::eglDestroySurfaceFn(EGLDisplay dpy, EGLSurface surface) {
- return driver_->fn.eglDestroySurfaceFn(dpy, surface);
+EGLBoolean TraceEGLApi::eglDestroySurfaceFn(EGLDisplay dpy,
+ EGLSurface surface) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglDestroySurface")
+ return egl_api_->eglDestroySurfaceFn(dpy, surface);
}
-EGLBoolean EGLApiBase::eglDestroySyncKHRFn(EGLDisplay dpy, EGLSyncKHR sync) {
- return driver_->fn.eglDestroySyncKHRFn(dpy, sync);
+EGLBoolean TraceEGLApi::eglDestroySyncKHRFn(EGLDisplay dpy, EGLSyncKHR sync) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglDestroySyncKHR")
+ return egl_api_->eglDestroySyncKHRFn(dpy, sync);
}
-EGLBoolean EGLApiBase::eglGetConfigAttribFn(EGLDisplay dpy,
- EGLConfig config,
- EGLint attribute,
- EGLint* value) {
- return driver_->fn.eglGetConfigAttribFn(dpy, config, attribute, value);
+EGLBoolean TraceEGLApi::eglGetConfigAttribFn(EGLDisplay dpy,
+ EGLConfig config,
+ EGLint attribute,
+ EGLint* value) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglGetConfigAttrib")
+ return egl_api_->eglGetConfigAttribFn(dpy, config, attribute, value);
}
-EGLBoolean EGLApiBase::eglGetConfigsFn(EGLDisplay dpy,
- EGLConfig* configs,
- EGLint config_size,
- EGLint* num_config) {
- return driver_->fn.eglGetConfigsFn(dpy, configs, config_size, num_config);
+EGLBoolean TraceEGLApi::eglGetConfigsFn(EGLDisplay dpy,
+ EGLConfig* configs,
+ EGLint config_size,
+ EGLint* num_config) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglGetConfigs")
+ return egl_api_->eglGetConfigsFn(dpy, configs, config_size, num_config);
}
-EGLContext EGLApiBase::eglGetCurrentContextFn(void) {
- return driver_->fn.eglGetCurrentContextFn();
+EGLContext TraceEGLApi::eglGetCurrentContextFn(void) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglGetCurrentContext")
+ return egl_api_->eglGetCurrentContextFn();
}
-EGLDisplay EGLApiBase::eglGetCurrentDisplayFn(void) {
- return driver_->fn.eglGetCurrentDisplayFn();
+EGLDisplay TraceEGLApi::eglGetCurrentDisplayFn(void) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglGetCurrentDisplay")
+ return egl_api_->eglGetCurrentDisplayFn();
}
-EGLSurface EGLApiBase::eglGetCurrentSurfaceFn(EGLint readdraw) {
- return driver_->fn.eglGetCurrentSurfaceFn(readdraw);
+EGLSurface TraceEGLApi::eglGetCurrentSurfaceFn(EGLint readdraw) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglGetCurrentSurface")
+ return egl_api_->eglGetCurrentSurfaceFn(readdraw);
}
-EGLDisplay EGLApiBase::eglGetDisplayFn(EGLNativeDisplayType display_id) {
- return driver_->fn.eglGetDisplayFn(display_id);
+EGLDisplay TraceEGLApi::eglGetDisplayFn(EGLNativeDisplayType display_id) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglGetDisplay")
+ return egl_api_->eglGetDisplayFn(display_id);
}
-EGLint EGLApiBase::eglGetErrorFn(void) {
- return driver_->fn.eglGetErrorFn();
+EGLint TraceEGLApi::eglGetErrorFn(void) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglGetError")
+ return egl_api_->eglGetErrorFn();
}
-EGLDisplay EGLApiBase::eglGetPlatformDisplayEXTFn(EGLenum platform,
- void* native_display,
- const EGLint* attrib_list) {
- return driver_->fn.eglGetPlatformDisplayEXTFn(platform, native_display,
- attrib_list);
+EGLDisplay TraceEGLApi::eglGetPlatformDisplayEXTFn(EGLenum platform,
+ void* native_display,
+ const EGLint* attrib_list) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglGetPlatformDisplayEXT")
+ return egl_api_->eglGetPlatformDisplayEXTFn(platform, native_display,
+ attrib_list);
}
-__eglMustCastToProperFunctionPointerType EGLApiBase::eglGetProcAddressFn(
+__eglMustCastToProperFunctionPointerType TraceEGLApi::eglGetProcAddressFn(
const char* procname) {
- return driver_->fn.eglGetProcAddressFn(procname);
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglGetProcAddress")
+ return egl_api_->eglGetProcAddressFn(procname);
}
-EGLBoolean EGLApiBase::eglGetSyncAttribKHRFn(EGLDisplay dpy,
- EGLSyncKHR sync,
- EGLint attribute,
- EGLint* value) {
- return driver_->fn.eglGetSyncAttribKHRFn(dpy, sync, attribute, value);
+EGLBoolean TraceEGLApi::eglGetSyncAttribKHRFn(EGLDisplay dpy,
+ EGLSyncKHR sync,
+ EGLint attribute,
+ EGLint* value) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglGetSyncAttribKHR")
+ return egl_api_->eglGetSyncAttribKHRFn(dpy, sync, attribute, value);
}
-EGLBoolean EGLApiBase::eglGetSyncValuesCHROMIUMFn(EGLDisplay dpy,
- EGLSurface surface,
- EGLuint64CHROMIUM* ust,
- EGLuint64CHROMIUM* msc,
- EGLuint64CHROMIUM* sbc) {
- return driver_->fn.eglGetSyncValuesCHROMIUMFn(dpy, surface, ust, msc, sbc);
+EGLBoolean TraceEGLApi::eglGetSyncValuesCHROMIUMFn(EGLDisplay dpy,
+ EGLSurface surface,
+ EGLuint64CHROMIUM* ust,
+ EGLuint64CHROMIUM* msc,
+ EGLuint64CHROMIUM* sbc) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglGetSyncValuesCHROMIUM")
+ return egl_api_->eglGetSyncValuesCHROMIUMFn(dpy, surface, ust, msc, sbc);
}
-EGLBoolean EGLApiBase::eglImageFlushExternalEXTFn(
+EGLBoolean TraceEGLApi::eglImageFlushExternalEXTFn(
EGLDisplay dpy,
EGLImageKHR image,
const EGLAttrib* attrib_list) {
- return driver_->fn.eglImageFlushExternalEXTFn(dpy, image, attrib_list);
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglImageFlushExternalEXT")
+ return egl_api_->eglImageFlushExternalEXTFn(dpy, image, attrib_list);
}
-EGLBoolean EGLApiBase::eglInitializeFn(EGLDisplay dpy,
- EGLint* major,
- EGLint* minor) {
- return driver_->fn.eglInitializeFn(dpy, major, minor);
+EGLBoolean TraceEGLApi::eglInitializeFn(EGLDisplay dpy,
+ EGLint* major,
+ EGLint* minor) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglInitialize")
+ return egl_api_->eglInitializeFn(dpy, major, minor);
}
-EGLBoolean EGLApiBase::eglMakeCurrentFn(EGLDisplay dpy,
- EGLSurface draw,
- EGLSurface read,
- EGLContext ctx) {
- return driver_->fn.eglMakeCurrentFn(dpy, draw, read, ctx);
+EGLBoolean TraceEGLApi::eglMakeCurrentFn(EGLDisplay dpy,
+ EGLSurface draw,
+ EGLSurface read,
+ EGLContext ctx) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglMakeCurrent")
+ return egl_api_->eglMakeCurrentFn(dpy, draw, read, ctx);
}
-EGLBoolean EGLApiBase::eglPostSubBufferNVFn(EGLDisplay dpy,
- EGLSurface surface,
- EGLint x,
- EGLint y,
- EGLint width,
- EGLint height) {
- return driver_->fn.eglPostSubBufferNVFn(dpy, surface, x, y, width, height);
+EGLBoolean TraceEGLApi::eglPostSubBufferNVFn(EGLDisplay dpy,
+ EGLSurface surface,
+ EGLint x,
+ EGLint y,
+ EGLint width,
+ EGLint height) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglPostSubBufferNV")
+ return egl_api_->eglPostSubBufferNVFn(dpy, surface, x, y, width, height);
}
-EGLenum EGLApiBase::eglQueryAPIFn(void) {
- return driver_->fn.eglQueryAPIFn();
+EGLenum TraceEGLApi::eglQueryAPIFn(void) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglQueryAPI")
+ return egl_api_->eglQueryAPIFn();
}
-EGLBoolean EGLApiBase::eglQueryContextFn(EGLDisplay dpy,
- EGLContext ctx,
- EGLint attribute,
- EGLint* value) {
- return driver_->fn.eglQueryContextFn(dpy, ctx, attribute, value);
+EGLBoolean TraceEGLApi::eglQueryContextFn(EGLDisplay dpy,
+ EGLContext ctx,
+ EGLint attribute,
+ EGLint* value) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglQueryContext")
+ return egl_api_->eglQueryContextFn(dpy, ctx, attribute, value);
}
-EGLBoolean EGLApiBase::eglQueryStreamKHRFn(EGLDisplay dpy,
- EGLStreamKHR stream,
- EGLenum attribute,
- EGLint* value) {
- return driver_->fn.eglQueryStreamKHRFn(dpy, stream, attribute, value);
+EGLBoolean TraceEGLApi::eglQueryStreamKHRFn(EGLDisplay dpy,
+ EGLStreamKHR stream,
+ EGLenum attribute,
+ EGLint* value) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglQueryStreamKHR")
+ return egl_api_->eglQueryStreamKHRFn(dpy, stream, attribute, value);
}
-EGLBoolean EGLApiBase::eglQueryStreamu64KHRFn(EGLDisplay dpy,
- EGLStreamKHR stream,
- EGLenum attribute,
- EGLuint64KHR* value) {
- return driver_->fn.eglQueryStreamu64KHRFn(dpy, stream, attribute, value);
+EGLBoolean TraceEGLApi::eglQueryStreamu64KHRFn(EGLDisplay dpy,
+ EGLStreamKHR stream,
+ EGLenum attribute,
+ EGLuint64KHR* value) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglQueryStreamu64KHR")
+ return egl_api_->eglQueryStreamu64KHRFn(dpy, stream, attribute, value);
}
-const char* EGLApiBase::eglQueryStringFn(EGLDisplay dpy, EGLint name) {
- return driver_->fn.eglQueryStringFn(dpy, name);
+const char* TraceEGLApi::eglQueryStringFn(EGLDisplay dpy, EGLint name) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglQueryString")
+ return egl_api_->eglQueryStringFn(dpy, name);
}
-EGLBoolean EGLApiBase::eglQuerySurfaceFn(EGLDisplay dpy,
- EGLSurface surface,
- EGLint attribute,
- EGLint* value) {
- return driver_->fn.eglQuerySurfaceFn(dpy, surface, attribute, value);
+EGLBoolean TraceEGLApi::eglQuerySurfaceFn(EGLDisplay dpy,
+ EGLSurface surface,
+ EGLint attribute,
+ EGLint* value) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglQuerySurface")
+ return egl_api_->eglQuerySurfaceFn(dpy, surface, attribute, value);
}
-EGLBoolean EGLApiBase::eglQuerySurfacePointerANGLEFn(EGLDisplay dpy,
- EGLSurface surface,
- EGLint attribute,
- void** value) {
- return driver_->fn.eglQuerySurfacePointerANGLEFn(dpy, surface, attribute,
- value);
+EGLBoolean TraceEGLApi::eglQuerySurfacePointerANGLEFn(EGLDisplay dpy,
+ EGLSurface surface,
+ EGLint attribute,
+ void** value) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu",
+ "TraceGLAPI::eglQuerySurfacePointerANGLE")
+ return egl_api_->eglQuerySurfacePointerANGLEFn(dpy, surface, attribute,
+ value);
}
-EGLBoolean EGLApiBase::eglReleaseTexImageFn(EGLDisplay dpy,
- EGLSurface surface,
- EGLint buffer) {
- return driver_->fn.eglReleaseTexImageFn(dpy, surface, buffer);
+EGLBoolean TraceEGLApi::eglReleaseTexImageFn(EGLDisplay dpy,
+ EGLSurface surface,
+ EGLint buffer) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglReleaseTexImage")
+ return egl_api_->eglReleaseTexImageFn(dpy, surface, buffer);
}
-EGLBoolean EGLApiBase::eglReleaseThreadFn(void) {
- return driver_->fn.eglReleaseThreadFn();
+EGLBoolean TraceEGLApi::eglReleaseThreadFn(void) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglReleaseThread")
+ return egl_api_->eglReleaseThreadFn();
}
-EGLBoolean EGLApiBase::eglStreamAttribKHRFn(EGLDisplay dpy,
- EGLStreamKHR stream,
- EGLenum attribute,
- EGLint value) {
- return driver_->fn.eglStreamAttribKHRFn(dpy, stream, attribute, value);
+EGLBoolean TraceEGLApi::eglStreamAttribKHRFn(EGLDisplay dpy,
+ EGLStreamKHR stream,
+ EGLenum attribute,
+ EGLint value) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglStreamAttribKHR")
+ return egl_api_->eglStreamAttribKHRFn(dpy, stream, attribute, value);
}
-EGLBoolean EGLApiBase::eglStreamConsumerAcquireKHRFn(EGLDisplay dpy,
- EGLStreamKHR stream) {
- return driver_->fn.eglStreamConsumerAcquireKHRFn(dpy, stream);
+EGLBoolean TraceEGLApi::eglStreamConsumerAcquireKHRFn(EGLDisplay dpy,
+ EGLStreamKHR stream) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu",
+ "TraceGLAPI::eglStreamConsumerAcquireKHR")
+ return egl_api_->eglStreamConsumerAcquireKHRFn(dpy, stream);
}
-EGLBoolean EGLApiBase::eglStreamConsumerGLTextureExternalAttribsNVFn(
+EGLBoolean TraceEGLApi::eglStreamConsumerGLTextureExternalAttribsNVFn(
EGLDisplay dpy,
EGLStreamKHR stream,
EGLAttrib* attrib_list) {
- return driver_->fn.eglStreamConsumerGLTextureExternalAttribsNVFn(dpy, stream,
- attrib_list);
+ TRACE_EVENT_BINARY_EFFICIENT0(
+ "gpu", "TraceGLAPI::eglStreamConsumerGLTextureExternalAttribsNV")
+ return egl_api_->eglStreamConsumerGLTextureExternalAttribsNVFn(dpy, stream,
+ attrib_list);
}
-EGLBoolean EGLApiBase::eglStreamConsumerGLTextureExternalKHRFn(
+EGLBoolean TraceEGLApi::eglStreamConsumerGLTextureExternalKHRFn(
EGLDisplay dpy,
EGLStreamKHR stream) {
- return driver_->fn.eglStreamConsumerGLTextureExternalKHRFn(dpy, stream);
+ TRACE_EVENT_BINARY_EFFICIENT0(
+ "gpu", "TraceGLAPI::eglStreamConsumerGLTextureExternalKHR")
+ return egl_api_->eglStreamConsumerGLTextureExternalKHRFn(dpy, stream);
}
-EGLBoolean EGLApiBase::eglStreamConsumerReleaseKHRFn(EGLDisplay dpy,
- EGLStreamKHR stream) {
- return driver_->fn.eglStreamConsumerReleaseKHRFn(dpy, stream);
+EGLBoolean TraceEGLApi::eglStreamConsumerReleaseKHRFn(EGLDisplay dpy,
+ EGLStreamKHR stream) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu",
+ "TraceGLAPI::eglStreamConsumerReleaseKHR")
+ return egl_api_->eglStreamConsumerReleaseKHRFn(dpy, stream);
}
-EGLBoolean EGLApiBase::eglStreamPostD3DTextureNV12ANGLEFn(
+EGLBoolean TraceEGLApi::eglStreamPostD3DTextureNV12ANGLEFn(
EGLDisplay dpy,
EGLStreamKHR stream,
void* texture,
const EGLAttrib* attrib_list) {
- return driver_->fn.eglStreamPostD3DTextureNV12ANGLEFn(dpy, stream, texture,
- attrib_list);
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu",
+ "TraceGLAPI::eglStreamPostD3DTextureNV12ANGLE")
+ return egl_api_->eglStreamPostD3DTextureNV12ANGLEFn(dpy, stream, texture,
+ attrib_list);
}
-EGLBoolean EGLApiBase::eglSurfaceAttribFn(EGLDisplay dpy,
- EGLSurface surface,
- EGLint attribute,
- EGLint value) {
- return driver_->fn.eglSurfaceAttribFn(dpy, surface, attribute, value);
+EGLBoolean TraceEGLApi::eglSurfaceAttribFn(EGLDisplay dpy,
+ EGLSurface surface,
+ EGLint attribute,
+ EGLint value) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglSurfaceAttrib")
+ return egl_api_->eglSurfaceAttribFn(dpy, surface, attribute, value);
}
-EGLBoolean EGLApiBase::eglSwapBuffersFn(EGLDisplay dpy, EGLSurface surface) {
- return driver_->fn.eglSwapBuffersFn(dpy, surface);
+EGLBoolean TraceEGLApi::eglSwapBuffersFn(EGLDisplay dpy, EGLSurface surface) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglSwapBuffers")
+ return egl_api_->eglSwapBuffersFn(dpy, surface);
}
-EGLBoolean EGLApiBase::eglSwapBuffersWithDamageKHRFn(EGLDisplay dpy,
- EGLSurface surface,
- EGLint* rects,
- EGLint n_rects) {
- return driver_->fn.eglSwapBuffersWithDamageKHRFn(dpy, surface, rects,
- n_rects);
+EGLBoolean TraceEGLApi::eglSwapBuffersWithDamageKHRFn(EGLDisplay dpy,
+ EGLSurface surface,
+ EGLint* rects,
+ EGLint n_rects) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu",
+ "TraceGLAPI::eglSwapBuffersWithDamageKHR")
+ return egl_api_->eglSwapBuffersWithDamageKHRFn(dpy, surface, rects, n_rects);
}
-EGLBoolean EGLApiBase::eglSwapIntervalFn(EGLDisplay dpy, EGLint interval) {
- return driver_->fn.eglSwapIntervalFn(dpy, interval);
+EGLBoolean TraceEGLApi::eglSwapIntervalFn(EGLDisplay dpy, EGLint interval) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglSwapInterval")
+ return egl_api_->eglSwapIntervalFn(dpy, interval);
}
-EGLBoolean EGLApiBase::eglTerminateFn(EGLDisplay dpy) {
- return driver_->fn.eglTerminateFn(dpy);
+EGLBoolean TraceEGLApi::eglTerminateFn(EGLDisplay dpy) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglTerminate")
+ return egl_api_->eglTerminateFn(dpy);
}
-
-EGLBoolean EGLApiBase::eglWaitClientFn(void) {
- return driver_->fn.eglWaitClientFn();
+
+EGLBoolean TraceEGLApi::eglWaitClientFn(void) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglWaitClient")
+ return egl_api_->eglWaitClientFn();
}
-EGLBoolean EGLApiBase::eglWaitGLFn(void) {
- return driver_->fn.eglWaitGLFn();
+EGLBoolean TraceEGLApi::eglWaitGLFn(void) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglWaitGL")
+ return egl_api_->eglWaitGLFn();
}
-EGLBoolean EGLApiBase::eglWaitNativeFn(EGLint engine) {
- return driver_->fn.eglWaitNativeFn(engine);
+EGLBoolean TraceEGLApi::eglWaitNativeFn(EGLint engine) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglWaitNative")
+ return egl_api_->eglWaitNativeFn(engine);
}
-EGLint EGLApiBase::eglWaitSyncKHRFn(EGLDisplay dpy,
- EGLSyncKHR sync,
- EGLint flags) {
- return driver_->fn.eglWaitSyncKHRFn(dpy, sync, flags);
+EGLint TraceEGLApi::eglWaitSyncKHRFn(EGLDisplay dpy,
+ EGLSyncKHR sync,
+ EGLint flags) {
+ TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglWaitSyncKHR")
+ return egl_api_->eglWaitSyncKHRFn(dpy, sync, flags);
}
-EGLBoolean TraceEGLApi::eglBindAPIFn(EGLenum api) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglBindAPI")
- return egl_api_->eglBindAPIFn(api);
+EGLBoolean DebugEGLApi::eglBindAPIFn(EGLenum api) {
+ GL_SERVICE_LOG("eglBindAPI"
+ << "(" << api << ")");
+ EGLBoolean result = egl_api_->eglBindAPIFn(api);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglBindTexImageFn(EGLDisplay dpy,
+EGLBoolean DebugEGLApi::eglBindTexImageFn(EGLDisplay dpy,
EGLSurface surface,
EGLint buffer) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglBindTexImage")
- return egl_api_->eglBindTexImageFn(dpy, surface, buffer);
+ GL_SERVICE_LOG("eglBindTexImage"
+ << "(" << dpy << ", " << surface << ", " << buffer << ")");
+ EGLBoolean result = egl_api_->eglBindTexImageFn(dpy, surface, buffer);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglChooseConfigFn(EGLDisplay dpy,
+EGLBoolean DebugEGLApi::eglChooseConfigFn(EGLDisplay dpy,
const EGLint* attrib_list,
EGLConfig* configs,
EGLint config_size,
EGLint* num_config) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglChooseConfig")
- return egl_api_->eglChooseConfigFn(dpy, attrib_list, configs, config_size,
- num_config);
+ GL_SERVICE_LOG("eglChooseConfig"
+ << "(" << dpy << ", " << static_cast<const void*>(attrib_list)
+ << ", " << static_cast<const void*>(configs) << ", "
+ << config_size << ", " << static_cast<const void*>(num_config)
+ << ")");
+ EGLBoolean result = egl_api_->eglChooseConfigFn(dpy, attrib_list, configs,
+ config_size, num_config);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLint TraceEGLApi::eglClientWaitSyncKHRFn(EGLDisplay dpy,
+EGLint DebugEGLApi::eglClientWaitSyncKHRFn(EGLDisplay dpy,
EGLSyncKHR sync,
EGLint flags,
EGLTimeKHR timeout) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglClientWaitSyncKHR")
- return egl_api_->eglClientWaitSyncKHRFn(dpy, sync, flags, timeout);
+ GL_SERVICE_LOG("eglClientWaitSyncKHR"
+ << "(" << dpy << ", " << sync << ", " << flags << ", "
+ << timeout << ")");
+ EGLint result = egl_api_->eglClientWaitSyncKHRFn(dpy, sync, flags, timeout);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglCopyBuffersFn(EGLDisplay dpy,
+EGLBoolean DebugEGLApi::eglCopyBuffersFn(EGLDisplay dpy,
EGLSurface surface,
EGLNativePixmapType target) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglCopyBuffers")
- return egl_api_->eglCopyBuffersFn(dpy, surface, target);
+ GL_SERVICE_LOG("eglCopyBuffers"
+ << "(" << dpy << ", " << surface << ", " << target << ")");
+ EGLBoolean result = egl_api_->eglCopyBuffersFn(dpy, surface, target);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLContext TraceEGLApi::eglCreateContextFn(EGLDisplay dpy,
+EGLContext DebugEGLApi::eglCreateContextFn(EGLDisplay dpy,
EGLConfig config,
EGLContext share_context,
const EGLint* attrib_list) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglCreateContext")
- return egl_api_->eglCreateContextFn(dpy, config, share_context, attrib_list);
+ GL_SERVICE_LOG("eglCreateContext"
+ << "(" << dpy << ", " << config << ", " << share_context
+ << ", " << static_cast<const void*>(attrib_list) << ")");
+ EGLContext result =
+ egl_api_->eglCreateContextFn(dpy, config, share_context, attrib_list);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLImageKHR TraceEGLApi::eglCreateImageKHRFn(EGLDisplay dpy,
+EGLImageKHR DebugEGLApi::eglCreateImageKHRFn(EGLDisplay dpy,
EGLContext ctx,
EGLenum target,
EGLClientBuffer buffer,
const EGLint* attrib_list) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglCreateImageKHR")
- return egl_api_->eglCreateImageKHRFn(dpy, ctx, target, buffer, attrib_list);
+ GL_SERVICE_LOG("eglCreateImageKHR"
+ << "(" << dpy << ", " << ctx << ", " << target << ", "
+ << buffer << ", " << static_cast<const void*>(attrib_list)
+ << ")");
+ EGLImageKHR result =
+ egl_api_->eglCreateImageKHRFn(dpy, ctx, target, buffer, attrib_list);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLSurface TraceEGLApi::eglCreatePbufferFromClientBufferFn(
+EGLSurface DebugEGLApi::eglCreatePbufferFromClientBufferFn(
EGLDisplay dpy,
EGLenum buftype,
void* buffer,
EGLConfig config,
const EGLint* attrib_list) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu",
- "TraceGLAPI::eglCreatePbufferFromClientBuffer")
- return egl_api_->eglCreatePbufferFromClientBufferFn(dpy, buftype, buffer,
- config, attrib_list);
+ GL_SERVICE_LOG("eglCreatePbufferFromClientBuffer"
+ << "(" << dpy << ", " << buftype << ", "
+ << static_cast<const void*>(buffer) << ", " << config << ", "
+ << static_cast<const void*>(attrib_list) << ")");
+ EGLSurface result = egl_api_->eglCreatePbufferFromClientBufferFn(
+ dpy, buftype, buffer, config, attrib_list);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLSurface TraceEGLApi::eglCreatePbufferSurfaceFn(EGLDisplay dpy,
+EGLSurface DebugEGLApi::eglCreatePbufferSurfaceFn(EGLDisplay dpy,
EGLConfig config,
const EGLint* attrib_list) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglCreatePbufferSurface")
- return egl_api_->eglCreatePbufferSurfaceFn(dpy, config, attrib_list);
+ GL_SERVICE_LOG("eglCreatePbufferSurface"
+ << "(" << dpy << ", " << config << ", "
+ << static_cast<const void*>(attrib_list) << ")");
+ EGLSurface result =
+ egl_api_->eglCreatePbufferSurfaceFn(dpy, config, attrib_list);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLSurface TraceEGLApi::eglCreatePixmapSurfaceFn(EGLDisplay dpy,
+EGLSurface DebugEGLApi::eglCreatePixmapSurfaceFn(EGLDisplay dpy,
EGLConfig config,
EGLNativePixmapType pixmap,
const EGLint* attrib_list) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglCreatePixmapSurface")
- return egl_api_->eglCreatePixmapSurfaceFn(dpy, config, pixmap, attrib_list);
+ GL_SERVICE_LOG("eglCreatePixmapSurface"
+ << "(" << dpy << ", " << config << ", " << pixmap << ", "
+ << static_cast<const void*>(attrib_list) << ")");
+ EGLSurface result =
+ egl_api_->eglCreatePixmapSurfaceFn(dpy, config, pixmap, attrib_list);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLStreamKHR TraceEGLApi::eglCreateStreamKHRFn(EGLDisplay dpy,
+EGLStreamKHR DebugEGLApi::eglCreateStreamKHRFn(EGLDisplay dpy,
const EGLint* attrib_list) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglCreateStreamKHR")
- return egl_api_->eglCreateStreamKHRFn(dpy, attrib_list);
+ GL_SERVICE_LOG("eglCreateStreamKHR"
+ << "(" << dpy << ", " << static_cast<const void*>(attrib_list)
+ << ")");
+ EGLStreamKHR result = egl_api_->eglCreateStreamKHRFn(dpy, attrib_list);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglCreateStreamProducerD3DTextureNV12ANGLEFn(
+EGLBoolean DebugEGLApi::eglCreateStreamProducerD3DTextureNV12ANGLEFn(
EGLDisplay dpy,
EGLStreamKHR stream,
EGLAttrib* attrib_list) {
- TRACE_EVENT_BINARY_EFFICIENT0(
- "gpu", "TraceGLAPI::eglCreateStreamProducerD3DTextureNV12ANGLE")
- return egl_api_->eglCreateStreamProducerD3DTextureNV12ANGLEFn(dpy, stream,
- attrib_list);
+ GL_SERVICE_LOG("eglCreateStreamProducerD3DTextureNV12ANGLE"
+ << "(" << dpy << ", " << stream << ", "
+ << static_cast<const void*>(attrib_list) << ")");
+ EGLBoolean result = egl_api_->eglCreateStreamProducerD3DTextureNV12ANGLEFn(
+ dpy, stream, attrib_list);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLSyncKHR TraceEGLApi::eglCreateSyncKHRFn(EGLDisplay dpy,
+EGLSyncKHR DebugEGLApi::eglCreateSyncKHRFn(EGLDisplay dpy,
EGLenum type,
const EGLint* attrib_list) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglCreateSyncKHR")
- return egl_api_->eglCreateSyncKHRFn(dpy, type, attrib_list);
+ GL_SERVICE_LOG("eglCreateSyncKHR"
+ << "(" << dpy << ", " << type << ", "
+ << static_cast<const void*>(attrib_list) << ")");
+ EGLSyncKHR result = egl_api_->eglCreateSyncKHRFn(dpy, type, attrib_list);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLSurface TraceEGLApi::eglCreateWindowSurfaceFn(EGLDisplay dpy,
+EGLSurface DebugEGLApi::eglCreateWindowSurfaceFn(EGLDisplay dpy,
EGLConfig config,
EGLNativeWindowType win,
const EGLint* attrib_list) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglCreateWindowSurface")
- return egl_api_->eglCreateWindowSurfaceFn(dpy, config, win, attrib_list);
+ GL_SERVICE_LOG("eglCreateWindowSurface"
+ << "(" << dpy << ", " << config << ", " << win << ", "
+ << static_cast<const void*>(attrib_list) << ")");
+ EGLSurface result =
+ egl_api_->eglCreateWindowSurfaceFn(dpy, config, win, attrib_list);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglDestroyContextFn(EGLDisplay dpy, EGLContext ctx) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglDestroyContext")
- return egl_api_->eglDestroyContextFn(dpy, ctx);
+EGLBoolean DebugEGLApi::eglDestroyContextFn(EGLDisplay dpy, EGLContext ctx) {
+ GL_SERVICE_LOG("eglDestroyContext"
+ << "(" << dpy << ", " << ctx << ")");
+ EGLBoolean result = egl_api_->eglDestroyContextFn(dpy, ctx);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglDestroyImageKHRFn(EGLDisplay dpy,
+EGLBoolean DebugEGLApi::eglDestroyImageKHRFn(EGLDisplay dpy,
EGLImageKHR image) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglDestroyImageKHR")
- return egl_api_->eglDestroyImageKHRFn(dpy, image);
+ GL_SERVICE_LOG("eglDestroyImageKHR"
+ << "(" << dpy << ", " << image << ")");
+ EGLBoolean result = egl_api_->eglDestroyImageKHRFn(dpy, image);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglDestroyStreamKHRFn(EGLDisplay dpy,
+EGLBoolean DebugEGLApi::eglDestroyStreamKHRFn(EGLDisplay dpy,
EGLStreamKHR stream) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglDestroyStreamKHR")
- return egl_api_->eglDestroyStreamKHRFn(dpy, stream);
+ GL_SERVICE_LOG("eglDestroyStreamKHR"
+ << "(" << dpy << ", " << stream << ")");
+ EGLBoolean result = egl_api_->eglDestroyStreamKHRFn(dpy, stream);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglDestroySurfaceFn(EGLDisplay dpy,
+EGLBoolean DebugEGLApi::eglDestroySurfaceFn(EGLDisplay dpy,
EGLSurface surface) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglDestroySurface")
- return egl_api_->eglDestroySurfaceFn(dpy, surface);
+ GL_SERVICE_LOG("eglDestroySurface"
+ << "(" << dpy << ", " << surface << ")");
+ EGLBoolean result = egl_api_->eglDestroySurfaceFn(dpy, surface);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglDestroySyncKHRFn(EGLDisplay dpy, EGLSyncKHR sync) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglDestroySyncKHR")
- return egl_api_->eglDestroySyncKHRFn(dpy, sync);
+EGLBoolean DebugEGLApi::eglDestroySyncKHRFn(EGLDisplay dpy, EGLSyncKHR sync) {
+ GL_SERVICE_LOG("eglDestroySyncKHR"
+ << "(" << dpy << ", " << sync << ")");
+ EGLBoolean result = egl_api_->eglDestroySyncKHRFn(dpy, sync);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglGetConfigAttribFn(EGLDisplay dpy,
+EGLBoolean DebugEGLApi::eglGetConfigAttribFn(EGLDisplay dpy,
EGLConfig config,
EGLint attribute,
EGLint* value) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglGetConfigAttrib")
- return egl_api_->eglGetConfigAttribFn(dpy, config, attribute, value);
+ GL_SERVICE_LOG("eglGetConfigAttrib"
+ << "(" << dpy << ", " << config << ", " << attribute << ", "
+ << static_cast<const void*>(value) << ")");
+ EGLBoolean result =
+ egl_api_->eglGetConfigAttribFn(dpy, config, attribute, value);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglGetConfigsFn(EGLDisplay dpy,
+EGLBoolean DebugEGLApi::eglGetConfigsFn(EGLDisplay dpy,
EGLConfig* configs,
EGLint config_size,
EGLint* num_config) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglGetConfigs")
- return egl_api_->eglGetConfigsFn(dpy, configs, config_size, num_config);
+ GL_SERVICE_LOG("eglGetConfigs"
+ << "(" << dpy << ", " << static_cast<const void*>(configs)
+ << ", " << config_size << ", "
+ << static_cast<const void*>(num_config) << ")");
+ EGLBoolean result =
+ egl_api_->eglGetConfigsFn(dpy, configs, config_size, num_config);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLContext TraceEGLApi::eglGetCurrentContextFn(void) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglGetCurrentContext")
- return egl_api_->eglGetCurrentContextFn();
+EGLContext DebugEGLApi::eglGetCurrentContextFn(void) {
+ GL_SERVICE_LOG("eglGetCurrentContext"
+ << "("
+ << ")");
+ EGLContext result = egl_api_->eglGetCurrentContextFn();
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLDisplay TraceEGLApi::eglGetCurrentDisplayFn(void) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglGetCurrentDisplay")
- return egl_api_->eglGetCurrentDisplayFn();
+EGLDisplay DebugEGLApi::eglGetCurrentDisplayFn(void) {
+ GL_SERVICE_LOG("eglGetCurrentDisplay"
+ << "("
+ << ")");
+ EGLDisplay result = egl_api_->eglGetCurrentDisplayFn();
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLSurface TraceEGLApi::eglGetCurrentSurfaceFn(EGLint readdraw) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglGetCurrentSurface")
- return egl_api_->eglGetCurrentSurfaceFn(readdraw);
+EGLSurface DebugEGLApi::eglGetCurrentSurfaceFn(EGLint readdraw) {
+ GL_SERVICE_LOG("eglGetCurrentSurface"
+ << "(" << readdraw << ")");
+ EGLSurface result = egl_api_->eglGetCurrentSurfaceFn(readdraw);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLDisplay TraceEGLApi::eglGetDisplayFn(EGLNativeDisplayType display_id) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglGetDisplay")
- return egl_api_->eglGetDisplayFn(display_id);
+EGLDisplay DebugEGLApi::eglGetDisplayFn(EGLNativeDisplayType display_id) {
+ GL_SERVICE_LOG("eglGetDisplay"
+ << "(" << display_id << ")");
+ EGLDisplay result = egl_api_->eglGetDisplayFn(display_id);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLint TraceEGLApi::eglGetErrorFn(void) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglGetError")
- return egl_api_->eglGetErrorFn();
+EGLint DebugEGLApi::eglGetErrorFn(void) {
+ GL_SERVICE_LOG("eglGetError"
+ << "("
+ << ")");
+ EGLint result = egl_api_->eglGetErrorFn();
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLDisplay TraceEGLApi::eglGetPlatformDisplayEXTFn(EGLenum platform,
+EGLDisplay DebugEGLApi::eglGetPlatformDisplayEXTFn(EGLenum platform,
void* native_display,
const EGLint* attrib_list) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglGetPlatformDisplayEXT")
- return egl_api_->eglGetPlatformDisplayEXTFn(platform, native_display,
- attrib_list);
+ GL_SERVICE_LOG("eglGetPlatformDisplayEXT"
+ << "(" << platform << ", "
+ << static_cast<const void*>(native_display) << ", "
+ << static_cast<const void*>(attrib_list) << ")");
+ EGLDisplay result = egl_api_->eglGetPlatformDisplayEXTFn(
+ platform, native_display, attrib_list);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-__eglMustCastToProperFunctionPointerType TraceEGLApi::eglGetProcAddressFn(
+__eglMustCastToProperFunctionPointerType DebugEGLApi::eglGetProcAddressFn(
const char* procname) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglGetProcAddress")
- return egl_api_->eglGetProcAddressFn(procname);
+ GL_SERVICE_LOG("eglGetProcAddress"
+ << "(" << procname << ")");
+ __eglMustCastToProperFunctionPointerType result =
+ egl_api_->eglGetProcAddressFn(procname);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglGetSyncAttribKHRFn(EGLDisplay dpy,
+EGLBoolean DebugEGLApi::eglGetSyncAttribKHRFn(EGLDisplay dpy,
EGLSyncKHR sync,
EGLint attribute,
EGLint* value) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglGetSyncAttribKHR")
- return egl_api_->eglGetSyncAttribKHRFn(dpy, sync, attribute, value);
+ GL_SERVICE_LOG("eglGetSyncAttribKHR"
+ << "(" << dpy << ", " << sync << ", " << attribute << ", "
+ << static_cast<const void*>(value) << ")");
+ EGLBoolean result =
+ egl_api_->eglGetSyncAttribKHRFn(dpy, sync, attribute, value);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglGetSyncValuesCHROMIUMFn(EGLDisplay dpy,
+EGLBoolean DebugEGLApi::eglGetSyncValuesCHROMIUMFn(EGLDisplay dpy,
EGLSurface surface,
EGLuint64CHROMIUM* ust,
EGLuint64CHROMIUM* msc,
EGLuint64CHROMIUM* sbc) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglGetSyncValuesCHROMIUM")
- return egl_api_->eglGetSyncValuesCHROMIUMFn(dpy, surface, ust, msc, sbc);
+ GL_SERVICE_LOG("eglGetSyncValuesCHROMIUM"
+ << "(" << dpy << ", " << surface << ", "
+ << static_cast<const void*>(ust) << ", "
+ << static_cast<const void*>(msc) << ", "
+ << static_cast<const void*>(sbc) << ")");
+ EGLBoolean result =
+ egl_api_->eglGetSyncValuesCHROMIUMFn(dpy, surface, ust, msc, sbc);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglImageFlushExternalEXTFn(
+EGLBoolean DebugEGLApi::eglImageFlushExternalEXTFn(
EGLDisplay dpy,
EGLImageKHR image,
const EGLAttrib* attrib_list) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglImageFlushExternalEXT")
- return egl_api_->eglImageFlushExternalEXTFn(dpy, image, attrib_list);
+ GL_SERVICE_LOG("eglImageFlushExternalEXT"
+ << "(" << dpy << ", " << image << ", "
+ << static_cast<const void*>(attrib_list) << ")");
+ EGLBoolean result =
+ egl_api_->eglImageFlushExternalEXTFn(dpy, image, attrib_list);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglInitializeFn(EGLDisplay dpy,
+EGLBoolean DebugEGLApi::eglInitializeFn(EGLDisplay dpy,
EGLint* major,
EGLint* minor) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglInitialize")
- return egl_api_->eglInitializeFn(dpy, major, minor);
+ GL_SERVICE_LOG("eglInitialize"
+ << "(" << dpy << ", " << static_cast<const void*>(major)
+ << ", " << static_cast<const void*>(minor) << ")");
+ EGLBoolean result = egl_api_->eglInitializeFn(dpy, major, minor);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglMakeCurrentFn(EGLDisplay dpy,
+EGLBoolean DebugEGLApi::eglMakeCurrentFn(EGLDisplay dpy,
EGLSurface draw,
EGLSurface read,
EGLContext ctx) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglMakeCurrent")
- return egl_api_->eglMakeCurrentFn(dpy, draw, read, ctx);
+ GL_SERVICE_LOG("eglMakeCurrent"
+ << "(" << dpy << ", " << draw << ", " << read << ", " << ctx
+ << ")");
+ EGLBoolean result = egl_api_->eglMakeCurrentFn(dpy, draw, read, ctx);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglPostSubBufferNVFn(EGLDisplay dpy,
+EGLBoolean DebugEGLApi::eglPostSubBufferNVFn(EGLDisplay dpy,
EGLSurface surface,
EGLint x,
EGLint y,
EGLint width,
EGLint height) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglPostSubBufferNV")
- return egl_api_->eglPostSubBufferNVFn(dpy, surface, x, y, width, height);
+ GL_SERVICE_LOG("eglPostSubBufferNV"
+ << "(" << dpy << ", " << surface << ", " << x << ", " << y
+ << ", " << width << ", " << height << ")");
+ EGLBoolean result =
+ egl_api_->eglPostSubBufferNVFn(dpy, surface, x, y, width, height);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLenum TraceEGLApi::eglQueryAPIFn(void) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglQueryAPI")
- return egl_api_->eglQueryAPIFn();
+EGLenum DebugEGLApi::eglQueryAPIFn(void) {
+ GL_SERVICE_LOG("eglQueryAPI"
+ << "("
+ << ")");
+ EGLenum result = egl_api_->eglQueryAPIFn();
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglQueryContextFn(EGLDisplay dpy,
+EGLBoolean DebugEGLApi::eglQueryContextFn(EGLDisplay dpy,
EGLContext ctx,
EGLint attribute,
EGLint* value) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglQueryContext")
- return egl_api_->eglQueryContextFn(dpy, ctx, attribute, value);
+ GL_SERVICE_LOG("eglQueryContext"
+ << "(" << dpy << ", " << ctx << ", " << attribute << ", "
+ << static_cast<const void*>(value) << ")");
+ EGLBoolean result = egl_api_->eglQueryContextFn(dpy, ctx, attribute, value);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglQueryStreamKHRFn(EGLDisplay dpy,
+EGLBoolean DebugEGLApi::eglQueryStreamKHRFn(EGLDisplay dpy,
EGLStreamKHR stream,
EGLenum attribute,
EGLint* value) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglQueryStreamKHR")
- return egl_api_->eglQueryStreamKHRFn(dpy, stream, attribute, value);
+ GL_SERVICE_LOG("eglQueryStreamKHR"
+ << "(" << dpy << ", " << stream << ", " << attribute << ", "
+ << static_cast<const void*>(value) << ")");
+ EGLBoolean result =
+ egl_api_->eglQueryStreamKHRFn(dpy, stream, attribute, value);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglQueryStreamu64KHRFn(EGLDisplay dpy,
+EGLBoolean DebugEGLApi::eglQueryStreamu64KHRFn(EGLDisplay dpy,
EGLStreamKHR stream,
EGLenum attribute,
EGLuint64KHR* value) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglQueryStreamu64KHR")
- return egl_api_->eglQueryStreamu64KHRFn(dpy, stream, attribute, value);
+ GL_SERVICE_LOG("eglQueryStreamu64KHR"
+ << "(" << dpy << ", " << stream << ", " << attribute << ", "
+ << static_cast<const void*>(value) << ")");
+ EGLBoolean result =
+ egl_api_->eglQueryStreamu64KHRFn(dpy, stream, attribute, value);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-const char* TraceEGLApi::eglQueryStringFn(EGLDisplay dpy, EGLint name) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglQueryString")
- return egl_api_->eglQueryStringFn(dpy, name);
+const char* DebugEGLApi::eglQueryStringFn(EGLDisplay dpy, EGLint name) {
+ GL_SERVICE_LOG("eglQueryString"
+ << "(" << dpy << ", " << name << ")");
+ const char* result = egl_api_->eglQueryStringFn(dpy, name);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglQuerySurfaceFn(EGLDisplay dpy,
+EGLBoolean DebugEGLApi::eglQuerySurfaceFn(EGLDisplay dpy,
EGLSurface surface,
EGLint attribute,
EGLint* value) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglQuerySurface")
- return egl_api_->eglQuerySurfaceFn(dpy, surface, attribute, value);
+ GL_SERVICE_LOG("eglQuerySurface"
+ << "(" << dpy << ", " << surface << ", " << attribute << ", "
+ << static_cast<const void*>(value) << ")");
+ EGLBoolean result =
+ egl_api_->eglQuerySurfaceFn(dpy, surface, attribute, value);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglQuerySurfacePointerANGLEFn(EGLDisplay dpy,
+EGLBoolean DebugEGLApi::eglQuerySurfacePointerANGLEFn(EGLDisplay dpy,
EGLSurface surface,
EGLint attribute,
void** value) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu",
- "TraceGLAPI::eglQuerySurfacePointerANGLE")
- return egl_api_->eglQuerySurfacePointerANGLEFn(dpy, surface, attribute,
- value);
+ GL_SERVICE_LOG("eglQuerySurfacePointerANGLE"
+ << "(" << dpy << ", " << surface << ", " << attribute << ", "
+ << value << ")");
+ EGLBoolean result =
+ egl_api_->eglQuerySurfacePointerANGLEFn(dpy, surface, attribute, value);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglReleaseTexImageFn(EGLDisplay dpy,
+EGLBoolean DebugEGLApi::eglReleaseTexImageFn(EGLDisplay dpy,
EGLSurface surface,
EGLint buffer) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglReleaseTexImage")
- return egl_api_->eglReleaseTexImageFn(dpy, surface, buffer);
+ GL_SERVICE_LOG("eglReleaseTexImage"
+ << "(" << dpy << ", " << surface << ", " << buffer << ")");
+ EGLBoolean result = egl_api_->eglReleaseTexImageFn(dpy, surface, buffer);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglReleaseThreadFn(void) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglReleaseThread")
- return egl_api_->eglReleaseThreadFn();
+EGLBoolean DebugEGLApi::eglReleaseThreadFn(void) {
+ GL_SERVICE_LOG("eglReleaseThread"
+ << "("
+ << ")");
+ EGLBoolean result = egl_api_->eglReleaseThreadFn();
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglStreamAttribKHRFn(EGLDisplay dpy,
+EGLBoolean DebugEGLApi::eglStreamAttribKHRFn(EGLDisplay dpy,
EGLStreamKHR stream,
EGLenum attribute,
EGLint value) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglStreamAttribKHR")
- return egl_api_->eglStreamAttribKHRFn(dpy, stream, attribute, value);
+ GL_SERVICE_LOG("eglStreamAttribKHR"
+ << "(" << dpy << ", " << stream << ", " << attribute << ", "
+ << value << ")");
+ EGLBoolean result =
+ egl_api_->eglStreamAttribKHRFn(dpy, stream, attribute, value);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglStreamConsumerAcquireKHRFn(EGLDisplay dpy,
+EGLBoolean DebugEGLApi::eglStreamConsumerAcquireKHRFn(EGLDisplay dpy,
EGLStreamKHR stream) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu",
- "TraceGLAPI::eglStreamConsumerAcquireKHR")
- return egl_api_->eglStreamConsumerAcquireKHRFn(dpy, stream);
+ GL_SERVICE_LOG("eglStreamConsumerAcquireKHR"
+ << "(" << dpy << ", " << stream << ")");
+ EGLBoolean result = egl_api_->eglStreamConsumerAcquireKHRFn(dpy, stream);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglStreamConsumerGLTextureExternalAttribsNVFn(
+EGLBoolean DebugEGLApi::eglStreamConsumerGLTextureExternalAttribsNVFn(
EGLDisplay dpy,
EGLStreamKHR stream,
EGLAttrib* attrib_list) {
- TRACE_EVENT_BINARY_EFFICIENT0(
- "gpu", "TraceGLAPI::eglStreamConsumerGLTextureExternalAttribsNV")
- return egl_api_->eglStreamConsumerGLTextureExternalAttribsNVFn(dpy, stream,
- attrib_list);
+ GL_SERVICE_LOG("eglStreamConsumerGLTextureExternalAttribsNV"
+ << "(" << dpy << ", " << stream << ", "
+ << static_cast<const void*>(attrib_list) << ")");
+ EGLBoolean result = egl_api_->eglStreamConsumerGLTextureExternalAttribsNVFn(
+ dpy, stream, attrib_list);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglStreamConsumerGLTextureExternalKHRFn(
+EGLBoolean DebugEGLApi::eglStreamConsumerGLTextureExternalKHRFn(
EGLDisplay dpy,
EGLStreamKHR stream) {
- TRACE_EVENT_BINARY_EFFICIENT0(
- "gpu", "TraceGLAPI::eglStreamConsumerGLTextureExternalKHR")
- return egl_api_->eglStreamConsumerGLTextureExternalKHRFn(dpy, stream);
+ GL_SERVICE_LOG("eglStreamConsumerGLTextureExternalKHR"
+ << "(" << dpy << ", " << stream << ")");
+ EGLBoolean result =
+ egl_api_->eglStreamConsumerGLTextureExternalKHRFn(dpy, stream);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglStreamConsumerReleaseKHRFn(EGLDisplay dpy,
+EGLBoolean DebugEGLApi::eglStreamConsumerReleaseKHRFn(EGLDisplay dpy,
EGLStreamKHR stream) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu",
- "TraceGLAPI::eglStreamConsumerReleaseKHR")
- return egl_api_->eglStreamConsumerReleaseKHRFn(dpy, stream);
+ GL_SERVICE_LOG("eglStreamConsumerReleaseKHR"
+ << "(" << dpy << ", " << stream << ")");
+ EGLBoolean result = egl_api_->eglStreamConsumerReleaseKHRFn(dpy, stream);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglStreamPostD3DTextureNV12ANGLEFn(
+EGLBoolean DebugEGLApi::eglStreamPostD3DTextureNV12ANGLEFn(
EGLDisplay dpy,
EGLStreamKHR stream,
void* texture,
const EGLAttrib* attrib_list) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu",
- "TraceGLAPI::eglStreamPostD3DTextureNV12ANGLE")
- return egl_api_->eglStreamPostD3DTextureNV12ANGLEFn(dpy, stream, texture,
- attrib_list);
+ GL_SERVICE_LOG("eglStreamPostD3DTextureNV12ANGLE"
+ << "(" << dpy << ", " << stream << ", "
+ << static_cast<const void*>(texture) << ", "
+ << static_cast<const void*>(attrib_list) << ")");
+ EGLBoolean result = egl_api_->eglStreamPostD3DTextureNV12ANGLEFn(
+ dpy, stream, texture, attrib_list);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglSurfaceAttribFn(EGLDisplay dpy,
+EGLBoolean DebugEGLApi::eglSurfaceAttribFn(EGLDisplay dpy,
EGLSurface surface,
EGLint attribute,
EGLint value) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglSurfaceAttrib")
- return egl_api_->eglSurfaceAttribFn(dpy, surface, attribute, value);
+ GL_SERVICE_LOG("eglSurfaceAttrib"
+ << "(" << dpy << ", " << surface << ", " << attribute << ", "
+ << value << ")");
+ EGLBoolean result =
+ egl_api_->eglSurfaceAttribFn(dpy, surface, attribute, value);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglSwapBuffersFn(EGLDisplay dpy, EGLSurface surface) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglSwapBuffers")
- return egl_api_->eglSwapBuffersFn(dpy, surface);
+EGLBoolean DebugEGLApi::eglSwapBuffersFn(EGLDisplay dpy, EGLSurface surface) {
+ GL_SERVICE_LOG("eglSwapBuffers"
+ << "(" << dpy << ", " << surface << ")");
+ EGLBoolean result = egl_api_->eglSwapBuffersFn(dpy, surface);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglSwapBuffersWithDamageKHRFn(EGLDisplay dpy,
+EGLBoolean DebugEGLApi::eglSwapBuffersWithDamageKHRFn(EGLDisplay dpy,
EGLSurface surface,
EGLint* rects,
EGLint n_rects) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu",
- "TraceGLAPI::eglSwapBuffersWithDamageKHR")
- return egl_api_->eglSwapBuffersWithDamageKHRFn(dpy, surface, rects, n_rects);
+ GL_SERVICE_LOG("eglSwapBuffersWithDamageKHR"
+ << "(" << dpy << ", " << surface << ", "
+ << static_cast<const void*>(rects) << ", " << n_rects << ")");
+ EGLBoolean result =
+ egl_api_->eglSwapBuffersWithDamageKHRFn(dpy, surface, rects, n_rects);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglSwapIntervalFn(EGLDisplay dpy, EGLint interval) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglSwapInterval")
- return egl_api_->eglSwapIntervalFn(dpy, interval);
+EGLBoolean DebugEGLApi::eglSwapIntervalFn(EGLDisplay dpy, EGLint interval) {
+ GL_SERVICE_LOG("eglSwapInterval"
+ << "(" << dpy << ", " << interval << ")");
+ EGLBoolean result = egl_api_->eglSwapIntervalFn(dpy, interval);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglTerminateFn(EGLDisplay dpy) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglTerminate")
- return egl_api_->eglTerminateFn(dpy);
+EGLBoolean DebugEGLApi::eglTerminateFn(EGLDisplay dpy) {
+ GL_SERVICE_LOG("eglTerminate"
+ << "(" << dpy << ")");
+ EGLBoolean result = egl_api_->eglTerminateFn(dpy);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglWaitClientFn(void) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglWaitClient")
- return egl_api_->eglWaitClientFn();
+EGLBoolean DebugEGLApi::eglWaitClientFn(void) {
+ GL_SERVICE_LOG("eglWaitClient"
+ << "("
+ << ")");
+ EGLBoolean result = egl_api_->eglWaitClientFn();
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglWaitGLFn(void) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglWaitGL")
- return egl_api_->eglWaitGLFn();
+EGLBoolean DebugEGLApi::eglWaitGLFn(void) {
+ GL_SERVICE_LOG("eglWaitGL"
+ << "("
+ << ")");
+ EGLBoolean result = egl_api_->eglWaitGLFn();
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLBoolean TraceEGLApi::eglWaitNativeFn(EGLint engine) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglWaitNative")
- return egl_api_->eglWaitNativeFn(engine);
+EGLBoolean DebugEGLApi::eglWaitNativeFn(EGLint engine) {
+ GL_SERVICE_LOG("eglWaitNative"
+ << "(" << engine << ")");
+ EGLBoolean result = egl_api_->eglWaitNativeFn(engine);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
-EGLint TraceEGLApi::eglWaitSyncKHRFn(EGLDisplay dpy,
+EGLint DebugEGLApi::eglWaitSyncKHRFn(EGLDisplay dpy,
EGLSyncKHR sync,
EGLint flags) {
- TRACE_EVENT_BINARY_EFFICIENT0("gpu", "TraceGLAPI::eglWaitSyncKHR")
- return egl_api_->eglWaitSyncKHRFn(dpy, sync, flags);
+ GL_SERVICE_LOG("eglWaitSyncKHR"
+ << "(" << dpy << ", " << sync << ", " << flags << ")");
+ EGLint result = egl_api_->eglWaitSyncKHRFn(dpy, sync, flags);
+ GL_SERVICE_LOG("GL_RESULT: " << result);
+ return result;
}
} // namespace gl
« no previous file with comments | « ui/gl/gl_bindings.h ('k') | ui/gl/gl_bindings_autogen_gl0.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698