diff options
author | piman@chromium.org <piman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-02-27 01:29:51 +0000 |
---|---|---|
committer | piman@chromium.org <piman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-02-27 01:29:51 +0000 |
commit | 840a7e465bf6de0c40e1240b8fff7ef121f1f964 (patch) | |
tree | 58a110e62cc4f41e0f3b5c420580306360c1513f /gpu/GLES2 | |
parent | 7c97f8cec3686136ad08b583d1596f25c713e3ce (diff) | |
download | chromium_src-840a7e465bf6de0c40e1240b8fff7ef121f1f964.zip chromium_src-840a7e465bf6de0c40e1240b8fff7ef121f1f964.tar.gz chromium_src-840a7e465bf6de0c40e1240b8fff7ef121f1f964.tar.bz2 |
Make WaitSyncPoint go through command buffers.
BUG=178305
Review URL: https://chromiumcodereview.appspot.com/12330129
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@184820 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'gpu/GLES2')
-rw-r--r-- | gpu/GLES2/extensions/CHROMIUM/CHROMIUM_sync_point.txt | 73 | ||||
-rw-r--r-- | gpu/GLES2/gl2chromium_autogen.h | 1 | ||||
-rw-r--r-- | gpu/GLES2/gl2extchromium.h | 11 |
3 files changed, 85 insertions, 0 deletions
diff --git a/gpu/GLES2/extensions/CHROMIUM/CHROMIUM_sync_point.txt b/gpu/GLES2/extensions/CHROMIUM/CHROMIUM_sync_point.txt new file mode 100644 index 0000000..bc8665a --- /dev/null +++ b/gpu/GLES2/extensions/CHROMIUM/CHROMIUM_sync_point.txt @@ -0,0 +1,73 @@ +Name + + CHROMIUM_sync_point + +Name Strings + + GL_CHROMIUM_sync_point + +Version + + Last Modifed Date: February 25, 2013 + +Dependencies + + OpenGL ES 2.0 is required. + +Overview + + This extension allows a client to order operations between contexts. + + This extension implements a small subset of ARB_sync, with weaker + guarantees. In particular it doesn't ensure commands are actually executed + by the server, it only guarantees submission order. + + It does however guarantee operation order with respect to + ConsumeTextureCHROMIUM and ProduceTextureCHROMIUM from + CHROMIUM_texture_mailbox, if present. + +Issues + + None + +New Tokens + + None + +New Procedures and Functions + + The command + + uint InsertSyncPointCHROMIUM() + + creates a sync point and inserts it into the stream of commands for the + current context. The sync point acts as a fence, which is signaled when + previous commands have been submitted to the server, or when the context is + destroyed, whichever happens first. The sync point name is returned. The + sync point is implicitly deleted when it becomes signaled. The sync point + namespace is shared between all contexts on the same server, including other + context groups. + + + The command + + void WaitSyncPointCHROMIUM(uint sync_point) + + causes the current context to stop submitting commands until the specified + sync point becomes signaled. This is implemented as a server-side wait. + <sync_point> is the name of the sync point to wait for. If <sync_point> + isn't a valid sync point returned by InsertSyncPointCHROMIUM, or if the sync + point has already been deleted, the command is equivalent to a no-op and no + error is generated. + +Errors + + None. + +New State + + None. + +Revision History + + 2/25/2013 Documented the extension diff --git a/gpu/GLES2/gl2chromium_autogen.h b/gpu/GLES2/gl2chromium_autogen.h index 88bf547..bda7202 100644 --- a/gpu/GLES2/gl2chromium_autogen.h +++ b/gpu/GLES2/gl2chromium_autogen.h @@ -221,6 +221,7 @@ #define glAsyncTexImage2DCHROMIUM GLES2_GET_FUN(AsyncTexImage2DCHROMIUM) #define glDiscardFramebufferEXT GLES2_GET_FUN(DiscardFramebufferEXT) #define glLoseContextCHROMIUM GLES2_GET_FUN(LoseContextCHROMIUM) +#define glWaitSyncPointCHROMIUM GLES2_GET_FUN(WaitSyncPointCHROMIUM) #endif // GPU_GLES2_GL2CHROMIUM_AUTOGEN_H_ diff --git a/gpu/GLES2/gl2extchromium.h b/gpu/GLES2/gl2extchromium.h index 0dd021d..6609fd4 100644 --- a/gpu/GLES2/gl2extchromium.h +++ b/gpu/GLES2/gl2extchromium.h @@ -443,6 +443,17 @@ typedef void (GL_APIENTRYP PFNGLGETPROGRAMINFOCHROMIUMPROC) ( #define GL_CHROMIUM_front_buffer_cached 1 #endif /* GL_CHROMIUM_front_buffer_cached */ +/* GL_CHROMIUM_sync_point */ +#ifndef GL_CHROMIUM_sync_point +#define GL_CHROMIUM_sync_point 1 +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL GLuint GL_APIENTRY glInsertSyncPointCHROMIUM(); +GL_APICALL void GL_APIENTRY glWaitSyncPointCHROMIUM(GLuint sync_point); +#endif +typedef GLuint (GL_APIENTRYP PFNGLINSERTSYNCPOINTCHROMIUMPROC) (); +typedef void (GL_APIENTRYP PFNGLWAITSYNCPOINTCHROMIUMPROC) (GLuint sync_point); +#endif /* GL_CHROMIUM_sync_point */ + #ifdef __cplusplus } #endif |