mirror of
https://github.com/bkaradzic/bgfx.git
synced 2026-02-17 20:52:36 +01:00
Adding geometry instancing support.
This commit is contained in:
10
src/bgfx.cpp
10
src/bgfx.cpp
@@ -845,6 +845,11 @@ namespace bgfx
|
||||
return s_ctx.allocTransientVertexBuffer(_num, _decl);
|
||||
}
|
||||
|
||||
const InstanceDataBuffer* allocInstanceDataBuffer(uint16_t _num, uint16_t _stride)
|
||||
{
|
||||
return s_ctx.allocInstanceDataBuffer(_num, _stride);
|
||||
}
|
||||
|
||||
VertexShaderHandle createVertexShader(const Memory* _mem)
|
||||
{
|
||||
return s_ctx.createVertexShader(_mem);
|
||||
@@ -1021,6 +1026,11 @@ namespace bgfx
|
||||
s_ctx.m_submit->setVertexBuffer(_vb);
|
||||
}
|
||||
|
||||
void setInstanceDataBuffer(const InstanceDataBuffer* _idb)
|
||||
{
|
||||
s_ctx.m_submit->setInstanceDataBuffer(_idb);
|
||||
}
|
||||
|
||||
void setMaterial(MaterialHandle _handle)
|
||||
{
|
||||
s_ctx.m_submit->setMaterial(_handle);
|
||||
|
||||
Reference in New Issue
Block a user