[FFmpeg-devel] [PATCH] doc/filters: document asetpts in single place

Stefano Sabatini stefasab at gmail.com
Fri May 3 19:59:47 CEST 2013


On date Thursday 2013-05-02 22:16:48 +0000, Paul B Mahol encoded:
> Signed-off-by: Paul B Mahol <onemda at gmail.com>
> ---
>  doc/filters.texi | 81 ++++++++------------------------------------------------
>  1 file changed, 11 insertions(+), 70 deletions(-)
> 
> diff --git a/doc/filters.texi b/doc/filters.texi
> index a62d977..1b5bfa1 100644
> --- a/doc/filters.texi
> +++ b/doc/filters.texi
> @@ -933,75 +933,6 @@ disable padding for the last frame, use:
>  asetnsamples=n=1234:p=0
>  @end example
>  
> - at section asetpts
> -
> -Change the PTS (presentation timestamp) of the input audio frames.
> -
> -This filter accepts the following options:
> -
> - at table @option
> -
> - at item expr
> -The expression which is evaluated for each frame to construct its timestamp.
> -
> - at end table
> -
> -The expression is evaluated through the eval API and can contain the following
> -constants:
> -
> - at table @option
> - at item PTS
> -the presentation timestamp in input
> -
> - at item PI
> -Greek PI
> -
> - at item PHI
> -golden ratio
> -
> - at item E
> -Euler number
> -
> - at item N
> -Number of the audio samples pass through the filter so far, starting at 0.
> -
> - at item S
> -Number of the audio samples in the current frame.
> -
> - at item SR
> -Audio sample rate.
> -
> - at item STARTPTS
> -the PTS of the first frame
> -
> - at item PREV_INPTS
> -previous input PTS
> -
> - at item PREV_OUTPTS
> -previous output PTS
> -
> - at item RTCTIME
> -wallclock (RTC) time in microseconds
> -
> - at item RTCSTART
> -wallclock (RTC) time at the start of the movie in microseconds
> -
> - at end table
> -
> -Some examples follow:
> -
> - at example
> -# start counting PTS from zero
> -asetpts=expr=PTS-STARTPTS
> -
> -#generate timestamps by counting samples
> -asetpts=expr=N/SR/TB
> -
> -# generate timestamps from a "live source" and rebase onto the current timebase
> -asetpts='(RTCTIME - RTCSTART) / (TB * 1000000)"
> - at end example
> -
> -
>  @section asetrate
>  
>  Set the sample rate without altering the PCM data.
> @@ -7927,15 +7858,18 @@ frame rate, only defined for constant frame-rate video
>  the presentation timestamp in input
>  

>  @item N
> -the count of the input frame, starting from 0.
> +the count of the input frame for video or the number of consumed samples,
> +not including the current frame for audio, starting from 0.

So the "new" asetpts introduced a syntax break, and an A/V semantics
mismatch as well.

Feel free to push it, but we should revert N to the old
behavior. Thanks.
-- 
FFmpeg = Fascinating & Fast Minimalistic Pure Extreme Gladiator


More information about the ffmpeg-devel mailing list