PageRenderTime 22ms CodeModel.GetById 14ms app.highlight 5ms RepoModel.GetById 1ms app.codeStats 0ms

/src/VBox/GuestHost/OpenGL/include/cr_bufpool.h

https://gitlab.com/ufo/virtualbox-ose-3-1-8
C Header | 33 lines | 19 code | 9 blank | 5 comment | 0 complexity | f995e2efd2bc754a429e7dfa27c63c0c MD5 | raw file
 1/* Copyright (c) 2001, Stanford University
 2 * All rights reserved.
 3 *
 4 * See the file LICENSE.txt for information on redistributing this software.
 5 */
 6
 7#ifndef CR_BUFPOOL_H
 8#define CR_BUFPOOL_H
 9
10#include <iprt/cdefs.h>
11
12#ifdef __cplusplus
13extern "C" {
14#endif
15
16typedef struct CRBufferPool_t CRBufferPool;
17typedef void (*CRBufferPoolDeleteCallback)(void *data);
18
19DECLEXPORT(CRBufferPool *) crBufferPoolInit( unsigned int maxBuffers );
20DECLEXPORT(void) crBufferPoolFree( CRBufferPool *pool );
21DECLEXPORT(void) crBufferPoolCallbackFree(CRBufferPool *pool, CRBufferPoolDeleteCallback pfnDelete);
22
23DECLEXPORT(void)   crBufferPoolPush( CRBufferPool *pool, void *buf, unsigned int bytes );
24DECLEXPORT(void *) crBufferPoolPop( CRBufferPool *pool, unsigned int bytes );
25
26DECLEXPORT(int) crBufferPoolGetNumBuffers( CRBufferPool *pool );
27DECLEXPORT(int) crBufferPoolGetMaxBuffers( CRBufferPool *pool );
28
29#ifdef __cplusplus
30}
31#endif
32
33#endif /* CR_BUFPOOL_H */