.Net Library for converting Motion Jpeg files to Jpeg stills?
I have a couple of Panasonic cameras that I use for shooting video, and they produce Motion JPEG (wrapped as .mov). I want to write a simple tool (in C开发者_运维知识库#) to convert the .mov files to a set of JPG stills.
Can't find much help becasue most folks want to read streams or to go the other way (from stills to video).
What should I use? I have picked up that there are at least couple of different libraries that might be useful. (DirectShow, OpenCV) but I'd appreciate any and all advice on how to approach this task...
In the end, I just analysed the files, worked out the headers and wrote the code. If anyone else is up to the same task, it's pretty easy, just watch for the keyframes, which seem to repeat what I'd deduced is the "start JPEG" code 3 times (at least for my camera).
Maybe useful....
byte[] _startToken = new byte[2] { 0xFF, 0xD8 }; //JPEG Start
byte[] _endToken = new byte[2] { 0xFF, 0xD9 }; //JPEG End
精彩评论