# [−][src]Enum image::ImageError

    pub enum ImageError {
        FormatError(String),
        DimensionError,
        UnsupportedError(String),
        UnsupportedColor(ColorType),
        NotEnoughData,
        IoError(Error),
        ImageEnd,
        InsufficientMemory,
    }

An enumeration of Image errors

## Variants

`FormatError(String)`

The Image is not formatted properly

`DimensionError`

The Image's dimensions are either too small or too large

`UnsupportedError(String)`

The Decoder does not support this image format

`UnsupportedColor(ColorType)`

The Decoder does not support this color type

`NotEnoughData`

Not enough data was provided to the Decoder to decode the image

`IoError(Error)`

An I/O Error occurred while decoding the image

`ImageEnd`

The end of the image has been reached

`InsufficientMemory`

There is not enough memory to complete the given operation

## Trait Implementations

### `impl From<Error> for ImageError`[src]

#### `fn from(error: Error) -> ImageError`[src]

Performs the conversion.

### `impl From<DecodingError> for ImageError`[src]

#### `fn from(err: DecodingError) -> ImageError`[src]

Performs the conversion.

### `impl From<Error> for ImageError`[src]

#### `fn from(err: Error) -> ImageError`[src]

Performs the conversion.

### `impl From<DecodingError> for ImageError`[src]

#### `fn from(err: DecodingError) -> ImageError`[src]

Performs the conversion.

### `impl From<TiffError> for ImageError`[src]

#### `fn from(err: TiffError) -> ImageError`[src]

Performs the conversion.

### `impl From<Error> for ImageError`[src]

#### `fn from(err: Error) -> ImageError`[src]

Performs the conversion.

### `impl Debug for ImageError`[src]

#### `fn fmt(&self, f: &mut Formatter) -> Result`[src]

Formats the value using the given formatter. Read more

### `impl Display for ImageError`[src]

#### `fn fmt(&self, fmt: &mut Formatter) -> Result<(), Error>`[src]

Formats the value using the given formatter. Read more

### `impl Error for ImageError`[src]

#### `fn description(&self) -> &str`[src]

This method is soft-deprecated. Read more

#### `fn cause(&self) -> Option<&dyn Error>`[src]

Deprecated since 1.33.0:

replaced by Error::source, which can support downcasting

The lower-level cause of this error, if any. Read more

#### `fn source(&self) -> Option<&(dyn Error + 'static)>`1.30.0[src]

The lower-level source of this error, if any. Read more

#### `fn backtrace(&self) -> Option<&Backtrace>`[src]

🔬 This is a nightly-only experimental API. (`backtrace`)

Returns a stack backtrace, if available, of where this error ocurred. Read more

## Auto Trait Implementations

### `impl Send for ImageError`

### `impl Unpin for ImageError`

### `impl Sync for ImageError`

### `impl !UnwindSafe for ImageError`

### `impl !RefUnwindSafe for ImageError`

## Blanket Implementations

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

#### `fn into(self) -> U`[src]

Performs the conversion.

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

#### `fn from(t: T) -> T`[src]

Performs the conversion.

### `impl<T> ToString for T where
T: Display + ?Sized,` [src]

#### `default fn to_string(&self) -> String`[src]

Converts the given value to a `String`. Read more

### `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.

#### `fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>`[src]

Performs the conversion.

### `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.

#### `fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>`[src]

Performs the conversion.

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

#### `fn borrow_mut(&mut self) -> &mut T`[src]

Mutably borrows from an owned value. Read more

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

#### `fn borrow(&self) -> &T`[src]

Immutably borrows from an owned value. Read more

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

#### `fn type_id(&self) -> TypeId`[src]

Gets the `TypeId` of `self`. Read more

### `impl<T> SetParameter for T`[src]

#### `fn set<T>(&mut self, value: T) -> <T as Parameter<Self>>::Result where
T: Parameter<Self>,` [src]

Sets `value` as a parameter of `self`.

# Help

## Keyboard Shortcuts

`?`
  Show this help dialog
`S`
  Focus the search field
`↑`
  Move up in search results
`↓`
  Move down in search results
`↹`
  Switch tab
`⏎`
  Go to active search result
`+`
  Expand all sections
`-`
  Collapse all sections

## Search Tricks

Prefix searches with a type followed by a colon (e.g., `fn:`) to restrict the search to a given type.

Accepted types are: `fn`, `mod`, `struct`, `enum`, `trait`, `type`, `macro`, and `const`.

Search functions by type signature (e.g., `vec -> usize` or `* -> vec`)

Search multiple things at once by splitting your query with comma (e.g., `str,u8` or `String,struct:Vec,test`)