Function subrip::utils::offset_subs

source ·
pub fn offset_subs(
subs: &[Subtitle],
delay_start: Option<Duration>
) -> Vec<Subtitle>
Expand description

Shift the timestamps for the provided subs to 0 + delay_start.

This is useful if you are cutting a segment out of a video file, and need the relevant subtitles to start at the beginning of the video.

delay_start is optional, and will insert a delay, otherwise the first subtitle card will appear at 00:00:00.