#[non_exhaustive]pub enum Error {
Show 58 variants
NotStarted,
Url(UrlError),
OpenInputStream(OpenInputError),
FindStream(FindStreamError),
Decoder(DecoderError),
FilterGraphParse(FilterGraphParseError),
FilterDescUtf8,
FilterNameUtf8,
FilterZeroOutputs,
FilterZeroInputs,
ParseInteger,
AllocOutputContext(AllocOutputContextError),
OpenOutput(OpenOutputError),
FileSameAsInput(String),
FindDevices(FindDevicesError),
AllocFrame(AllocFrameError),
AllocPacket(AllocPacketError),
FrameWritable(FrameWritableError),
Muxing(MuxingOperationError),
OpenEncoder(OpenEncoderOperationError),
Encoding(EncodingOperationError),
FilterGraph(FilterGraphOperationError),
OpenDecoder(OpenDecoderOperationError),
Decoding(DecodingOperationError),
Demuxing(DemuxingOperationError),
PacketScanner(PacketScannerError),
FrameFilterInit(Box<dyn Error + Send + Sync>),
FrameFilterProcess(Box<dyn Error + Send + Sync>),
FrameFilterRequest(Box<dyn Error + Send + Sync>),
FrameFilterTypeNoMatched(String, String),
FrameFilterStreamTypeNoMatched(String, usize, String),
FrameFilterDstFinished,
FrameFilterFrameDuplicateFailed,
FrameFilterThreadExited,
WorkerPanicked(String),
StartFailed,
RtmpStreamAlreadyExists(String),
RtmpCreateStream,
RtmpRegistrationQueueFull,
RtmpThreadExited,
RtmpStreamClosed,
RtmpServerAlreadyStarted,
Subtitle(SubtitleError),
WgpuFilter(WgpuFilterError),
OpenGLFilter(OpenGLFilterError),
IO(Error),
EOF,
Exit,
Bug,
InvalidRecipeArg(String),
ContainerInfo(ContainerInfoError),
FrameExport(FrameExportError),
Writer(WriterError),
Push(PushError),
FrameSourceThreadExited,
PacketSink(PacketSinkError),
AmbiguousVideoSource {
video_streams: usize,
},
UnconsumedCliOption {
site: String,
option: String,
},
}Expand description
Top-level error type for all ez-ffmpeg operations.
Most variants wrap a stage-specific error enum (opening inputs and outputs, demuxing, decoding, filtering, encoding, muxing, …), so callers can match on the pipeline stage first and inspect the typed cause when they need to.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
NotStarted
Returned when an operation requires a scheduler that has been started, but it has not been.
Url(UrlError)
A URL or path string could not be converted into a C string for
FFmpeg (see UrlError).
OpenInputStream(OpenInputError)
Opening an input file, stream, device, or custom input source failed.
FindStream(FindStreamError)
Probing stream information from an opened input failed.
Decoder(DecoderError)
Resolving a decoder failed (see DecoderError).
FilterGraphParse(FilterGraphParseError)
Parsing a filtergraph description failed.
FilterDescUtf8
Returned when a filtergraph link label could not be converted to a UTF-8 string.
FilterNameUtf8
Returned when a filter name could not be converted to a UTF-8 string.
FilterZeroOutputs
Returned when a filtergraph declares zero outputs, which is not supported.
FilterZeroInputs
Returned when a filtergraph declares zero inputs, which is not supported.
ParseInteger
Returned when a numeric field — such as a file index in a stream specifier or link label — could not be parsed as an integer.
AllocOutputContext(AllocOutputContextError)
Allocating an output format context failed.
OpenOutput(OpenOutputError)
Opening or configuring an output failed.
FileSameAsInput(String)
Returned when an output URL is identical to one of the input URLs; the payload is the offending path. In-place editing is not supported.
FindDevices(FindDevicesError)
Enumerating capture devices failed.
AllocFrame(AllocFrameError)
Allocating an AVFrame failed.
AllocPacket(AllocPacketError)
Allocating an AVPacket failed.
FrameWritable(FrameWritableError)
Making a frame’s data buffers writable failed (see
FrameWritableError).
Muxing(MuxingOperationError)
A muxing operation failed while writing the output container.
OpenEncoder(OpenEncoderOperationError)
Opening or configuring an encoder failed.
Encoding(EncodingOperationError)
An encoding operation failed.
FilterGraph(FilterGraphOperationError)
A filtergraph runtime operation failed.
OpenDecoder(OpenDecoderOperationError)
Opening or configuring a decoder failed.
Decoding(DecodingOperationError)
A decoding operation failed.
Demuxing(DemuxingOperationError)
A demuxing operation failed.
PacketScanner(PacketScannerError)
A packet-scanning operation failed (see PacketScannerError).
FrameFilterInit(Box<dyn Error + Send + Sync>)
A frame filter failed to initialize; carries the error returned by
the filter’s init.
FrameFilterProcess(Box<dyn Error + Send + Sync>)
A frame filter failed while processing a frame; carries the error
returned by the filter’s filter_frame.
FrameFilterRequest(Box<dyn Error + Send + Sync>)
A frame filter failed while generating a frame; carries the error
returned by the filter’s request_frame.
FrameFilterTypeNoMatched(String, String)
Returned while building a frame pipeline when no stream of the required media type exists at the named pipeline end; fields are the pipeline end (input/output) and the media type.
FrameFilterStreamTypeNoMatched(String, usize, String)
Returned while building a frame pipeline when no stream at the named pipeline end matches both the requested stream index and media type; fields are the pipeline end, the stream index, and the media type.
FrameFilterDstFinished
Returned when a frame pipeline tries to deliver a frame to a destination that has already finished.
FrameFilterFrameDuplicateFailed
Returned when a frame pipeline fails to duplicate a frame required for an additional destination.
FrameFilterThreadExited
Returned when spawning a frame pipeline’s worker thread fails, so the pipeline never ran.
WorkerPanicked(String)
A worker thread panicked; the payload is the worker’s thread name. Output may be incomplete.
StartFailed
Recorded as the scheduler result when start() fails after some
worker threads were already launched. start() itself returns the
actual init error to its caller; this recorded value is what
concurrent observers (packet-sink terminal callbacks) report, so a
sink can never mistake a torn-down startup for a settled-Ok job.
RtmpStreamAlreadyExists(String)
Returned when publishing to the embedded RTMP server with a stream key that is already in use; the payload is the key.
RtmpCreateStream
Returned when a stream could not be created on the embedded RTMP server, typically because the server has stopped.
RtmpRegistrationQueueFull
Returned when too many streams are waiting to be registered on the embedded RTMP server.
RtmpThreadExited
Returned when the embedded RTMP server’s thread has exited.
RtmpStreamClosed
Returned when the embedded RTMP server is no longer consuming a published stream.
RtmpServerAlreadyStarted
Returned when starting an embedded RTMP server that was already started; clones of one server share a single lifecycle that can be started only once.
Subtitle(SubtitleError)
A subtitle processing operation failed.
WgpuFilter(WgpuFilterError)
A wgpu GPU filter operation failed.
OpenGLFilter(OpenGLFilterError)
An OpenGL filter operation failed (deprecated opengl feature).
IO(Error)
An I/O error from the standard library.
EOF
Internal end-of-stream marker passed between pipeline stages; a normal end of input is consumed internally rather than reported as a job failure.
Exit
Internal control-flow marker instructing pipeline stages to shut down; normally consumed internally.
Bug
Internal invariant violation that should never occur; indicates a bug in this crate rather than a problem with user input.
InvalidRecipeArg(String)
Returned when a recipe or analysis option is invalid (out of range, malformed, or inconsistent); the payload describes the problem.
ContainerInfo(ContainerInfoError)
A container-info query was called with an out-of-range index.
FrameExport(FrameExportError)
A frame-export operation failed.
Writer(WriterError)
Building or opening a video writer failed.
Push(PushError)
Pushing a frame into a video writer failed.
FrameSourceThreadExited
Returned when a frame-source input’s worker thread failed to start.
PacketSink(PacketSinkError)
A packet-sink output failed (see PacketSinkError).
AmbiguousVideoSource
CLI-compat pipelines only: a -vf command was lowered onto an input
whose OPENED demuxer does not carry exactly one video stream. The
check runs on the demuxer instance the pipeline actually executes
with (no separate probe opening, no TOCTOU window). The facade maps
this to its public AmbiguousFilterSource diagnostic.
UnconsumedCliOption
Strict AVOption handling (CLI-compat pipelines): an option the caller
supplied was not consumed by the component it targeted. The default
builder path only WARNS about such leftovers; pipelines built through
the cli feature’s entry points fail instead, mirroring fftools’
check_avoptions abort. Only exists with the cli feature — the
feature-off API surface is unchanged.
Trait Implementations§
Source§impl Error for Error
impl Error for Error
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
Source§impl From<AllocFrameError> for Error
impl From<AllocFrameError> for Error
Source§fn from(source: AllocFrameError) -> Self
fn from(source: AllocFrameError) -> Self
Source§impl From<AllocOutputContextError> for Error
impl From<AllocOutputContextError> for Error
Source§fn from(source: AllocOutputContextError) -> Self
fn from(source: AllocOutputContextError) -> Self
Source§impl From<AllocPacketError> for Error
impl From<AllocPacketError> for Error
Source§fn from(source: AllocPacketError) -> Self
fn from(source: AllocPacketError) -> Self
Source§impl From<ContainerInfoError> for Error
impl From<ContainerInfoError> for Error
Source§fn from(source: ContainerInfoError) -> Self
fn from(source: ContainerInfoError) -> Self
Source§impl From<DecoderError> for Error
impl From<DecoderError> for Error
Source§fn from(source: DecoderError) -> Self
fn from(source: DecoderError) -> Self
Source§impl From<DecodingOperationError> for Error
impl From<DecodingOperationError> for Error
Source§fn from(source: DecodingOperationError) -> Self
fn from(source: DecodingOperationError) -> Self
Source§impl From<DemuxingOperationError> for Error
impl From<DemuxingOperationError> for Error
Source§fn from(source: DemuxingOperationError) -> Self
fn from(source: DemuxingOperationError) -> Self
Source§impl From<EncodingOperationError> for Error
impl From<EncodingOperationError> for Error
Source§fn from(source: EncodingOperationError) -> Self
fn from(source: EncodingOperationError) -> Self
Source§impl From<Error> for StreamError
impl From<Error> for StreamError
Source§impl From<FilterGraphOperationError> for Error
impl From<FilterGraphOperationError> for Error
Source§fn from(source: FilterGraphOperationError) -> Self
fn from(source: FilterGraphOperationError) -> Self
Source§impl From<FilterGraphParseError> for Error
impl From<FilterGraphParseError> for Error
Source§fn from(source: FilterGraphParseError) -> Self
fn from(source: FilterGraphParseError) -> Self
Source§impl From<FindDevicesError> for Error
impl From<FindDevicesError> for Error
Source§fn from(source: FindDevicesError) -> Self
fn from(source: FindDevicesError) -> Self
Source§impl From<FindStreamError> for Error
impl From<FindStreamError> for Error
Source§fn from(source: FindStreamError) -> Self
fn from(source: FindStreamError) -> Self
Source§impl From<FrameExportError> for Error
impl From<FrameExportError> for Error
Source§fn from(source: FrameExportError) -> Self
fn from(source: FrameExportError) -> Self
Source§impl From<FrameWritableError> for Error
impl From<FrameWritableError> for Error
Source§fn from(source: FrameWritableError) -> Self
fn from(source: FrameWritableError) -> Self
Source§impl From<MuxingOperationError> for Error
impl From<MuxingOperationError> for Error
Source§fn from(source: MuxingOperationError) -> Self
fn from(source: MuxingOperationError) -> Self
Source§impl From<OpenDecoderOperationError> for Error
impl From<OpenDecoderOperationError> for Error
Source§fn from(source: OpenDecoderOperationError) -> Self
fn from(source: OpenDecoderOperationError) -> Self
Source§impl From<OpenEncoderOperationError> for Error
impl From<OpenEncoderOperationError> for Error
Source§fn from(source: OpenEncoderOperationError) -> Self
fn from(source: OpenEncoderOperationError) -> Self
Source§impl From<OpenGLFilterError> for Error
Available on crate feature opengl only.
impl From<OpenGLFilterError> for Error
opengl only.Source§fn from(err: OpenGLFilterError) -> Self
fn from(err: OpenGLFilterError) -> Self
Source§impl From<OpenInputError> for Error
impl From<OpenInputError> for Error
Source§fn from(source: OpenInputError) -> Self
fn from(source: OpenInputError) -> Self
Source§impl From<OpenOutputError> for Error
impl From<OpenOutputError> for Error
Source§fn from(source: OpenOutputError) -> Self
fn from(source: OpenOutputError) -> Self
Source§impl From<OwnedPushError> for Error
Drops the recovered frame and wraps the cause as
crate::error::Error::Push, so ? composes in functions returning
crate::error::Result. Destructure the error first when the buffer
should be reused.
impl From<OwnedPushError> for Error
Drops the recovered frame and wraps the cause as
crate::error::Error::Push, so ? composes in functions returning
crate::error::Result. Destructure the error first when the buffer
should be reused.