FFMPEG installation for Fedora11 and useful information to dive in video streaming using PHP:
1. Open the command prompt (terminal) window
2. Run the Su command if not log in as admin (root)
I. Su (Enter)
II. Enter root password
3. Run the command: yum install ffmpeg ffmpeg-devel
4. To check what audio/video formats are supported
I. Run the command: ffmpeg -formats > ffmpeg-format.txt
II. Open the ffmpeg-formats.txt to see the ooutput
D means decode
E means encode
V means video
A means audio
T = Truncated
5. Install FFMPEG-PHP Extension
I. FFmpeg-php is a very good extension and wrapper for PHP which can pull useful information about video through API interface. Inorder to install it you will need to download the source file and then compile and install extension in your server. You can download the source tarball : http://ffmpeg-php.sourceforge.net/
II. tar -xjf ffmpeg-php-X.x.x.tbz2
III. cd ffmpeg-php-X.x.x/
IV. phpize
Common Errors
I. If you get command not found error for phpize, then you will need to do yum install php-devel
II. If you get error like "ffmpeg headers not found" while configuring the source.
configure: error: ffmpeg headers not found. Make sure ffmpeg is compiled as shared libraries using the --enable-shared option
then it means you need to copy libraries to ffmpeg folder itself.
To Fix:
V. cp /usr/include/ffmpeg/lib*/* /usr/include/ffmpeg/
VI. ./configure
VII. make
VIII. make install
6. Editing php.ini (For me, path is etc/php.ini)
Put the below two lines at the end of the php.ini file
[ffmpeg]
extension=ffmpeg.so
7. You can check the installation by running php script
phpinfo();
?>
Reference Links:
1. http://www.mysql-apache-php.com/ffmpeg-install.htm
2. http://ffmpeg-php.sourceforge.net/
3. http://www.lampadmins.com/f9/ffmpeg-shared-libraries-header-files-663/
Useful Links:
1. http://vexxhost.com/blog/2006/12/20/what-ffmpeg-php-can-do-and-how-to-use-the-most-out-of-it/
2. http://www.phpclasses.org/package/3747-PHP-Manipulate-and-convert-videos-with-ffmpeg-program.html
3. http://howto-pages.org/ffmpeg/
Enjoy Programming !!!
Subscribe to:
Posts (Atom)