Witam
Oosiadam taki skrypt
<?php
/*
* This test script is not part of the automatic regression tests. It serves
* as a simple manual test script and an example of the syntax for calling
* the ffmpeg-php functions
*
* To run it from the command line type 'php -q ffmpeg_test.php 'or from a
* browser * copy this file into your web root and point your browser at it.
*/
$extension = "ffmpeg";
$extension_soname = $extension . "." . PHP_SHLIB_SUFFIX;
$extension_fullname = PHP_EXTENSION_DIR . "/" . $extension_soname;
// load extension
dl($extension_soname) or
die("Can't load extension $extension_fullnamen"); }
if (php_sapi_name() != 'cgi') {
}
printf("ffmpeg-php version string: %sn", FFMPEG_PHP_VERSION_STRING
); printf("libavcodec build number: %dn", LIBAVCODEC_BUILD_NUMBER
); printf("libavcodec version number: %dn", LIBAVCODEC_VERSION_NUMBER
); printf("libavcodec build number: %dn", LIBAVCODEC_BUILD_NUMBER
);
$name = 'test';
$fpatch = '/home/bastek/public_html/test_media/test.avi';
$movie = '/home/bastek/public_html/test_media/test.avi';
$mov = new ffmpeg_movie($movie);
function video_to_frame($fpath,$name,$mov,$chnl)
{
$frcount=$mov->getFrameCount()-1;
$try = 1;
$fc = 1;
while(1)
{
$ff_frame= $mov->getFrame($p);
if($ff_frame==true)
{
$gd_image = $ff_frame->toGDImage();
$ff='thumbs'."/".$name.".jpg";
imagejpeg($gd_image, $ff);
$fd='thumbs'."/".$fc."_".$name.".jpg";
createThumb($ff,$fd,'55','55');
$fc++;
}
$try++;
if($try>10 || $fc==4)
break;
}
}
video_to_frame($fpath,$name,$mov,$chnl);
?>
Wszystko dziala ajnie tylke ze gdy wstawie link odnoszacy sie do pliku z zew serwera (google, youtube) to skrypcik odmawia polsuszenstwa piszec ze niemoze otworzyc pliku..
I tu pytanie: czy da sie przerobic ten sktypt tak by robil thumby filmow flash z serwisow typu google?