[Mesa-dev] [PATCH 03/14] mesa_glinterop: use consistent naming scheme for GL interop

Emil Velikov emil.l.velikov at gmail.com
Tue May 24 14:32:45 UTC 2016


From: Emil Velikov <emil.velikov at collabora.com>

Signed-off-by: Emil Velikov <emil.velikov at collabora.com>
---
 include/GL/mesa_glinterop.h           | 2 +-
 src/gallium/state_trackers/dri/dri2.c | 6 +++---
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/include/GL/mesa_glinterop.h b/include/GL/mesa_glinterop.h
index 814064d..087764e 100644
--- a/include/GL/mesa_glinterop.h
+++ b/include/GL/mesa_glinterop.h
@@ -193,7 +193,7 @@ typedef struct _mesa_glinterop_export_out {
     * format specified by glTexStorage, glTexImage, or glRenderbufferStorage
     * will be returned.
     */
-   GLenum internalformat;
+   GLenum internal_format;
 
    /* Buffer offset and size for GL_ARRAY_BUFFER and GL_TEXTURE_BUFFER.
     * This allows interop with suballocations (a buffer allocated within
diff --git a/src/gallium/state_trackers/dri/dri2.c b/src/gallium/state_trackers/dri/dri2.c
index b07cfcb..7f0db35 100644
--- a/src/gallium/state_trackers/dri/dri2.c
+++ b/src/gallium/state_trackers/dri/dri2.c
@@ -1603,7 +1603,7 @@ dri2_interop_export_object(__DRIcontext *_ctx,
          return MESA_GLINTEROP_OUT_OF_RESOURCES;
       }
 
-      out->internalformat = rb->InternalFormat;
+      out->internal_format = rb->InternalFormat;
       out->view_minlevel = 0;
       out->view_numlevels = 1;
       out->view_minlayer = 0;
@@ -1659,14 +1659,14 @@ dri2_interop_export_object(__DRIcontext *_ctx,
       }
 
       if (target == GL_TEXTURE_BUFFER) {
-         out->internalformat = obj->BufferObjectFormat;
+         out->internal_format = obj->BufferObjectFormat;
          out->buf_offset = obj->BufferOffset;
          out->buf_size = obj->BufferSize == -1 ? obj->BufferObject->Size :
                                                  obj->BufferSize;
 
          obj->BufferObject->UsageHistory |= USAGE_DISABLE_MINMAX_CACHE;
       } else {
-         out->internalformat = obj->Image[0][0]->InternalFormat;
+         out->internal_format = obj->Image[0][0]->InternalFormat;
          out->view_minlevel = obj->MinLevel;
          out->view_numlevels = obj->NumLevels;
          out->view_minlayer = obj->MinLayer;
-- 
2.8.2



More information about the mesa-dev mailing list