Grab Image, Convert video to H264 single php

this is a updated code, provided by Steve, this single php file will grab image from input video and convert video to h264.


Line, 3 is where you input your video, the output.jpg is the output mpeg also called jpg image format which will be be grabbed. the output.ogm is the actual encoded video. ogm is just a open source video container like avi mkv etc. you can change it to whatever suits your needs.

Line 12, deals with the image grabbing which uses ffmpeg, not much to be said here.

Line 16, deals with Mencoder this basically is the encoding engine, here you can change bit-rate, video width and height and aspect ratio. and volume control.

Dependency packages and operating systems

1. Ubuntu 8.10 Desktop or Server version
2. Lamp server - php5 CLI everything that includes inside Lamp server
3. FFmpeg
4. Mencoder

thanks it.