Name

OfxMultiThreadSuiteV1::mutexTryLock — Non blocking attempt to lock the mutex

Synopsis

#include "ofxMultiThread.h" 
OfxStatus (*mutexTryLock) ( const OfxMutexHandle mutex ) ;
 

Arguments

  • mutex -

Description

This attempts to lock a mutex, if it cannot, it returns and says so, rather than blocking.

A sucessful lock causes the mutex's lock count to be increased by one, if the lock did not suceed, the call returns immediately and the lock count remains unchanged.

Returns

  • kOfxStatOK - if it got the lock
  • kOfxStatFailed - if it did not get the lock
  • kOfxStatErrBadHandle - if the handle was bad