Explorar o código

Quads that don't read the viewport should not begin the pingpong chain. Fixes #167.

Lasse Öörni %!s(int64=12) %!d(string=hai) anos
pai
achega
0610520768
Modificáronse 1 ficheiros con 2 adicións e 2 borrados
  1. 2 2
      Source/Engine/Graphics/View.cpp

+ 2 - 2
Source/Engine/Graphics/View.cpp

@@ -1657,9 +1657,9 @@ bool View::CheckViewportWrite(const RenderPathCommand& command)
 
 bool View::CheckPingpong(unsigned index)
 {
-    // Current command must be a viewport-writing quad to begin the pingpong chain
+    // Current command must be a viewport-reading & writing quad to begin the pingpong chain
     RenderPathCommand& current = renderPath_->commands_[index];
-    if (current.type_ != CMD_QUAD || !CheckViewportWrite(current))
+    if (current.type_ != CMD_QUAD || !CheckViewportRead(current) || !CheckViewportWrite(current))
         return false;
 
     // If there are commands other than quads that target the viewport, we must keep rendering to the final target and resolving