Revision: 43493
          
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=43493
Author:   jbakker
Date:     2012-01-18 15:08:37 +0000 (Wed, 18 Jan 2012)
Log Message:
-----------
TileBranch
 * resolution propagation patch

Resolution were not always propagated between read/write buffers. This will be 
important when implementing Buffer caches

Jeroen Bakker
 - At Mind - 

Modified Paths:
--------------
    
branches/tile/source/blender/compositor/operations/COM_ReadBufferOperation.cpp

Modified: 
branches/tile/source/blender/compositor/operations/COM_ReadBufferOperation.cpp
===================================================================
--- 
branches/tile/source/blender/compositor/operations/COM_ReadBufferOperation.cpp  
    2012-01-18 14:52:47 UTC (rev 43492)
+++ 
branches/tile/source/blender/compositor/operations/COM_ReadBufferOperation.cpp  
    2012-01-18 15:08:37 UTC (rev 43493)
@@ -35,21 +35,24 @@
 }
 
 void ReadBufferOperation::determineResolution(unsigned int resolution[], 
unsigned int preferredResolution[]) {
-    if (this->memoryProxy != NULL) {
-        
memoryProxy->getWriteBufferOperation()->determineResolution(resolution, 
preferredResolution);
+       if (this->memoryProxy != NULL) {
+               WriteBufferOperation * operation = 
memoryProxy->getWriteBufferOperation();
+               operation->determineResolution(resolution, preferredResolution);
+               operation->setResolution(resolution);
+
                /// @todo: may not occur!, but does with blur node
                if (memoryProxy->getExecutor()) 
memoryProxy->getExecutor()->setResolution(resolution);
-    }
+       }
 }
 void ReadBufferOperation::executePixel(float* color, float x, float y, 
MemoryBuffer *inputBuffers[]) {
-    MemoryBuffer *inputBuffer = inputBuffers[this->offset];
+       MemoryBuffer *inputBuffer = inputBuffers[this->offset];
        if (inputBuffer) {
-        if (readmode == COM_RM_NORMAL) {
-            inputBuffer->read(color, x, y);
-        } else {
-            inputBuffer->readCubic(color, x, y);
-        }
-    }
+               if (readmode == COM_RM_NORMAL) {
+                       inputBuffer->read(color, x, y);
+               } else {
+                       inputBuffer->readCubic(color, x, y);
+               }
+       }
 }
 
 void ReadBufferOperation::executePixel(float *color, float x, float y, float 
dx, float dy, MemoryBuffer *inputBuffers[]) {

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to