[][src]Module imageproc::definitions

Trait definitions and type aliases.

Traits

Clamp

A type to which we can clamp a value of type T. Implementations are not required to handle NaNs gracefully.

HasBlack

Pixels which have a named Black value.

HasWhite

Pixels which have a named White value.

Position

Something with a 2d position.

Score

Something with a score.

Type Definitions

Image

An ImageBuffer containing Pixels of type P with storage Vec<P::Subpixel>. Most operations in this library only support inputs of type Image, rather than arbitrary image::GenericImages. This is obviously less flexible, but has the advantage of allowing many functions to be more performant. We may want to add more flexibility later, but this should not be at the expense of performance. When specialisation lands we should be able to do this by defining traits for images with contiguous storage.