Fix/tweak for cycles border render, it wasn't generating the exact same samples
authorBrecht Van Lommel <brechtvanlommel@pandora.be>
Mon, 16 Apr 2012 09:52:25 +0000 (09:52 +0000)
committerBrecht Van Lommel <brechtvanlommel@pandora.be>
Mon, 16 Apr 2012 09:52:25 +0000 (09:52 +0000)
when rendering a subset instead of the whole, mostly useful for debugging.

intern/cycles/render/buffers.cpp

index 62a322b3a0f5cff46c77d8a1f7ab446f99bcaaa7..bda20a8ab9d6ab3cd084c07b56ceec8794566574 100644 (file)
@@ -119,7 +119,7 @@ void RenderBuffers::reset(Device *device, BufferParams& params_)
        
        for(x=0; x<width; x++)
                for(y=0; y<height; y++)
-                       init_state[x + y*width] = hash_int_2d(x, y);
+                       init_state[x + y*width] = hash_int_2d(params.full_x+x, params.full_y+y);
 
        device->mem_alloc(rng_state, MEM_READ_WRITE);
        device->mem_copy_to(rng_state);