summaryrefslogtreecommitdiffstats
path: root/gpu/GLES2
diff options
context:
space:
mode:
authorbajones@chromium.org <bajones@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-06-10 17:51:22 +0000
committerbajones@chromium.org <bajones@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-06-10 17:51:22 +0000
commit43f253da10d5a2c7e24df81fd6d8c9ef7c03cf1b (patch)
tree152dc57bb5dd1497ba97a347c4c9d2f6bad08c1b /gpu/GLES2
parent275838d7fca42818390bd4fa30d0888869420e33 (diff)
downloadchromium_src-43f253da10d5a2c7e24df81fd6d8c9ef7c03cf1b.zip
chromium_src-43f253da10d5a2c7e24df81fd6d8c9ef7c03cf1b.tar.gz
chromium_src-43f253da10d5a2c7e24df81fd6d8c9ef7c03cf1b.tar.bz2
Adding bindless variants mailbox produce/consume
BUG=354697 Review URL: https://codereview.chromium.org/299043003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@276068 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'gpu/GLES2')
-rw-r--r--gpu/GLES2/extensions/CHROMIUM/CHROMIUM_texture_mailbox.txt33
-rw-r--r--gpu/GLES2/gl2chromium_autogen.h4
-rw-r--r--gpu/GLES2/gl2extchromium.h8
3 files changed, 40 insertions, 5 deletions
diff --git a/gpu/GLES2/extensions/CHROMIUM/CHROMIUM_texture_mailbox.txt b/gpu/GLES2/extensions/CHROMIUM/CHROMIUM_texture_mailbox.txt
index f3c476b..9cc8c86 100644
--- a/gpu/GLES2/extensions/CHROMIUM/CHROMIUM_texture_mailbox.txt
+++ b/gpu/GLES2/extensions/CHROMIUM/CHROMIUM_texture_mailbox.txt
@@ -8,7 +8,7 @@ Name Strings
Version
- Last Modifed Date: April 25, 2012
+ Last Modifed Date: June 2, 2014
Dependencies
@@ -18,11 +18,12 @@ Overview
This extension defines a way of sharing texture image data between texture
objects in different contexts where the contexts would not normally share
- texture resources. Three new functions are exported. glGenMailboxCHROMIUM
+ texture resources. Five new functions are exported. glGenMailboxCHROMIUM
generates a name that can be used to identify texture image data outside
- the scope of a context group. glProduceMailboxCHROMIUM associates a texture
- object with a global mailbox name. glConsumeMailboxCHROMIUM associates the
- texture object referenced by a mailbox name to a texture name.
+ the scope of a context group. glProduceMailboxCHROMIUM and
+ glProduceTextureDirectCHROMIUM associate a texture object with a global
+ mailbox name. glConsumeMailboxCHROMIUM and glCreateAndConsumeTextureCHROMIUM
+ associate the texture object referenced by a mailbox name to a texture name.
New Procedures and Functions
@@ -62,6 +63,17 @@ New Procedures and Functions
INVALID_OPERATION is generated if <mailbox> is invalid.
+ void glProduceTextureDirectCHROMIUM (GLuint texture, GLenum target,
+ const GLbyte *mailbox)
+
+ Associates the specified texture object with the mailbox name. Performs
+ identically to glProduceTextureCHROMIUM except that the texture specified by
+ <texture> is used instead of the currently bound texture. This operation
+ does not change the texture bindings or alter the bound texture in any way.
+
+ <texture> Specifies the name of a texture.
+
+
void glConsumeTextureCHROMIUM (GLenum target, const GLbyte *mailbox)
<target> uses the same parameters as TexImage2D.
@@ -95,6 +107,15 @@ New Procedures and Functions
INVALID_OPERATION is generated if the currently bound texture was previously
deleted (for example in another context), hence doesn't have a name.
+
+ GLuint glCreateAndConsumeTextureCHROMIUM (GLenum target,
+ const GLbyte *mailbox)
+
+ Returns a new texture name associated with the given target pointing to the
+ texture object associated with the mailbox name. Does not alter the texture
+ bindings or alter the currently bound texture in any way. Otherwise performs
+ identically to glConsumeTextureCHROMIUM.
+
New Tokens
The size of a mailbox name in bytes.
@@ -118,3 +139,5 @@ Revision History
4/25/2011 Documented the extension
5/23/2013 Major revision in Produce/Consume semantics, introducing
sharing.
+ 6/02/2014 Added glProduceTextureDirectCHROMIUM and
+ glCreateAndConsumeTextureCHROMIUM definitions.
diff --git a/gpu/GLES2/gl2chromium_autogen.h b/gpu/GLES2/gl2chromium_autogen.h
index db9c6249..7f3bbee 100644
--- a/gpu/GLES2/gl2chromium_autogen.h
+++ b/gpu/GLES2/gl2chromium_autogen.h
@@ -216,7 +216,11 @@
#define glVertexAttribDivisorANGLE GLES2_GET_FUN(VertexAttribDivisorANGLE)
#define glGenMailboxCHROMIUM GLES2_GET_FUN(GenMailboxCHROMIUM)
#define glProduceTextureCHROMIUM GLES2_GET_FUN(ProduceTextureCHROMIUM)
+#define glProduceTextureDirectCHROMIUM \
+ GLES2_GET_FUN(ProduceTextureDirectCHROMIUM)
#define glConsumeTextureCHROMIUM GLES2_GET_FUN(ConsumeTextureCHROMIUM)
+#define glCreateAndConsumeTextureCHROMIUM \
+ GLES2_GET_FUN(CreateAndConsumeTextureCHROMIUM)
#define glBindUniformLocationCHROMIUM GLES2_GET_FUN(BindUniformLocationCHROMIUM)
#define glBindTexImage2DCHROMIUM GLES2_GET_FUN(BindTexImage2DCHROMIUM)
#define glReleaseTexImage2DCHROMIUM GLES2_GET_FUN(ReleaseTexImage2DCHROMIUM)
diff --git a/gpu/GLES2/gl2extchromium.h b/gpu/GLES2/gl2extchromium.h
index d78f8ef..0671187 100644
--- a/gpu/GLES2/gl2extchromium.h
+++ b/gpu/GLES2/gl2extchromium.h
@@ -55,14 +55,22 @@ typedef void (GL_APIENTRYP PFNGLTEXIMAGEIOSURFACE2DCHROMIUMPROC) (
GL_APICALL void GL_APIENTRY glGenMailboxCHROMIUM(GLbyte* mailbox);
GL_APICALL void GL_APIENTRY glProduceTextureCHROMIUM(
GLenum target, const GLbyte* mailbox);
+GL_APICALL void GL_APIENTRY glProduceTextureDirectCHROMIUM(
+ GLuint texture, GLenum target, const GLbyte* mailbox);
GL_APICALL void GL_APIENTRY glConsumeTextureCHROMIUM(
GLenum target, const GLbyte* mailbox);
+GL_APICALL GLuint GL_APIENTRY glCreateAndConsumeTextureCHROMIUM(
+ GLenum target, const GLbyte* mailbox);
#endif
typedef void (GL_APIENTRYP PFNGLGENMAILBOXCHROMIUMPROC) (GLbyte* mailbox);
typedef void (GL_APIENTRYP PFNGLPRODUCETEXTURECHROMIUMPROC) (
GLenum target, const GLbyte* mailbox);
+typedef void (GL_APIENTRYP PFNGLPRODUCETEXTUREDIRECTCHROMIUMPROC) (
+ GLuint texture, GLenum target, const GLbyte* mailbox);
typedef void (GL_APIENTRYP PFNGLCONSUMETEXTURECHROMIUMPROC) (
GLenum target, const GLbyte* mailbox);
+typedef GLuint (GL_APIENTRYP PFNGLCREATEANDCONSUMETEXTURECHROMIUMPROC) (
+ GLenum target, const GLbyte* mailbox);
#endif /* GL_CHROMIUM_texture_mailbox */
/* GL_CHROMIUM_pixel_transfer_buffer_object */