[Ffmpeg-devel] [PATCH] vhook timestamps

Diego Biurrun diego
Tue Mar 27 11:53:25 CEST 2007


On Tue, Mar 27, 2007 at 04:19:48PM +0900, Bobby Bingham wrote:
> This patch changes the vhook code to send real timestamps to the filters 
> instead of the current time of day, which is useless, and which the 
> filters could just as easily query for themselves.  I kept the units of 
> the timestamps in nanoseconds to match what the fish filter currently 
> expects.
> 
> --- ffmpeg.orig/ffmpeg.c
> +++ ffmpeg/ffmpeg.c
> @@ -562,7 +562,7 @@ static void do_audio_out(AVFormatContext
>  
> -static void pre_process_video_frame(AVInputStream *ist, AVPicture *picture, void **bufp)
> +static void pre_process_video_frame(AVInputStream *ist, AVPicture *picture, void **bufp, uint64_t pts)

pts is uint64_t here ..

> --- ffmpeg.orig/libavformat/framehook.c
> +++ ffmpeg/libavformat/framehook.c
> @@ -93,11 +93,10 @@ int frame_hook_add(int argc, char *argv[
>  
> -void frame_hook_process(AVPicture *pict, enum PixelFormat pix_fmt, int width, int height)
> +void frame_hook_process(AVPicture *pict, enum PixelFormat pix_fmt, int width, int height, int64_t pts)
> --- ffmpeg.orig/libavformat/framehook.h
> +++ ffmpeg/libavformat/framehook.h
> @@ -46,7 +46,7 @@ typedef FrameHookRelease *FrameHookRelea
>  
> -extern void frame_hook_process(struct AVPicture *pict, enum PixelFormat pix_fmt, int width, int height);
> +extern void frame_hook_process(struct AVPicture *pict, enum PixelFormat pix_fmt, int width, int height, int64_t pts);

.. but int64_t here ..

Why?

Diego




More information about the ffmpeg-devel mailing list