diff options
author | Chris Robinson <[email protected]> | 2009-12-09 12:14:53 -0800 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2009-12-09 12:14:53 -0800 |
commit | 2b7953c472f1f0a6045dd4768ad1feceffce4cb3 (patch) | |
tree | 1c53d35296d8cbadb1d1877957b1bc01ebd354e3 /Alc/ALc.c | |
parent | 368ef1cea9f2f17158ffebc70cab5c466652a176 (diff) |
Track whether a context is suspended or not
Diffstat (limited to 'Alc/ALc.c')
-rw-r--r-- | Alc/ALc.c | 13 |
1 files changed, 9 insertions, 4 deletions
@@ -596,6 +596,7 @@ static ALvoid InitContext(ALCcontext *pContext) //Validate pContext pContext->LastError = AL_NO_ERROR; pContext->InUse = AL_FALSE; + pContext->Suspended = AL_FALSE; //Set globals pContext->DistanceModel = AL_INVERSE_DISTANCE_CLAMPED; @@ -772,8 +773,10 @@ ALCAPI ALCenum ALCAPIENTRY alcGetError(ALCdevice *device) */ ALCAPI ALCvoid ALCAPIENTRY alcSuspendContext(ALCcontext *pContext) { - // Not a lot happens here ! - (void)pContext; + SuspendContext(NULL); + if(IsContext(pContext)) + pContext->Suspended = AL_TRUE; + ProcessContext(NULL); } @@ -784,8 +787,10 @@ ALCAPI ALCvoid ALCAPIENTRY alcSuspendContext(ALCcontext *pContext) */ ALCAPI ALCvoid ALCAPIENTRY alcProcessContext(ALCcontext *pContext) { - // Not a lot happens here ! - (void)pContext; + SuspendContext(NULL); + if(IsContext(pContext)) + pContext->Suspended = AL_FALSE; + ProcessContext(NULL); } |