[FFmpeg-user] Translating working command line to programmatic code
Brad O'Hearne
brado at bighillsoftware.com
Wed Aug 1 00:31:33 CEST 2012
Hello,
*** My use case:
On a Mac, I need to capture video from an attached camera (such as the internal MacBook Pro camera), transcode it to FLV, and then stream (publish) it to Wowza media server for restreaming.
*** What I have done so far:
I have successfully used the ffmpeg client to take an mp4 video, transcode it to FLV, and publish it to Wowza using RTMP, using the following command line:
ffmpeg -i ~/SampleVideo.mp4 -re -r 24 -b:v 1000k -f flv rtmp://localhost/live/SAMPLE_STREAM
I have also consumed the video from a web browser successfully, so I know that this is both possible in ffmpeg and works. Basically the above serves as a successful prototype for my use-case.
*** What I need to do now:
I need know how to do two things specifically:
1) Convert the above command line to programmatic code which uses the underlying ffmpeg libraries to accomplish the same thing. Can anyone point me in the right direction of which libraries to use, and or direct me to a snippet of sample code which demonstrates how to do this?
2) Whatever the approach in 1 above, I need to convert from taking a video file as input, and instead taking captured frame data as input.
Any help with these two things would be greatly appreciated.
Cheers,
Brad
Brad O'Hearne
Founder / Lead Developer
Big Hill Software LLC
http://www.bighillsoftware.com
More information about the ffmpeg-user
mailing list