Struct ffmpeg_cli::FfmpegBuilder[][src]

pub struct FfmpegBuilder<'a> {
    pub options: Vec<Parameter<'a>>,
    pub inputs: Vec<File<'a>>,
    pub outputs: Vec<File<'a>>,
    pub ffmpeg_command: &'a str,
    pub stdin: Stdio,
    pub stdout: Stdio,
    pub stderr: Stdio,
}

The main struct which is used to set up ffmpeg.

Fields

options: Vec<Parameter<'a>>

The global options.

inputs: Vec<File<'a>>

The input files.

outputs: Vec<File<'a>>

The output files.

ffmpeg_command: &'a str

The command that’s run for ffmpeg. Usually just ffmpeg

stdin: Stdio

Passed as Command::stdin

stdout: Stdio

Passed as Command::stdout

stderr: Stdio

Passed as Command::stderr

Implementations

impl<'a> FfmpegBuilder<'a>[src]

pub async fn run(self) -> Result<Ffmpeg, Error>[src]

Spawns a new ffmpeg process and records the output, consuming the builder

This has to consume the builder for stdin, etc to work

impl<'a> FfmpegBuilder<'a>[src]

pub fn new() -> FfmpegBuilder<'a>[src]

Gets a FfmpegBuilder with nothing set

pub fn option(self, option: Parameter<'a>) -> Self[src]

Adds an option.

pub fn input(self, input: File<'a>) -> Self[src]

Adds an input.

pub fn output(self, output: File<'a>) -> Self[src]

Adds an output.

pub fn stdin(self, stdin: Stdio) -> Self[src]

Sets stdin.

pub fn stdout(self, stdout: Stdio) -> Self[src]

Sets stdout.

pub fn stderr(self, stderr: Stdio) -> Self[src]

Sets stderr.

pub fn to_command(self) -> Command[src]

Turns it into a command, consuming the builder.

This has to consume the builder for stdin, etc to work Note that usually you want to use Self::run(), not call this directly

Trait Implementations

impl<'a> Debug for FfmpegBuilder<'a>[src]

Auto Trait Implementations

impl<'a> RefUnwindSafe for FfmpegBuilder<'a>

impl<'a> Send for FfmpegBuilder<'a>

impl<'a> Sync for FfmpegBuilder<'a>

impl<'a> Unpin for FfmpegBuilder<'a>

impl<'a> UnwindSafe for FfmpegBuilder<'a>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.