diff --git a/modules/imagecache_effects/imageapi.inc b/modules/imagecache_effects/imageapi.inc index 82742d9..7dab9e2 100644 --- a/modules/imagecache_effects/imageapi.inc +++ b/modules/imagecache_effects/imageapi.inc @@ -146,7 +146,7 @@ function imageapi_gd_image_reflection(&$image, $options = array()) { case 'bottom': $steps = min($options['size'], $image->info['height']); for ($i = 0, $opacity = 50; $i < $steps; ++$i, $opacity = ceil(((($steps - $i) / $steps) * 100) / 2)) { - imagecopymerge($background, $image->res, 0, $image->info['height'] + $i, 0, $image->info['height'] - $i, $image->info['width'], 1, $opacity); + imagecopymerge($background, $image->res, 0, $image->info['height'] + $i, 0, $image->info['height'] - $i - 1, $image->info['width'], 1, $opacity); } $return = true; break; @@ -160,7 +160,7 @@ function imageapi_gd_image_reflection(&$image, $options = array()) { case 'right': $steps = min($options['size'], $image->info['height']); for ($i = 0, $opacity = 50; $i < $steps; ++$i, $opacity = ceil(((($steps - $i) / $steps) * 100) / 2)) { - imagecopymerge($background, $image->res, $image->info['width'] + $i, 0, $image->info['width'] - $i, 0, 1, $image->info['height'], $opacity); + imagecopymerge($background, $image->res, $image->info['width'] + $i, 0, $image->info['width'] - $i - 1, 0, 1, $image->info['height'], $opacity); } $return = true; break;