shaderlib.h revision 3194da424708abdd288b28d96892b3a5f3f7df0b
45e9809aff7304721fddb95654901b32195c9c7avboxsync#ifndef __SHADERLIB_H__
45e9809aff7304721fddb95654901b32195c9c7avboxsync#define __SHADERLIB_H__
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#include <VBox/cdefs.h>
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#ifdef __cplusplus
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern "C" {
45e9809aff7304721fddb95654901b32195c9c7avboxsync#endif
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#ifdef IN_SHADERLIB_STATIC
45e9809aff7304721fddb95654901b32195c9c7avboxsync# define SHADERDECL(type) DECLHIDDEN(type) RTCALL
45e9809aff7304721fddb95654901b32195c9c7avboxsync#else
45e9809aff7304721fddb95654901b32195c9c7avboxsync# define SHADERDECL(type) DECLEXPORT(type) RTCALL
45e9809aff7304721fddb95654901b32195c9c7avboxsync#endif
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncSHADERDECL(int) ShaderInitLib();
45e9809aff7304721fddb95654901b32195c9c7avboxsyncSHADERDECL(int) ShaderDestroyLib();
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncSHADERDECL(int) ShaderContextCreate(void **ppShaderContext);
45e9809aff7304721fddb95654901b32195c9c7avboxsyncSHADERDECL(int) ShaderContextDestroy(void *pShaderContext);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncSHADERDECL(int) ShaderCreateVertexShader(void *pShaderContext, const uint32_t *pShaderData, void **pShaderObj);
45e9809aff7304721fddb95654901b32195c9c7avboxsyncSHADERDECL(int) ShaderCreatePixelShader(void *pShaderContext, const uint32_t *pShaderData, void **pShaderObj);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncSHADERDECL(int) ShaderDestroyVertexShader(void *pShaderContext, void *pShaderObj);
45e9809aff7304721fddb95654901b32195c9c7avboxsyncSHADERDECL(int) ShaderDestroyPixelShader(void *pShaderContext, void *pShaderObj);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncSHADERDECL(int) ShaderSetVertexShader(void *pShaderContext, void *pShaderObj);
45e9809aff7304721fddb95654901b32195c9c7avboxsyncSHADERDECL(int) ShaderSetPixelShader(void *pShaderContext, void *pShaderObj);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncSHADERDECL(int) ShaderSetVertexShaderConstantB(void *pShaderContext, uint32_t reg, const uint8_t *pValues, uint32_t cRegisters);
45e9809aff7304721fddb95654901b32195c9c7avboxsyncSHADERDECL(int) ShaderSetVertexShaderConstantI(void *pShaderContext, uint32_t reg, const int32_t *pValues, uint32_t cRegisters);
45e9809aff7304721fddb95654901b32195c9c7avboxsyncSHADERDECL(int) ShaderSetVertexShaderConstantF(void *pShaderContext, uint32_t reg, const float *pValues, uint32_t cRegisters);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncSHADERDECL(int) ShaderSetPixelShaderConstantB(void *pShaderContext, uint32_t reg, const uint8_t *pValues, uint32_t cRegisters);
45e9809aff7304721fddb95654901b32195c9c7avboxsyncSHADERDECL(int) ShaderSetPixelShaderConstantI(void *pShaderContext, uint32_t reg, const int32_t *pValues, uint32_t cRegisters);
45e9809aff7304721fddb95654901b32195c9c7avboxsyncSHADERDECL(int) ShaderSetPixelShaderConstantF(void *pShaderContext, uint32_t reg, const float *pValues, uint32_t cRegisters);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncSHADERDECL(int) ShaderUpdateState(void *pShaderContext, uint32_t rtHeight);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncSHADERDECL(int) ShaderTransformProjection(unsigned cxViewPort, unsigned cyViewPort, float matrix[16]);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#ifdef __cplusplus
45e9809aff7304721fddb95654901b32195c9c7avboxsync}
45e9809aff7304721fddb95654901b32195c9c7avboxsync#endif
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#endif /* __SHADERLIB_H__ */
45e9809aff7304721fddb95654901b32195c9c7avboxsync