コード例 #1
0
ファイル: test01.php プロジェクト: mgorny/libming
#!/usr/bin/php -c.
<?php 
$m = new SWFMovie(9);
ming_setscale(1.0);
$m->setFrames(10);
/*Unknown block type 69*/
/* SWF_SHOWFRAME */
$m->nextFrame();
/* end of frame 1 */
/* SWF_SHOWFRAME */
$m->nextFrame();
/* end of frame 2 */
/* SWF_SHOWFRAME */
$m->nextFrame();
/* end of frame 3 */
/* SWF_SHOWFRAME */
$m->nextFrame();
/* end of frame 4 */
/* SWF_SHOWFRAME */
$m->nextFrame();
/* end of frame 5 */
/* SWF_SHOWFRAME */
$m->nextFrame();
/* end of frame 6 */
/* SWF_SHOWFRAME */
$m->nextFrame();
/* end of frame 7 */
/* SWF_SHOWFRAME */
$m->nextFrame();
/* end of frame 8 */
/* SWF_SHOWFRAME */
コード例 #2
0
ファイル: streamvideo.php プロジェクト: Videofy/php-codes
<?php

header('Content-type: application/x-shockwave-flash');
$mp3file = "sample.mp3";
$mp3Stream = fopen($mp3file, 'rb');
$mp3Content = fread($mp3Stream, filesize($mp3file));
fclose($mp3Stream);
$mp3length = 8.5;
$rate = 12.0;
$mp3 = new SWFMovie();
$mp3->setRate($rate);
$mp3->streamMp3($mp3Content);
$mp3->setFrames($mp3length * $rate);
$mp3->output();
コード例 #3
0
ファイル: test02.php プロジェクト: mgorny/libming
#!/usr/bin/php -c.
<?php 
$m = new SWFMovie();
$m->setFrames(2);
/* SWF_SETBACKGROUNDCOLOR */
$m->setBackground(0xff, 0xff, 0xff);
/* SWF_SHOWFRAME */
$m->nextFrame();
/* end of frame 1 */
/* SWF_DOACTION */
$m->add(new SWFAction("var a = 1;\n"));
/* SWF_SHOWFRAME */
$m->nextFrame();
/* end of frame 2 */
/* SWF_END */
$m->save("test02.swf");