diff options
author | bunnei <bunneidev@gmail.com> | 2020-05-03 08:43:18 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-05-03 08:43:18 +0200 |
commit | 2aff0b473338655fba08f83c6a4c0af808b6d4a9 (patch) | |
tree | aae207eac2560d76f835a0eba3511b36fcf4a571 /src/video_core/renderer_opengl/gl_rasterizer.cpp | |
parent | Merge pull request #3861 from lat9nq/ci-enable-vulkan (diff) | |
parent | {maxwell_3d,buffer_cache}: Implement memory barriers using 3D registers (diff) | |
download | yuzu-2aff0b473338655fba08f83c6a4c0af808b6d4a9.tar yuzu-2aff0b473338655fba08f83c6a4c0af808b6d4a9.tar.gz yuzu-2aff0b473338655fba08f83c6a4c0af808b6d4a9.tar.bz2 yuzu-2aff0b473338655fba08f83c6a4c0af808b6d4a9.tar.lz yuzu-2aff0b473338655fba08f83c6a4c0af808b6d4a9.tar.xz yuzu-2aff0b473338655fba08f83c6a4c0af808b6d4a9.tar.zst yuzu-2aff0b473338655fba08f83c6a4c0af808b6d4a9.zip |
Diffstat (limited to 'src/video_core/renderer_opengl/gl_rasterizer.cpp')
-rw-r--r-- | src/video_core/renderer_opengl/gl_rasterizer.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/video_core/renderer_opengl/gl_rasterizer.cpp b/src/video_core/renderer_opengl/gl_rasterizer.cpp index 725b4c32d..8b3b3ce92 100644 --- a/src/video_core/renderer_opengl/gl_rasterizer.cpp +++ b/src/video_core/renderer_opengl/gl_rasterizer.cpp @@ -746,6 +746,17 @@ void RasterizerOpenGL::FlushAndInvalidateRegion(VAddr addr, u64 size) { InvalidateRegion(addr, size); } +void RasterizerOpenGL::WaitForIdle() { + // Place a barrier on everything that is not framebuffer related. + // This is related to another flag that is not currently implemented. + glMemoryBarrier(GL_VERTEX_ATTRIB_ARRAY_BARRIER_BIT | GL_ELEMENT_ARRAY_BARRIER_BIT | + GL_UNIFORM_BARRIER_BIT | GL_TEXTURE_FETCH_BARRIER_BIT | + GL_SHADER_IMAGE_ACCESS_BARRIER_BIT | GL_COMMAND_BARRIER_BIT | + GL_PIXEL_BUFFER_BARRIER_BIT | GL_TEXTURE_UPDATE_BARRIER_BIT | + GL_BUFFER_UPDATE_BARRIER_BIT | GL_TRANSFORM_FEEDBACK_BARRIER_BIT | + GL_SHADER_STORAGE_BARRIER_BIT | GL_QUERY_BUFFER_BARRIER_BIT); +} + void RasterizerOpenGL::FlushCommands() { // Only flush when we have commands queued to OpenGL. if (num_queued_commands == 0) { |