Hey,
Today I spent some time trying to work out the best way to load AV streams (ie: .avi, .vob, .mp3 etc) files into me program. So there are a nice 100 or so ways to do this with different libraries. But what's LGPL and usable? There's a good question.
After a good bit of googling around I found FFMpeg, LibAVCodec, LibAVFormat, LibAVFilter etc... all hard to link to, seperate fast-moving API's and breaking ABI's... nightmare.
In comes LibAVBin, a "thin wrapper" around all the above libraries, and abstracts away the details. Still getting the example to work is a little messy, so heres my own experience with it as of 09-04-11.
Grab the source here: http://code.google.com/p/avbin/
Then read the readme, and hit the SVN command to grab the latest FFMpeg.
./build.sh the library, there's a couple of errors in main, cast "malloc" to (void*), and fix whatever else is needed... I forget!
Then grab: http://code.google.com/p/avbin/source/browse/trunk/example/avbin_dump.c
That's the basic code for analysing a file's media content. From there it should be easy enough to see what's needed. The top of the header file has a nice "tutorial" on what functions need to be called in what order. I'm sure you'll work it out. Any questions, fire away!
Cheers, -Harry
No comments:
Post a Comment