Changeset 12057
- Timestamp:
- 2007/04/02 18:22:47 (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/dev/data/lib/gdthumb.php
r12056 r12057 137 137 $imageresize($dst_im, $src_im, 0, 0, 0, 0, $re_size[0], $re_size[1], $size[0], $size[1]); 138 138 139 if(function_exists("imagegif")) { 140 139 if(function_exists("imagegif")) { 141 140 // ²èÁü½ÐÎÏ 142 141 if($header){ … … 145 144 return ""; 146 145 }else{ 147 $dst_file = $dst_file . ".gif"; 148 imagegif($dst_im, $dst_file); 149 } 150 146 $dst_file = $dst_file . ".gif"; 147 if($re_size[0] == $size[0] && $re_size[1] == $size[1]) { 148 // ¥µ¥¤¥º¤¬Æ±¤¸¾ì¹ç¤Ë¤Ï¡¢¤½¤Î¤Þ¤Þ¥³¥Ô¡¼¤¹¤ë¡£(²è¼ÁÎô²½¤òËɤ°¡Ë 149 copy($path, $dst_file); 150 } else { 151 imagegif($dst_im, $dst_file); 152 } 153 } 151 154 imagedestroy($src_im); 152 155 imagedestroy($dst_im); … … 158 161 return ""; 159 162 }else{ 160 $dst_file = $dst_file . ".png"; 161 imagepng($dst_im, $dst_file); 163 $dst_file = $dst_file . ".png"; 164 if($re_size[0] == $size[0] && $re_size[1] == $size[1]) { 165 // ¥µ¥¤¥º¤¬Æ±¤¸¾ì¹ç¤Ë¤Ï¡¢¤½¤Î¤Þ¤Þ¥³¥Ô¡¼¤¹¤ë¡£(²è¼ÁÎô²½¤òËɤ°¡Ë 166 copy($path, $dst_file); 167 } else { 168 imagepng($dst_im, $dst_file); 169 } 162 170 } 163 171 imagedestroy($src_im); … … 207 215 208 216 if($re_size[0] == $size[0] && $re_size[1] == $size[1]) { 209 // ¥µ¥¤¥º¤¬Æ±¤¸¾ì¹ç¤Ë¤Ï¡¢¤½¤Î¤Þ¤Þ¥³¥Ô¡¼¤¹¤ë¡£ 217 // ¥µ¥¤¥º¤¬Æ±¤¸¾ì¹ç¤Ë¤Ï¡¢¤½¤Î¤Þ¤Þ¥³¥Ô¡¼¤¹¤ë¡£(²è¼ÁÎô²½¤òËɤ°¡Ë 210 218 copy($path, $dst_file); 211 219 } else { … … 247 255 }else{ 248 256 $dst_file = $dst_file . ".png"; 249 imagepng($dst_im, $dst_file); 257 if($re_size[0] == $size[0] && $re_size[1] == $size[1]) { 258 // ¥µ¥¤¥º¤¬Æ±¤¸¾ì¹ç¤Ë¤Ï¡¢¤½¤Î¤Þ¤Þ¥³¥Ô¡¼¤¹¤ë¡£(²è¼ÁÎô²½¤òËɤ°¡Ë 259 copy($path, $dst_file); 260 } else { 261 imagepng($dst_im, $dst_file); 262 } 250 263 } 251 264 imagedestroy($src_im);
Note: See TracChangeset
for help on using the changeset viewer.