The *frame is a pointer to the the YUV420P video frame base address that
you want to put the text into. row_size is the number of bytes that make up
a single row in your video frame.
The x and y are the offsets into the video frame to write the text at.
so write_string( 10,10, "This is a test", {*video_frame}, 640)
would write "This is a test" in the upper left corner of a video frame that
has a width of 640
write_string( 10,10, "This is a test", {*video_frame}, 320)
would write "This is a test" in the upper left corner of a video frame that
has a width of 320
hope this helps
On Tue, Aug 3, 2010 at 11:57 AM, German Vallejos C. <[email protected]>wrote:
> thanks for your code, i'm trying use this, but i have a question
> to call the fuction "write_string"
>
> write_string( int x, //position x
> int y, //position y
> char *text, //text to write on video frame
> char *frame, //..?
> int row_size ) // size text
>
> the parameter "char *frame" i guess this char pointer is frame where
> write string..?
> if this true, from what field struct libav* is pased this..?
>
> Thanks again
>
>
> German
>
>
> On Mon, Aug 2, 2010 at 12:40 PM, Glen Ruedinger <[email protected]>
> wrote:
> > Attached is myfont.h which defines the bitmapped font and font.c that
> draws
> > a string on a YUV420P frame buffer.
> >
> > I have since upgraded my code to use SDL_TTF for more flexability.
> >
> >
> > On Mon, Aug 2, 2010 at 12:10 PM, Stefano Sabatini <
> > [email protected]> wrote:
> >
> >> On date Monday 2010-08-02 11:51:00 -0400, German Vallejos C. encoded:
> >> > Hi, is possible overlay text with libav* libraries on video frames..?
> >>
> >> Check libavfilter soc + drawtext.
> >>
> >> Regards.
> >> _______________________________________________
> >> libav-user mailing list
> >> [email protected]
> >> https://lists.mplayerhq.hu/mailman/listinfo/libav-user
> >>
> >
> > _______________________________________________
> > libav-user mailing list
> > [email protected]
> > https://lists.mplayerhq.hu/mailman/listinfo/libav-user
> >
> >
>
>
>
> --
> [email protected]
> _______________________________________________
> libav-user mailing list
> [email protected]
> https://lists.mplayerhq.hu/mailman/listinfo/libav-user
>
_______________________________________________
libav-user mailing list
[email protected]
https://lists.mplayerhq.hu/mailman/listinfo/libav-user