Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/compositor/operations/COM_ImageOperation.cpp')
-rw-r--r--source/blender/compositor/operations/COM_ImageOperation.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/source/blender/compositor/operations/COM_ImageOperation.cpp b/source/blender/compositor/operations/COM_ImageOperation.cpp
index 2733c483146..ff0ffe27b42 100644
--- a/source/blender/compositor/operations/COM_ImageOperation.cpp
+++ b/source/blender/compositor/operations/COM_ImageOperation.cpp
@@ -119,10 +119,10 @@ static void sampleImageAtLocation(ImBuf *ibuf, float x, float y, PixelSampler sa
nearest_interpolation_color(ibuf, NULL, color, x, y);
break;
case COM_PS_BILINEAR:
- bilinear_interpolation_color(ibuf, NULL, color, x, y);
+ bilinear_interpolation_color(ibuf, NULL, color, x - 0.5f, y - 0.5f);
break;
case COM_PS_BICUBIC:
- bicubic_interpolation_color(ibuf, NULL, color, x, y);
+ bicubic_interpolation_color(ibuf, NULL, color, x - 0.5f, y - 0.5f);
break;
}
}
@@ -133,10 +133,10 @@ static void sampleImageAtLocation(ImBuf *ibuf, float x, float y, PixelSampler sa
nearest_interpolation_color(ibuf, byte_color, NULL, x, y);
break;
case COM_PS_BILINEAR:
- bilinear_interpolation_color(ibuf, byte_color, NULL, x, y);
+ bilinear_interpolation_color(ibuf, byte_color, NULL, x - 0.5f, y - 0.5f);
break;
case COM_PS_BICUBIC:
- bicubic_interpolation_color(ibuf, byte_color, NULL, x, y);
+ bicubic_interpolation_color(ibuf, byte_color, NULL, x - 0.5f, y - 0.5f);
break;
}
rgba_uchar_to_float(color, byte_color);