diff options
author | Paul B Mahol <onemda@gmail.com> | 2014-07-02 09:39:07 +0000 |
---|---|---|
committer | Paul B Mahol <onemda@gmail.com> | 2014-09-05 17:30:57 +0000 |
commit | 422619646ea0e938188a49a06226831cc42e2a6a (patch) | |
tree | 7c82599181e9a9cb15405ec815a9dbe23e35c994 /doc/filters.texi | |
parent | 1e4e760f767b597f88442b75e90d726ae626b230 (diff) | |
download | ffmpeg-422619646ea0e938188a49a06226831cc42e2a6a.tar.gz |
add silenceremove filter
Signed-off-by: Paul B Mahol <onemda@gmail.com>
Diffstat (limited to 'doc/filters.texi')
-rw-r--r-- | doc/filters.texi | 69 |
1 files changed, 69 insertions, 0 deletions
diff --git a/doc/filters.texi b/doc/filters.texi index d13278ef71..627f112724 100644 --- a/doc/filters.texi +++ b/doc/filters.texi @@ -1875,6 +1875,75 @@ ffmpeg -i silence.mp3 -af silencedetect=noise=0.0001 -f null - @end example @end itemize +@section silenceremove + +Remove silence from the beginning, middle or end of the audio. + +The filter accepts the following options: + +@table @option +@item start_periods +This value is used to indicate if audio should be trimmed at beginning of +the audio. A value of zero indicates no silence should be trimmed from the +beginning. When specifying a non-zero value, it trims audio up until it +finds non-silence. Normally, when trimming silence from beginning of audio +the @var{start_periods} will be @code{1} but it can be increased to higher +values to trim all audio up to specific count of non-silence periods. +Default value is @code{0}. + +@item start_duration +Specify the amount of time that non-silence must be detected before it stops +trimming audio. By increasing the duration, bursts of noises can be treated +as silence and trimmed off. Default value is @code{0}. + +@item start_threshold +This indicates what sample value should be treated as silence. For digital +audio, a value of @code{0} may be fine but for audio recorded from analog, +you may wish to increase the value to account for background noise. +Can be specified in dB (in case "dB" is appended to the specified value) +or amplitude ratio. Default value is @code{0}. + +@item stop_periods +Set the count for trimming silence from the end of audio. +To remove silence from the middle of a file, specify a @var{stop_periods} +that is negative. This value is then threated as a positive value and is +used to indicate the effect should restart processing as specified by +@var{start_periods}, making it suitable for removing periods of silence +in the middle of the audio. +Default value is @code{0}. + +@item stop_duration +Specify a duration of silence that must exist before audio is not copied any +more. By specifying a higher duration, silence that is wanted can be left in +the audio. +Default value is @code{0}. + +@item stop_threshold +This is the same as @option{start_threshold} but for trimming silence from +the end of audio. +Can be specified in dB (in case "dB" is appended to the specified value) +or amplitude ratio. Default value is @code{0}. + +@item leave_silence +This indicate that @var{stop_duration} length of audio should be left intact +at the beginning of each period of silence. +For example, if you want to remove long pauses between words but do not want +to remove the pauses completely. Default value is @code{0}. + +@end table + +@subsection Examples + +@itemize +@item +The following example shows how this filter can be used to start a recording +that does not contain the delay at the start which usually occurs between +pressing the record button and the start of the performance: +@example +silenceremove=1:5:0.02 +@end example +@end itemize + @section treble Boost or cut treble (upper) frequencies of the audio using a two-pole |