[Swfed-svn] swfed-svn [416] gif 入れ替えのテストスクリプト

Back to archive index

svnno****@sourc***** svnno****@sourc*****
2011年 3月 11日 (金) 10:01:51 JST


Revision: 416
          http://sourceforge.jp/projects/swfed/svn/view?view=rev&revision=416
Author:   yoya
Date:     2011-03-11 10:01:51 +0900 (Fri, 11 Mar 2011)

Log Message:
-----------
gif 入れ替えのテストスクリプト

Added Paths:
-----------
    trunk/src/tests/gif.phpt
    trunk/src/tests/inasahama.gif


-------------- next part --------------
Added: trunk/src/tests/gif.phpt
===================================================================
--- trunk/src/tests/gif.phpt	                        (rev 0)
+++ trunk/src/tests/gif.phpt	2011-03-11 01:01:51 UTC (rev 416)
@@ -0,0 +1,25 @@
+--TEST--
+replaceJpegData test;
+--FILE--
+<?php
+
+$swf_filename = 'tests/saitama.swf';
+$gif_filename = 'tests/inasahama.gif';
+
+$swfdata = file_get_contents($swf_filename);
+$obj = new SWFEditor();
+
+// $obj->setShapeAdjustMode(SWFEditor::SHAPE_BITMAP_RECT_RESIZE);
+// $obj->setShapeAdjustMode(SWFEditor::SHAPE_BITMAP_MATRIX_RESCALE);
+$obj->setShapeAdjustMode(SWFEditor::SHAPE_BITMAP_TYPE_TILLED);
+
+$obj->input($swfdata);
+$image_id = 1;
+$gifdata = file_get_contents($gif_filename);
+$obj->replaceGIFData($image_id, $gifdata);
+echo md5($obj->output())."\n";
+?>
+===DONE===
+--EXPECTF--
+41b00e8a7c684685ebe1bee5dd0e61dc
+===DONE===

Added: trunk/src/tests/inasahama.gif
===================================================================
(Binary files differ)


Property changes on: trunk/src/tests/inasahama.gif
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream



Swfed-svn メーリングリストの案内
Back to archive index