1 | /* $Id: dlm.h 56566 2015-06-20 08:10:59Z vboxsync $ */
|
---|
2 |
|
---|
3 | #ifndef _DLM_H
|
---|
4 | #define _DLM_H
|
---|
5 |
|
---|
6 | #include "cr_dlm.h"
|
---|
7 | #include "cr_spu.h"
|
---|
8 |
|
---|
9 | #ifdef CHROMIUM_THREADSAFE
|
---|
10 | #define DLM_LOCK(dlm) crLockMutex(&(dlm->dlMutex));
|
---|
11 | #define DLM_UNLOCK(dlm) crUnlockMutex(&(dlm->dlMutex));
|
---|
12 | extern CRtsd CRDLMTSDKey;
|
---|
13 | #define SET_CURRENT_STATE(state) crSetTSD(&CRDLMTSDKey, (void *)state);
|
---|
14 | #define CURRENT_STATE() ((CRDLMContextState *)crGetTSD(&CRDLMTSDKey))
|
---|
15 | #else
|
---|
16 | #define DLM_LOCK(dlm)
|
---|
17 | #define DLM_UNLOCK(dlm)
|
---|
18 | extern CRDLMContextState *CRDLMCurrentState;
|
---|
19 | #define SET_CURRENT_STATE(state) CRDLMCurrentState = (state);
|
---|
20 | #define CURRENT_STATE() (CRDLMCurrentState)
|
---|
21 | #endif
|
---|
22 |
|
---|
23 | /* These routines are intended to be used within the DLM library, across
|
---|
24 | * the modules therein, but not as an API into the DLM library from
|
---|
25 | * outside.
|
---|
26 | */
|
---|
27 | extern void crdlmWarning( int line, char *file, GLenum error, char *format, ... );
|
---|
28 | extern void crdlmFreeDisplayListResourcesCb(void *pParm1, void *pParam2);
|
---|
29 | extern void crdlm_error(int line, const char *file, GLenum error, const char *info);
|
---|
30 |
|
---|
31 | #endif
|
---|