load.video | R Documentation |
You need to have ffmpeg on your path for this to work. This function uses ffmpeg to split the video into individual frames, which are then loaded as images and recombined. Videos are memory-intensive, and load.video performs a safety check before loading a video that would be larger than maxSize in memory (default 1GB)
load.video(
fname,
maxSize = 1,
skip.to = 0,
frames = NULL,
fps = NULL,
extra.args = "",
verbose = FALSE
)
fname |
file to load |
maxSize |
max. allowed size in memory, in GB (default max 1GB). |
skip.to |
skip to a certain point in time (in sec., or "hh:mm::ss" format) |
frames |
number of frames to load (default NULL, all) |
fps |
frames per second (default NULL, determined automatically) |
extra.args |
extra arguments to be passed to ffmpeg (default "", none) |
verbose |
if TRUE, show ffmpeg output (default FALSE) |
an image with the extracted frames along the "z" coordinates
Simon Barthelme
save.video, make.video
fname <- system.file('extdata/tennis_sif.mpeg',package='imager')
##Not run
## load.video(fname) %>% play
## load.video(fname,fps=10) %>% play
## load.video(fname,skip=2) %>% play
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.