Updated docs.

This commit is contained in:
Branimir Karadžić 2015-11-02 19:26:42 -08:00
parent 6e7de6f122
commit fdb8d0dec9
3 changed files with 30 additions and 1 deletions

View file

@ -1530,9 +1530,19 @@ namespace bgfx
///
void destroyUniform(UniformHandle _handle);
/// Create occlusion query.
///
/// @returns Handle to occlusion query object.
///
/// @attention C99 equivalent is `bgfx_create_occlusion_query`.
///
OcclusionQueryHandle createOcclusionQuery();
/// Destroy occlusion query.
///
/// @param[in] _handle Handle to occlusion query object.
///
/// @attention C99 equivalent is `bgfx_destroy_occlusion_query`.
///
void destroyOcclusionQuery(OcclusionQueryHandle _handle);

View file

@ -639,6 +639,12 @@ BGFX_C_API bgfx_uniform_handle_t bgfx_create_uniform(const char* _name, bgfx_uni
/**/
BGFX_C_API void bgfx_destroy_uniform(bgfx_uniform_handle_t _handle);
/**/
BGFX_C_API bgfx_occlusion_query_handle_t bgfx_create_occlusion_query();
/**/
BGFX_C_API void bgfx_destroy_occlusion_query(bgfx_occlusion_query_handle_t _handle);
/**/
BGFX_C_API void bgfx_set_palette_color(uint8_t _index, const float _rgba[4]);

View file

@ -3984,6 +3984,19 @@ BGFX_C_API void bgfx_destroy_uniform(bgfx_uniform_handle_t _handle)
bgfx::destroyUniform(handle.cpp);
}
BGFX_C_API bgfx_occlusion_query_handle_t bgfx_create_occlusion_query()
{
union { bgfx_occlusion_query_handle_t c; bgfx::OcclusionQueryHandle cpp; } handle;
handle.cpp = bgfx::createOcclusionQuery();
return handle.c;
}
BGFX_C_API void bgfx_destroy_occlusion_query(bgfx_occlusion_query_handle_t _handle)
{
union { bgfx_occlusion_query_handle_t c; bgfx::OcclusionQueryHandle cpp; } handle = { _handle };
bgfx::destroyOcclusionQuery(handle.cpp);
}
BGFX_C_API void bgfx_set_palette_color(uint8_t _index, const float _rgba[4])
{
bgfx::setPaletteColor(_index, _rgba);