Solved it guys.
I was calling av_codec_encode_video2 twice for some reason, and the second
call was encoding a blank frame instead of the one that had data decoded
into it. Silly mistake :p
Thanks for the replies!
On Mon, May 6, 2013 at 7:51 PM, Alex Cohn wrote:
> On Sun, May 5, 2013 at 2:59
On Sun, May 5, 2013 at 2:59 PM, yy-zed wrote:
I've written a piece of C++ code that can capture webcam video frame, decode
> them, convert them to YUV420P, encode them and then write them to a file.
> If
> I use the mpeg2 codec and write to a .mpg file, everything works perfectly.
> But, if I use
Sam,
Early on in my video encoding work I had encountered something similar. I don't
know if this can help you or not -- while I'm capturing from QTKit, I am
converting pixel formats and encoding to FLV. There's enough similarity there
that I thought it might be worth taking a look-see at my c
I've written a piece of C++ code that can capture webcam video frame, decode
them, convert them to YUV420P, encode them and then write them to a file. If
I use the mpeg2 codec and write to a .mpg file, everything works perfectly.
But, if I use flv, then the output produced is just a green screen. I