diff options
author | Brian <[email protected]> | 2007-05-21 21:48:33 -0600 |
---|---|---|
committer | Brian <[email protected]> | 2007-05-21 21:48:33 -0600 |
commit | a01ee8ff0bdc9b80907f2fe48ebf1618ce2ded92 (patch) | |
tree | 4702f92d38c2c62c48ca8d0178b4f25d4ba71772 /src/mesa/main/texobj.c | |
parent | 3898e67f49b375bd0127fb2931468653cc29d5f9 (diff) |
improve some comments, clean-up formatting
Diffstat (limited to 'src/mesa/main/texobj.c')
-rw-r--r-- | src/mesa/main/texobj.c | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/src/mesa/main/texobj.c b/src/mesa/main/texobj.c index bd447ac0688..65e1bc1357d 100644 --- a/src/mesa/main/texobj.c +++ b/src/mesa/main/texobj.c @@ -1097,14 +1097,21 @@ _mesa_IsTexture( GLuint texture ) return t && t->Target; } -/* Simplest implementation of texture locking: Grab the a new mutex in + +/** + * Simplest implementation of texture locking: Grab the a new mutex in * the shared context. Examine the shared context state timestamp and * if there has been a change, set the appropriate bits in * ctx->NewState. * - * See also _mesa_lock/unlock_texture in texobj.h + * This is used to deal with synchronizing things when a texture object + * is used/modified by different contexts (or threads) which are sharing + * the texture. + * + * See also _mesa_lock/unlock_texture() in teximage.h */ -void _mesa_lock_context_textures( GLcontext *ctx ) +void +_mesa_lock_context_textures( GLcontext *ctx ) { _glthread_LOCK_MUTEX(ctx->Shared->TexMutex); @@ -1115,7 +1122,8 @@ void _mesa_lock_context_textures( GLcontext *ctx ) } -void _mesa_unlock_context_textures( GLcontext *ctx ) +void +_mesa_unlock_context_textures( GLcontext *ctx ) { assert(ctx->Shared->TextureStateStamp == ctx->TextureStateTimestamp); _glthread_UNLOCK_MUTEX(ctx->Shared->TexMutex); |