diff options
author | bunnei <bunneidev@gmail.com> | 2018-04-13 20:18:37 +0200 |
---|---|---|
committer | bunnei <bunneidev@gmail.com> | 2018-04-17 03:10:15 +0200 |
commit | 1a1af3fda354f3e81cace3f3f64138bcea1995c6 (patch) | |
tree | a1bf934fac2579ae296c6ff55d37d94fd37650ca /src/video_core/renderer_opengl/maxwell_to_gl.h | |
parent | Merge pull request #338 from bunnei/unrequire-shared-font (diff) | |
download | yuzu-1a1af3fda354f3e81cace3f3f64138bcea1995c6.tar yuzu-1a1af3fda354f3e81cace3f3f64138bcea1995c6.tar.gz yuzu-1a1af3fda354f3e81cace3f3f64138bcea1995c6.tar.bz2 yuzu-1a1af3fda354f3e81cace3f3f64138bcea1995c6.tar.lz yuzu-1a1af3fda354f3e81cace3f3f64138bcea1995c6.tar.xz yuzu-1a1af3fda354f3e81cace3f3f64138bcea1995c6.tar.zst yuzu-1a1af3fda354f3e81cace3f3f64138bcea1995c6.zip |
Diffstat (limited to 'src/video_core/renderer_opengl/maxwell_to_gl.h')
-rw-r--r-- | src/video_core/renderer_opengl/maxwell_to_gl.h | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/src/video_core/renderer_opengl/maxwell_to_gl.h b/src/video_core/renderer_opengl/maxwell_to_gl.h index 7909dcfc3..68bb77b4d 100644 --- a/src/video_core/renderer_opengl/maxwell_to_gl.h +++ b/src/video_core/renderer_opengl/maxwell_to_gl.h @@ -45,6 +45,20 @@ inline GLenum VertexType(Maxwell::VertexAttribute attrib) { return {}; } +inline GLenum IndexFormat(Maxwell::IndexFormat index_format) { + switch (index_format) { + case Maxwell::IndexFormat::UnsignedByte: + return GL_UNSIGNED_BYTE; + case Maxwell::IndexFormat::UnsignedShort: + return GL_UNSIGNED_SHORT; + case Maxwell::IndexFormat::UnsignedInt: + return GL_UNSIGNED_INT; + } + LOG_CRITICAL(Render_OpenGL, "Unimplemented index_format=%d", index_format); + UNREACHABLE(); + return {}; +} + inline GLenum PrimitiveTopology(Maxwell::PrimitiveTopology topology) { switch (topology) { case Maxwell::PrimitiveTopology::Triangles: @@ -52,7 +66,7 @@ inline GLenum PrimitiveTopology(Maxwell::PrimitiveTopology topology) { case Maxwell::PrimitiveTopology::TriangleStrip: return GL_TRIANGLE_STRIP; } - LOG_CRITICAL(Render_OpenGL, "Unimplemented primitive topology=%d", topology); + LOG_CRITICAL(Render_OpenGL, "Unimplemented topology=%d", topology); UNREACHABLE(); return {}; } |