Name

    CHROMIUM_sync_point

Name Strings

    GL_CHROMIUM_sync_point

Version

    Last Modifed Date: September 8, 2015

Dependencies

    OpenGL ES 2.0 is required.

Overview

    This extension allows a client to order operations between contexts.

    This extension introduces the concept of "fence syncs" and "sync token".
    Inserted fence syncs represents a position in the command stream of a
    context. Sync tokens are generated from fence syncs and allows another
    context to issue a "wait" command on the sync token. This wait command
    will then guarantee that commands before the inserted fence sync are
    submitted before commands after the sync token wait.

    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 Procedures and Functions

    The command

        uint InsertFenceSyncCHROMIUM()

    inserts a fence sync in the current command stream. The fence sync is
    signaled when previous commands have been submitted to the server, or when
    the context is destroyed, whichever happens first. The fence sync name is
    only visible for the current context. The returned fence sync name cannot
    be waited upon directly, but once the command is flushed to the server it
    can be converted to a sync token using GenSyncTokenCHROMIUM which is
    waitable.

    The command

        void GenSyncTokenCHROMIUM(uint fence_sync, GLbyte *sync_token)

    converts <fence_sync> which is only visible to the current context to a
    sync token which may be waited upon by any contexts on the same server.
    The <fence_sync> command must be flushed before this function may be
    called, otherwise an INVALID_OPERATION error is generated. The generated
    <sync_token> must be generated on the same context as when
    InsertSyncPointCHROMIUM was called. The <sync_token> can be passed and
    used by any context on the same server, including other context groups.

    <sync_token> returns a GL_SYNC_POINT_SIZE_CHROMIUM byte sized name.

    The command

        void WaitSyncTokenCHROMIUM(GLbyte *sync_token)

    causes the current context to stop submitting commands until the specified
    fence sync becomes signaled. This is implemented as a server-side wait.
    <sync_token> is a sync token generated by GenSyncPointCHROMIUM. If
    <sync_token> isn't a valid sync token returned by GenSyncPointCHROMIUM, the
    command is equivalent to a no-op and no error is generated.

New Tokens

    The size of a sync token name in bytes.

        GL_SYNC_TOKEN_SIZE_CHROMIUM                        12

Errors

    INVALID_VALUE is generated if the <fence_sync> parameter of
    GenSyncPointCHROMIUM is not a valid local fence sync name.

    INVALID_OPERATION is generated if the <fence_sync> parameter of
    GenSyncPointCHROMIUM has not been flushed to the server.

New State

    None.

Revision History

    2/25/2013    Documented the extension

    9/8/2015     Modified functions to InsertFenceSyncCHROMIUM,
    GenSyncTokenCHROMIUM, and WaitSyncTokenCHROMIUM.
