PixelFormat<P, C> class
abstract
base
mixin
Pixel Formats
Describes the organization and characteristics of pixel data P
in memory.
A pixel format is essentially a set of rules and static-like methods that define how to work with pixels of a specific format without requiring boxing of pixels. Several built-in pixel formats are provided, such as abgr8888 and floatRgba.
///
- Implementers
- Annotations
Properties
- bytesPerPixel → int
-
Number of bytes required to store a single pixel in memory.
no setter
- hashCode → int
-
The hash code for this object.
no setterinherited
- max → P
-
The maximum value for the pixel format.
no setter
- name → String
-
Human-readable name or description of the pixel format.
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- zero → P
-
The zero, or minimum, value for the pixel format.
no setter
Methods
-
clamp(
P pixel) → P -
Clamps a
pixel
to the valid range of values for the pixel format. -
compare(
P a, P b) → double - Compares two pixels in the pixel format.
-
convert<
R> (R pixel, {required PixelFormat< R, void> from}) → P -
Converts a pixel
from
one another format tothis
format. -
copyWith(
P pixel) → P -
Returns a copy of the
pixel
. -
copyWithNormalized(
P pixel) → P -
Returns a copy of the
pixel
with normalized values. -
describe(
P pixel) → String - Returns a human-readable description of the pixel.
-
distance(
P a, P b) → double - Returns the distance between two pixels in the pixel format.
-
fromAbgr8888(
int pixel) → P -
Converts a pixel in the abgr8888 pixel format to
this
pixel format. -
fromFloatRgba(
Float32x4 pixel) → P -
Converts a pixel in the floatRgba pixel format to
this
pixel format. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toAbgr8888(
P pixel) → int -
Converts a pixel in
this
pixel format to the abgr8888 pixel format. -
toFloatRgba(
P pixel) → Float32x4 -
Converts a pixel in
this
pixel format to the floatRgba pixel format. -
toString(
) → String -
A string representation of this object.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited