segment_video | R Documentation |
Use FFmpeg to quickly break a single video file into multiple smaller video
files (with the same encoding) based on pairs of start and stop timestamps.
Segment video files will be named by taking the name of infile
and
appending a suffix of an underscore (_) and an integer indicating which
segment (based on the order provided in ts_start
and ts_stop
).
segment_video(infile, ts_start, ts_stop, outfiles = NULL, run = TRUE, ...)
infile |
A string containing the path to a video file. |
ts_start |
A vector containing one or more timestamps indicating the
start of each segment to create. Can be either a numeric vector indicating
seconds or a character vector with time duration syntax. Must have the same
length as |
ts_stop |
A vector containing one or more timestamps indicating the stop
of each segment to create. Can be either a numeric vector indicating
seconds or a character vector with time duration syntax. Must have the same
length as |
outfiles |
Either NULL or a character vector indicating the filename
(with extension) for each segment to create. If NULL, will append a
zero-padded integer to |
run |
A logical indicating whether to run the command or just create it. |
... |
Not currently used |
https://ffmpeg.org/ffmpeg-utils.html#time-duration-syntax
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.