Enum FlacEncoderInitErrorCode

Source
pub enum FlacEncoderInitErrorCode {
Show 14 variants StreamEncoderInitStatusOk = 0, StreamEncoderInitStatusEncoderError = 1, StreamEncoderInitStatusUnsupportedContainer = 2, StreamEncoderInitStatusInvalidCallbacks = 3, StreamEncoderInitStatusInvalidNumberOfChannels = 4, StreamEncoderInitStatusInvalidBitsPerSample = 5, StreamEncoderInitStatusInvalidSampleRate = 6, StreamEncoderInitStatusInvalidBlockSize = 7, StreamEncoderInitStatusInvalidMaxLpcOrder = 8, StreamEncoderInitStatusInvalidQlpCoeffPrecision = 9, StreamEncoderInitStatusBlockSizeTooSmallForLpcOrder = 10, StreamEncoderInitStatusNotStreamable = 11, StreamEncoderInitStatusInvalidMetadata = 12, StreamEncoderInitStatusAlreadyInitialized = 13,
}
Expand description

§The error code for FlacEncoderInitError

Variants§

§

StreamEncoderInitStatusOk = 0

  • Initialization was successful
§

StreamEncoderInitStatusEncoderError = 1

  • General failure to set up encoder; call FLAC__stream_encoder_get_state() for cause.
§

StreamEncoderInitStatusUnsupportedContainer = 2

  • The library was not compiled with support for the given container format.
§

StreamEncoderInitStatusInvalidCallbacks = 3

  • A required callback was not supplied.
§

StreamEncoderInitStatusInvalidNumberOfChannels = 4

  • The encoder has an invalid setting for number of channels.
§

StreamEncoderInitStatusInvalidBitsPerSample = 5

  • The encoder has an invalid setting for bits-per-sample. FLAC supports 4-32 bps.
§

StreamEncoderInitStatusInvalidSampleRate = 6

  • The encoder has an invalid setting for the input sample rate.
§

StreamEncoderInitStatusInvalidBlockSize = 7

  • The encoder has an invalid setting for the block size.
§

StreamEncoderInitStatusInvalidMaxLpcOrder = 8

  • The encoder has an invalid setting for the maximum LPC order.
§

StreamEncoderInitStatusInvalidQlpCoeffPrecision = 9

  • The encoder has an invalid setting for the precision of the quantized linear predictor coefficients.
§

StreamEncoderInitStatusBlockSizeTooSmallForLpcOrder = 10

  • The specified block size is less than the maximum LPC order.
§

StreamEncoderInitStatusNotStreamable = 11

  • The encoder is bound to the Subset but other settings violate it.
§

StreamEncoderInitStatusInvalidMetadata = 12

  • The metadata input to the encoder is invalid, in one of the following ways:
    • FLAC__stream_encoder_set_metadata() was called with a null pointer but a block count > 0
    • One of the metadata blocks contains an undefined type
    • It contains an illegal CUESHEET as checked by FLAC__format_cuesheet_is_legal()
    • It contains an illegal SEEKTABLE as checked by FLAC__format_seektable_is_legal()
    • It contains more than one SEEKTABLE block or more than one VORBIS_COMMENT block
    • FLAC__STREAM_ENCODER_INIT_STATUS_ALREADY_INITIALIZED
    • FLAC__stream_encoder_init_*() was called when the encoder was already initialized, usually because FLAC__stream_encoder_finish() was not called.
§

StreamEncoderInitStatusAlreadyInitialized = 13

  • FLAC__stream_encoder_init_*() was called when the encoder was already initialized, usually because FLAC__stream_encoder_finish() was not called.

Trait Implementations§

Source§

impl Clone for FlacEncoderInitErrorCode

Source§

fn clone(&self) -> FlacEncoderInitErrorCode

Returns a copy of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for FlacEncoderInitErrorCode

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Display for FlacEncoderInitErrorCode

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Error for FlacEncoderInitErrorCode

1.30.0 · Source§

fn source(&self) -> Option<&(dyn Error + 'static)>

Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§

fn description(&self) -> &str

👎Deprecated since 1.42.0: use the Display impl or to_string()
1.0.0 · Source§

fn cause(&self) -> Option<&dyn Error>

👎Deprecated since 1.33.0: replaced by Error::source, which can support downcasting
Source§

fn provide<'a>(&'a self, request: &mut Request<'a>)

🔬This is a nightly-only experimental API. (error_generic_member_access)
Provides type-based access to context intended for error reports. Read more
Source§

impl From<u32> for FlacEncoderInitErrorCode

Source§

fn from(code: u32) -> Self

Converts to this type from the input type.
Source§

impl Copy for FlacEncoderInitErrorCode

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T> ToString for T
where T: Display + ?Sized,

Source§

fn to_string(&self) -> String

Converts the given value to a String. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.