| 66 | } |
| 67 | |
| 68 | void GuiBuffer::submit(u32 num_vertices, u32 num_indices, const Matrix4x4 &world, ShaderData &shader, u8 view, u32 depth) |
| 69 | { |
| 70 | bgfx::setVertexBuffer(0, &_vertex_buffer, _num_vertices, num_vertices); |
| 71 | bgfx::setIndexBuffer(&_index_buffer, _num_indices, num_indices); |
| 72 | bgfx::setTransform(to_float_ptr(world)); |
| 73 | |
| 74 | bgfx::setState(shader.state); |
| 75 | bgfx::submit(view, shader.program, depth); |
| 76 | |
| 77 | _num_vertices += num_vertices; |
| 78 | _num_indices += num_indices; |
| 79 | } |
| 80 | |
| 81 | void GuiBuffer::submit_with_material(u32 num_vertices, u32 num_indices, const Matrix4x4 &world, u8 view, u32 depth, Material *material) |
| 82 | { |
no test coverage detected