diff options
author | Chad Versace <chad.versace@intel.com> | 2016-04-25 14:54:56 -0700 |
---|---|---|
committer | Chad Versace <chad.versace@intel.com> | 2016-04-28 10:49:30 -0700 |
commit | 1d2374f463b3b14dfae8d9993b2e7aab756077a6 (patch) | |
tree | ab07cb8bfde9b22dde0c11d2b139373969995ef7 | |
parent | 7dd3115a091d6c27f64f91608ff15cb1c0420e61 (diff) |
ext_image_dma_buf_import: Use piglit-dispatch
Stop calling eglGetProcAddress. Let piglit-dispatch do it.
-rw-r--r-- | tests/spec/ext_image_dma_buf_import/intel_external_sampler_only.c | 26 |
1 files changed, 3 insertions, 23 deletions
diff --git a/tests/spec/ext_image_dma_buf_import/intel_external_sampler_only.c b/tests/spec/ext_image_dma_buf_import/intel_external_sampler_only.c index 59772e18e..7743a68a8 100644 --- a/tests/spec/ext_image_dma_buf_import/intel_external_sampler_only.c +++ b/tests/spec/ext_image_dma_buf_import/intel_external_sampler_only.c @@ -42,10 +42,6 @@ PIGLIT_GL_TEST_CONFIG_BEGIN PIGLIT_GL_TEST_CONFIG_END -static PFNGLGENRENDERBUFFERSOESPROC piglit_glGenRenderbuffersOES; -static PFNGLBINDRENDERBUFFEROESPROC piglit_glBindRenderbufferOES; -static PFNGLDELETERENDERBUFFERSOESPROC piglit_glDeleteRenderbuffersOES; - static EGLImageKHR create_image(unsigned w, unsigned h, int fd, unsigned stride, unsigned offset) { @@ -87,13 +83,11 @@ try_as_render_buffer(EGLImageKHR img) GLuint rbo; bool res; - piglit_glGenRenderbuffersOES(1, &rbo); - piglit_glBindRenderbufferOES(GL_RENDERBUFFER_OES, rbo); - + glGenRenderbuffersOES(1, &rbo); + glBindRenderbufferOES(GL_RENDERBUFFER_OES, rbo); glEGLImageTargetRenderbufferStorageOES(GL_RENDERBUFFER_OES, img); res = piglit_check_gl_error(GL_NO_ERROR); - - piglit_glDeleteRenderbuffersOES(1, &rbo); + glDeleteRenderbuffersOES(1, &rbo); return res; } @@ -148,20 +142,6 @@ piglit_init(int argc, char **argv) piglit_require_egl_extension(egl_dpy, "EGL_KHR_image_base"); piglit_require_extension("GL_OES_EGL_image"); piglit_require_extension("GL_OES_framebuffer_object"); - - piglit_glGenRenderbuffersOES = - (PFNGLGENRENDERBUFFERSOESPROC) - eglGetProcAddress("glGenRenderbuffersOES"); - piglit_glBindRenderbufferOES = - (PFNGLBINDRENDERBUFFEROESPROC) - eglGetProcAddress("glBindRenderbufferOES"); - piglit_glDeleteRenderbuffersOES = - (PFNGLDELETERENDERBUFFERSOESPROC) - eglGetProcAddress("glDeleteRenderbuffersOES"); - if (!piglit_glGenRenderbuffersOES || - !piglit_glBindRenderbufferOES || - !piglit_glDeleteRenderbuffersOES) - piglit_report_result(PIGLIT_FAIL); vendor_str = (const char *)glGetString(GL_VENDOR); if (strncmp(vendor_str, intel_id, sizeof(intel_id) - 1) != 0) { |