change.mp4.length: Change the length of an .mp4 file

View source: R/change.mp4.length.R

change.mp4.lengthR Documentation

Change the length of an .mp4 file

Description

Creates a and saves a copy of a .mp4 file with a different length to that of the original. The length of the movie is changed by the percent.diff given.

Usage

change.mp4.length(time.mult, input, output, overwrite = F)

Arguments

time.mult

The value by which the time of the movie will be scaled by .mp4 file. Calculated as current length / desired length

i.e) if the current length is 10 seconds and the desired length is 8 seconds the percent.diff would be 10/8.

input

The .mp4 file to change length of

output

The name of the .mp4 file that the copy with the altered length will be saved as. Cannot use the same name as the origonl version, unless choosing to overwrite original.

overwrite

An optional boolean value, if True will delete the original version and replace with the new, altered length version.

Examples

Changing an mp4 file from 10s to 5s
change.mp4.length(0.5, test.mp4, shorter_test.mp4)


Will-McD/ENSTvisualise documentation built on June 24, 2022, 5:13 p.m.