Re: [Ffmpeg-php-user] togdimage() not working on BSD
Brought to you by:
tkirby
From: Todd.Kirby <dou...@pa...> - 2005-03-24 06:29:01
|
Scott Larson wrote: > I'm running the following script on a RH Linux 3ES machine with no >problems, however when moving the script to a FreeBSD machine I get this >error: > >[21-Mar-2005 10:58:00] PHP Warning: togdimage(): supplied resource is >not a valid Image resource in /usr/local/www/data-dist/ffmpeg/bar.php on >line 16 > > Here is the script I'm testing with: > ><?php > >header("Content-type: image/jpeg"); > >$file = "qt/video.mov"; > >$movie = new ffmpeg_movie($file); >$total = $movie->getFrameCount(); >$bitrate = $movie->getBitRate(); >$type = $movie->getVideoCodec(); >$id = round($total/2); >$frame = $movie->getFrame($id); >$width = $frame->getWidth($frame); >$height = $frame->getHeight($frame); > > $image = $frame->togdimage(); > imagejpeg($image,'',100); > >?> > > The only underlying difference is the OS. Both machines run PHP >4.3.10, ffmpeg 0.4.9p1, and ffmpeg-php 0.4.3, and in both cases >ffmpeg-php is built as a dynamic extension. An interesting thing to >note is that on the troublesome BSD machine, all the other functions >seem to work. It correctly gets the frame count, bit rate, video codec, >width and height. > > > Hi Scott, togdimage() is the only function that interacts with gd so it's likely a problem with the gd/ffmpeg-php integration (which is pure voodoo thanks to the way gd is bundled into the php sources). Which version of gd are you using? Is gd built into php or as an extension? BTW: I work at a large media company in Burbank and know some folks who might be interested in WiredrivePro/Hub. Are these apps web based? -Todd |