diff options
author | ReinUsesLisp <reinuseslisp@airmail.cc> | 2019-05-28 00:41:19 +0200 |
---|---|---|
committer | ReinUsesLisp <reinuseslisp@airmail.cc> | 2019-07-06 05:37:55 +0200 |
commit | a6d2f52fc32295c73f41b86ab1b5e85d06afd5b0 (patch) | |
tree | 4d6c96182a406b607597bb43693a1a2cca1678ea /src/video_core/renderer_opengl/gl_rasterizer.cpp | |
parent | gl_rasterizer: Make DrawParameters rasterizer instance const (diff) | |
download | yuzu-a6d2f52fc32295c73f41b86ab1b5e85d06afd5b0.tar yuzu-a6d2f52fc32295c73f41b86ab1b5e85d06afd5b0.tar.gz yuzu-a6d2f52fc32295c73f41b86ab1b5e85d06afd5b0.tar.bz2 yuzu-a6d2f52fc32295c73f41b86ab1b5e85d06afd5b0.tar.lz yuzu-a6d2f52fc32295c73f41b86ab1b5e85d06afd5b0.tar.xz yuzu-a6d2f52fc32295c73f41b86ab1b5e85d06afd5b0.tar.zst yuzu-a6d2f52fc32295c73f41b86ab1b5e85d06afd5b0.zip |
Diffstat (limited to '')
-rw-r--r-- | src/video_core/renderer_opengl/gl_rasterizer.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/video_core/renderer_opengl/gl_rasterizer.cpp b/src/video_core/renderer_opengl/gl_rasterizer.cpp index 6cab48329..bfc3c4df9 100644 --- a/src/video_core/renderer_opengl/gl_rasterizer.cpp +++ b/src/video_core/renderer_opengl/gl_rasterizer.cpp @@ -650,12 +650,17 @@ void RasterizerOpenGL::DrawArrays() { gpu.dirty_flags.vertex_array.set(); } + // Prepare vertex array format. const GLuint vertex_array = SetupVertexFormat(); + // Upload vertex and index data. SetupVertexBuffer(vertex_array); const GLintptr index_buffer_offset = SetupIndexBuffer(); + // Setup draw parameters. It will automatically choose what glDraw* method to use. const DrawParameters params = SetupDraw(index_buffer_offset); + + // Setup shaders and their used resources. texture_cache.GuardSamplers(true); SetupShaders(params.primitive_mode); texture_cache.GuardSamplers(false); |