pub enum StreamError {
Encode(EncodeError),
Io(Error),
InvalidConfig {
reason: String,
},
UnsupportedCodec {
codec: String,
reason: String,
},
FanoutFailure {
failed: usize,
total: usize,
messages: Vec<String>,
},
ProtocolUnavailable {
reason: String,
},
Ffmpeg {
code: i32,
message: String,
},
}Expand description
Errors that can occur during streaming output operations.
This enum covers all error conditions that may arise when configuring, building, or writing HLS / DASH output.
§Error Categories
- Encoding errors:
Encode— wraps errors fromff-encode - I/O errors:
Io— file system errors during segment writing - Configuration errors:
InvalidConfig— missing or invalid builder options, or not-yet-implemented stubs
Variants§
Encode(EncodeError)
An encoding operation in the underlying ff-encode crate failed.
This error propagates from ff_encode::EncodeError when the encoder
cannot open a codec or write frames.
Io(Error)
An I/O operation failed during segment or playlist writing.
Typical causes include missing output directories, permission errors, or a full disk.
InvalidConfig
A configuration value is missing or invalid, or the feature is not yet implemented.
This variant is also used as a stub return value for write() / hls()
/ dash() methods that await FFmpeg muxing integration.
UnsupportedCodec
The requested codec is not supported by the output format.
For example, RTMP/FLV requires H.264 video and AAC audio; requesting
any other codec returns this error from build().
Fields
FanoutFailure
One or more FanoutOutput targets failed to receive a
frame or to finish cleanly.
All targets still receive every frame even when some fail; errors are collected and returned together after the full fan-out pass.
Fields
The requested network protocol is not compiled into the linked FFmpeg build.
Returned by build() when a feature-gated output (e.g. SrtOutput)
is opened but the underlying FFmpeg library was built without the
required protocol support (e.g. libsrt).
Ffmpeg
An FFmpeg runtime error occurred during muxing or transcoding.
code is the raw FFmpeg negative error value returned by the failing
function (e.g. AVERROR(EINVAL)). message is the human-readable
string produced by av_strerror. Exposing the numeric code lets
engineers cross-reference FFmpeg documentation and source directly.
Trait Implementations§
Source§impl Debug for StreamError
impl Debug for StreamError
Source§impl Display for StreamError
impl Display for StreamError
Source§impl Error for StreamError
impl Error for StreamError
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()