From 44d3fd6d5bcfe5868ca9d708ea8be8c701323dfc Mon Sep 17 00:00:00 2001 From: Thomas Harte Date: Wed, 16 Nov 2016 11:22:12 +0800 Subject: [PATCH] Fixed mistimed reset of the target output line. Now all that's left is occasional noise. --- Outputs/CRT/Internals/CRTOpenGL.cpp | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/Outputs/CRT/Internals/CRTOpenGL.cpp b/Outputs/CRT/Internals/CRTOpenGL.cpp index cc9497f26..e9e801896 100644 --- a/Outputs/CRT/Internals/CRTOpenGL.cpp +++ b/Outputs/CRT/Internals/CRTOpenGL.cpp @@ -239,6 +239,9 @@ void OpenGLOutputBuilder::draw_frame(unsigned int output_width, unsigned int out _buffer_builder->get_image_pointer()); } + // buffer usage restart from 0 for the next time around + _composite_src_output_y = 0; + // data having been grabbed, allow the machine to continue _output_mutex->unlock(); @@ -285,14 +288,10 @@ void OpenGLOutputBuilder::draw_frame(unsigned int output_width, unsigned int out active_pipeline++; } - } - _composite_src_output_y = 0; - // transfer to framebuffer - framebuffer->bind_framebuffer(); + // transfer to framebuffer + framebuffer->bind_framebuffer(); - if(submitted_output_data) - { glEnable(GL_BLEND); // Ensure we're back on the output framebuffer, drawing from the output array buffer