From 4a1ce71fd9b13255064dcdbea8a59ae98303bf22 Mon Sep 17 00:00:00 2001 From: Lukas Toenne Date: Thu, 5 Sep 2013 10:45:19 +0000 Subject: Extend mode option for MemoryBuffer reading in compositor. This will allow proper interpolation of pixel values when using wrapping in the Translate node. Implemented in inline functions, so won't cause overhead if constant values are passed (as happens with most calls using the default argument). --- source/blender/compositor/operations/COM_GlareStreaksOperation.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'source/blender/compositor/operations/COM_GlareStreaksOperation.cpp') diff --git a/source/blender/compositor/operations/COM_GlareStreaksOperation.cpp b/source/blender/compositor/operations/COM_GlareStreaksOperation.cpp index 60d37fb8145..5644ff30ef3 100644 --- a/source/blender/compositor/operations/COM_GlareStreaksOperation.cpp +++ b/source/blender/compositor/operations/COM_GlareStreaksOperation.cpp @@ -54,9 +54,9 @@ void GlareStreaksOperation::generateGlare(float *data, MemoryBuffer *inputTile, // first pass no offset, always same for every pass, exact copy, // otherwise results in uneven brightness, only need once if (n == 0) tsrc->read(c1, x, y); else c1[0] = c1[1] = c1[2] = 0; - tsrc->readCubic(c2, x + vxp, y + vyp); - tsrc->readCubic(c3, x + vxp * 2.f, y + vyp * 2.f); - tsrc->readCubic(c4, x + vxp * 3.f, y + vyp * 3.f); + tsrc->readBilinear(c2, x + vxp, y + vyp); + tsrc->readBilinear(c3, x + vxp * 2.f, y + vyp * 2.f); + tsrc->readBilinear(c4, x + vxp * 3.f, y + vyp * 3.f); // modulate color to look vaguely similar to a color spectrum c2[1] *= cmo; c2[2] *= cmo; -- cgit v1.2.3