summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorStefano Sabatini <stefasab@gmail.com>2012-08-08 13:44:11 +0200
committerStefano Sabatini <stefasab@gmail.com>2012-08-09 01:03:05 +0200
commitf6580b50edd1f1e0eb92309a16fe90cc911ccf5e (patch)
treefa68df9b437d107903ab061d998159e015f98323 /doc
parent11a1033c9fcae380f4da06b2b0253ab0eb82b026 (diff)
lavfi: add asetpts audio filter
Based on an idea by Andrey Utkin <andrey.krieger.utkin@gmail.com>.
Diffstat (limited to 'doc')
-rw-r--r--doc/filters.texi19
1 files changed, 17 insertions, 2 deletions
diff --git a/doc/filters.texi b/doc/filters.texi
index e73fc09431..a5627525a9 100644
--- a/doc/filters.texi
+++ b/doc/filters.texi
@@ -3032,9 +3032,11 @@ Mark the frame as top-field-first.
Mark the frame as progressive.
@end table
-@section setpts
+@section asetpts, setpts
-Change the PTS (presentation timestamp) of the input video frames.
+Change the PTS (presentation timestamp) of the input frames.
+
+@code{asetpts} works on audio frames, @code{setpts} on video frames.
Accept in input an expression evaluated through the eval API, which
can contain the following constants:
@@ -3046,6 +3048,16 @@ the presentation timestamp in input
@item N
the count of the input frame, starting from 0.
+@item NB_CONSUMED_SAMPLES
+the number of consumed samples, not including the current frame (only
+audio)
+
+@item NB_SAMPLES
+the number of samples in the current frame (only audio)
+
+@item SAMPLE_RATE
+audio sample rate
+
@item STARTPTS
the PTS of the first video frame
@@ -3084,6 +3096,9 @@ setpts=N/(25*TB)
# fixed rate 25 fps with some jitter
setpts='1/(25*TB) * (N + 0.05 * sin(N*2*PI/25))'
+
+# apply an offset of 10 seconds to the input PTS
+setpts=PTS+10/TB
@end example
@section settb, asettb