diff options
Diffstat (limited to 'intern/cycles/kernel/kernel_compat_cpu.h')
-rw-r--r-- | intern/cycles/kernel/kernel_compat_cpu.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/intern/cycles/kernel/kernel_compat_cpu.h b/intern/cycles/kernel/kernel_compat_cpu.h index 45f653a686c..01bb78e8e1c 100644 --- a/intern/cycles/kernel/kernel_compat_cpu.h +++ b/intern/cycles/kernel/kernel_compat_cpu.h @@ -112,8 +112,8 @@ template<typename T> struct texture_image { return make_float4(0.0f, 0.0f, 0.0f, 0.0f); int ix, iy, nix, niy; - float tx = frac(x*width, &ix); - float ty = frac(y*height, &iy); + float tx = frac(x*width - 0.5f, &ix); + float ty = frac(y*height - 0.5f, &iy); if(periodic) { ix = wrap_periodic(ix, width); |