///////////////////////////////////////////////////////
| 888 | |
| 889 | //////////////////////////////////////////////////////////// |
| 890 | void RenderTarget::drawPrimitives(PrimitiveType type, std::size_t firstVertex, std::size_t vertexCount) |
| 891 | { |
| 892 | // Find the OpenGL primitive type |
| 893 | static constexpr priv::EnumArray<PrimitiveType, GLenum, 6> modes = |
| 894 | {GL_POINTS, GL_LINES, GL_LINE_STRIP, GL_TRIANGLES, GL_TRIANGLE_STRIP, GL_TRIANGLE_FAN}; |
| 895 | const GLenum mode = modes[type]; |
| 896 | |
| 897 | // Draw the primitives |
| 898 | glCheck(glDrawArrays(mode, static_cast<GLint>(firstVertex), static_cast<GLsizei>(vertexCount))); |
| 899 | } |
| 900 | |
| 901 | |
| 902 | //////////////////////////////////////////////////////////// |
nothing calls this directly
no outgoing calls
no test coverage detected