Make sure imageantialias exists. Props rob1n and jeppe. fixes #3939

git-svn-id: https://develop.svn.wordpress.org/trunk@5016 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren 2007-03-10 05:26:28 +00:00
parent e57eea2390
commit 9768611dc1

View File

@ -2087,7 +2087,9 @@ function wp_crop_image( $src_file, $src_x, $src_y, $src_w, $src_h, $dst_w, $dst_
$src_h -= $src_y;
}
imageantialias( $dst, true );
if (function_exists('imageantialias'))
imageantialias( $dst, true );
imagecopyresampled( $dst, $src, 0, 0, $src_x, $src_y, $dst_w, $dst_h, $src_w, $src_h );
if ( !$dst_file )