Index: /temp/trunk/html/test/kakinaka/resize_image.php
===================================================================
--- /temp/trunk/html/test/kakinaka/resize_image.php	(revision 9184)
+++ /temp/trunk/html/test/kakinaka/resize_image.php	(revision 9187)
@@ -10,5 +10,5 @@
 
 //sfprintr(pathinfo($file));
-$path = $objImage->saveResizeImage($file, 0.5, true);
+$path = $objImage->saveResizeImage($file, 100, 100, true);
 
 //sfprintr($path);
Index: /temp/trunk/data/class/SC_Image.php
===================================================================
--- /temp/trunk/data/class/SC_Image.php	(revision 9186)
+++ /temp/trunk/data/class/SC_Image.php	(revision 9187)
@@ -53,14 +53,21 @@
 
 	// ³ÈÂçÎ¨¤ò»ØÄê¤·¤Æ²èÁüÊÝÂ¸
-	function saveResizeImage($file, $zip_scale = 1, $header = false) {
+	function saveResizeImage($file, $to_w = 1, $to_h = 1, $header = false) {
 		// ¥Ç¥£¥ì¥¯¥È¥ê¼èÆÀ
 		$dir = dirname($file);
 		
 		// ¸µ²èÁü¥µ¥¤¥º¤ò¼èÆÀ
-		list($src_w, $src_h) = getimagesize($file);
-	
+		list($from_w, $from_h) = getimagesize($file);
+		
+		// Éý¤Î½Ì¾®Î¨
+		($to_w < $from_w) ? $wscale = $to_w / $from_w :	$wscale = 1;
+		// ¹â¤µ¤Î½Ì¾®Î¨
+		($to_h < $from_h) ? $hscale = $to_h / $from_h :	$hscale = 1;
+		// ½Ì¾®Î¨¤Ï¾®¤µ¤¤¤Û¤¦¤Ë¤¢¤ï¤»¤ë
+		($wscale < $hscale) ? $scale = $wscale : $scale = $hscale;
+
 		// °µ½ÌÎ¨»ØÄê
-		$zip_width = $src_w * $zip_scale;
-		$zip_height = $src_h * $zip_scale;
+		$zip_width = $from_w * $scale;
+		$zip_height = $from_h * $scale;
 		
 		// ¥Õ¥¡¥¤¥ë¤Î³ÈÄ¥»Ò¼èÆÀ	
@@ -85,5 +92,5 @@
 					// °µ½ÌÀè²èÁü
 					$dst_im = imagecreatetruecolor($zip_width, $zip_height);	
-					imagecopyresampled($dst_im, $src_im, 0, 0, 0,0, $zip_width, $zip_height, $src_w, $src_h);
+					imagecopyresampled($dst_im, $src_im, 0, 0, 0,0, $zip_width, $zip_height, $from_w, $from_h);
 					
 					// ²èÁü½ÐÎÏ
@@ -102,5 +109,5 @@
 					// °µ½ÌÀè²èÁü
 					$dst_im = imagecreatetruecolor($zip_width, $zip_height);	
-					imagecopyresampled($dst_im, $src_im, 0, 0, 0,0, $zip_width, $zip_height, $src_w, $src_h);
+					imagecopyresampled($dst_im, $src_im, 0, 0, 0,0, $zip_width, $zip_height, $from_w, $from_h);
 					
 					// ²èÁü½ÐÎÏ
@@ -115,5 +122,5 @@
 					// °µ½ÌÀè²èÁü
 					$dst_im = imagecreatetruecolor($zip_width, $zip_height);	
-					imagecopyresampled($dst_im, $src_im, 0, 0, 0,0, $zip_width, $zip_height, $src_w, $src_h);
+					imagecopyresampled($dst_im, $src_im, 0, 0, 0,0, $zip_width, $zip_height, $from_w, $from_h);
 
 					// ²èÁü½ÐÎÏ
