[Libav-user] Create a video with pixmap?

cesar pachon cesarpachon at gmail.com
Thu Aug 13 15:05:05 CEST 2015


you are absolutely in the right path. you just have to figure how to
implement a function that copies/translate the pixels from you QT
data-structure into the buffer that in the example is being filled with
self-generated data.
It may be as easy as to copy each r,g,b byte or depending on your
input/output formats, it may require some manipulation to properly
decode/encode the pixels in the right formats (bit lengths, channel order,
etc)
I went through that path a couple of months ago, in my case I was writing a
video-recorder chrome-extension and had to copy the pixels from the
chrome-video stream into the ffmpeg AVFrame. I used the same example that
you as reference for that.

other tricky part you will have to solve (once you will be able to copy
frames) will be the timing of each frame. but that is another history.

Cesar  Pachón
-------------------------------------------------------------
www.cesarpachon.com, just a digital hermit


On Wed, Aug 12, 2015 at 4:31 AM, Moreno, Nicolas - Harris France <
NMORENO at harris.com> wrote:

> Hello,
>
>
>
> My application needs to capture all the window to create a capture video.
> This software is developed with C++ and Qt.
>
>
>
> I can get a screenshot each X msec and now I have to put it in a video
> file. I would like to use FFmpeg but I didn’t found a example to create a
> video with QPixmap (or pixmap). I found this example:
> http://ffmpeg.org/doxygen/trunk/decoding_encoding_8c-example.html but I
> can’t doing it work (problem with malloc) and I am not sure that is the
> better way to create video.
>
>
>
> Can you explain me how to create a video or show me an example, please?
>
>
>
> If you need, I can get you more information.
>
>
>
> Thanks in advance,
>
> Nicolas MORENO
>
>
>
> *------------------------------------------------*
>
> *Nicolas MORENO*
> Consulting Software Engineer
>
> *Exelis*
> *Visual Information Solutions*
> *A subsidiary of Exelis Inc.*
> Standard : +33 (0) 5 81 91 90 33
> nicolas.moreno at exelisinc.com
>
>
>
> ------------------------------
>
> This e-mail and any files transmitted with it may be proprietary and are
> intended solely for the use of the individual or entity to whom they are
> addressed. If you have received this e-mail in error please notify the
> sender. Please note that any views or opinions presented in this e-mail are
> solely those of the author and do not necessarily represent those of Exelis
> Inc. The recipient should check this e-mail and any attachments for the
> presence of viruses. Exelis Inc. accepts no liability for any damage caused
> by any virus transmitted by this e-mail.
>
> _______________________________________________
> Libav-user mailing list
> Libav-user at ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/libav-user
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://ffmpeg.org/pipermail/libav-user/attachments/20150813/b71552b1/attachment.html>


More information about the Libav-user mailing list