PixelUint8 class
Constructors
- PixelUint8.from(PixelUint8 other)
- PixelUint8.image(Image image)
- PixelUint8.imageData(ImageDataUint8 image)
Properties
- a ↔ num
- 
  Alpha channel.
  getter/setter pairoverride
- aNormalized ↔ num
- 
  Normalized [0, 1] alpha.
  getter/setter pairoverride
- b ↔ num
- 
  Blue channel.
  getter/setter pairoverride
- bNormalized ↔ num
- 
  Normalized [0, 1] blue.
  getter/setter pairoverride
- current → Pixel
- 
  The current pixel (this), for using Pixel as an iterator.
  no setteroverride
- data → Uint8List
- 
  
  no setter
- first → num
- 
  The first element.
  no setterinherited
- format → Format
- 
  The Format of the color.
  no setteroverride
- g ↔ num
- 
  Green channel.
  getter/setter pairoverride
- gNormalized ↔ num
- 
  Normalized [0, 1] green.
  getter/setter pairoverride
- hashCode → int
- 
  Calculate the hash code for this pixel.
  no setteroverride
- hasPalette → bool
- 
  True if the color uses a palette.
  no setteroverride
- height → int
- 
  The height in pixels of the image data this pixel refers to.
  no setteroverride
- image → ImageDataUint8
- 
  The ImageData this pixel refers to.
  final
- index ↔ num
- 
  Palette index value (or red channel if there is no palette).
  getter/setter pairoverride
- isEmpty → bool
- 
  Whether this collection has no elements.
  no setterinherited
- isHdrFormat → bool
- 
  True if the format is high dynamic range.
  no setteroverride
- isLdrFormat → bool
- 
  True if the format is low dynamic range.
  no setteroverride
- isNotEmpty → bool
- 
  Whether this collection has at least one element.
  no setterinherited
- isValid → bool
- 
  True if this points to a valid pixel, otherwise false.
  no setteroverride
- iterator → ChannelIterator
- 
  A new Iteratorthat allows iterating the elements of thisIterable.no setteroverride
- last → num
- 
  The last element.
  no setterinherited
- length → int
- 
  The number of channels used by the color.
  no setteroverride
- luminance → num
- 
  The luminance (grayscale) of the color.
  no setteroverride
- luminanceNormalized → num
- 
  
  no setteroverride
- maxChannelValue → num
- 
  The maximum value for a color channel.
  no setteroverride
- maxIndexValue → num
- 
  The maximum value for a palette index.
  no setteroverride
- numChannels → int
- 
  
  no setter
- palette → Palette?
- 
  The palette used by the color, or null.
  no setteroverride
- r ↔ num
- 
  Red channel.
  getter/setter pairoverride
- rNormalized ↔ num
- 
  Normalized [0, 1] red.
  getter/setter pairoverride
- runtimeType → Type
- 
  A representation of the runtime type of the object.
  no setterinherited
- single → num
- 
  Checks that this iterable has only one element, and returns that element.
  no setterinherited
- width → int
- 
  The width in pixels of the image data this pixel refers to.
  no setteroverride
- x → int
- 
  The x coordinate of the pixel.
  no setteroverride
- xNormalized → num
- 
  The normalized x coordinate of the pixel, in the range [0, 1].
  no setteroverride
- y → int
- 
  The y coordinate of the pixel.
  no setteroverride
- yNormalized → num
- 
  The normalized y coordinate of the pixel, in the range [0, 1].
  no setteroverride
Methods
- 
  any(bool test(num element)) → bool 
- 
  Checks whether any element of this iterable satisfies test.inherited
- 
  cast<R> () → Iterable< R> 
- 
  A view of this iterable as an iterable of Rinstances.inherited
- 
  clone() → PixelUint8 
- 
  Returns a copy of the color.
  override
- 
  contains(Object? element) → bool 
- 
  Whether the collection contains an element equal to element.inherited
- 
  convert({Format? format, int? numChannels, num? alpha}) → Color 
- 
  Convert the formatand/or thenumChannelsof the color. IfnumChannelsis 4 and the current color does not have an alpha value, thenalphacan specify what value to use for the new alpha channel. Ifalphais not given, then maxChannelValue will be used.override
- 
  elementAt(int index) → num 
- 
  Returns the indexth element.inherited
- 
  every(bool test(num element)) → bool 
- 
  Checks whether every element of this iterable satisfies test.inherited
- 
  expand<T> (Iterable< T> toElements(num element)) → Iterable<T> 
- 
  Expands each element of this Iterable into zero or more elements.
  inherited
- 
  firstWhere(bool test(num element), {num orElse()?}) → num 
- 
  The first element that satisfies the given predicate test.inherited
- 
  fold<T> (T initialValue, T combine(T previousValue, num element)) → T 
- 
  Reduces a collection to a single value by iteratively combining each
element of the collection with an existing value
  inherited
- 
  followedBy(Iterable< num> other) → Iterable<num> 
- 
  Creates the lazy concatenation of this iterable and other.inherited
- 
  forEach(void action(num element)) → void 
- 
  Invokes actionon each element of this iterable in iteration order.inherited
- 
  get(int ci) → num 
- 
  getChannel(Channel channel) → num 
- 
  Get a channelfrom the color. If the channel isn't available, 0 will be returned.override
- 
  getChannelNormalized(Channel channel) → num 
- 
  Get the normalized [0, 1] value of a channelfrom the color. If the channel isn't available, 0 will be returned.override
- 
  join([String separator = ""]) → String 
- 
  Converts each element to a String and concatenates the strings.
  inherited
- 
  lastWhere(bool test(num element), {num orElse()?}) → num 
- 
  The last element that satisfies the given predicate test.inherited
- 
  map<T> (T toElement(num e)) → Iterable< T> 
- 
  The current elements of this iterable modified by toElement.inherited
- 
  moveNext() → bool 
- 
  Move to the next pixel, returning false if it moved past the end of
the image data.
  override
- 
  noSuchMethod(Invocation invocation) → dynamic 
- 
  Invoked when a nonexistent method or property is accessed.
  inherited
- 
  reduce(num combine(num value, num element)) → num 
- 
  Reduces a collection to a single value by iteratively combining elements
of the collection using the provided function.
  inherited
- 
  set(Color c) → void 
- 
  Set the values of this color to the given color.override
- 
  setPosition(int x, int y) → void 
- 
  Set the coordinates of the pixel.
  override
- 
  setPositionNormalized(num x, num y) → void 
- 
  Set the normalized coordinates of the pixel, in the range [0, 1].
  override
- 
  setRgb(num r, num g, num b) → void 
- 
  Set the individual r,g,bchannels of the color.override
- 
  setRgba(num r, num g, num b, num a) → void 
- 
  Set the individual r,g,b,achannels of the color.override
- 
  singleWhere(bool test(num element), {num orElse()?}) → num 
- 
  The single element that satisfies test.inherited
- 
  skip(int count) → Iterable< num> 
- 
  Creates an Iterable that provides all but the first countelements.inherited
- 
  skipWhile(bool test(num value)) → Iterable< num> 
- 
  Creates an Iterablethat skips leading elements whiletestis satisfied.inherited
- 
  take(int count) → Iterable< num> 
- 
  Creates a lazy iterable of the countfirst elements of this iterable.inherited
- 
  takeWhile(bool test(num value)) → Iterable< num> 
- 
  Creates a lazy iterable of the leading elements satisfying test.inherited
- 
  toList({bool growable = true}) → List< num> 
- 
  Creates a List containing the elements of this Iterable.
  inherited
- 
  toSet() → Set< num> 
- 
  Creates a Set containing the same elements as this iterable.
  inherited
- 
  toString() → String 
- 
  Returns a string representation of (some of) the elements of this.inherited
- 
  updateCache() → void 
- 
  where(bool test(num element)) → Iterable< num> 
- 
  Creates a new lazy Iterable with all elements that satisfy the
predicate test.inherited
- 
  whereType<T> () → Iterable< T> 
- 
  Creates a new lazy Iterable with all elements that have type T.inherited
Operators
- 
  operator ==(Object other) → bool 
- 
  Tests if this pixel has the same values as the given pixel or color.
  override
- 
  operator [](int ci) → num 
- 
  Gets a channel from the color by its index.
  override
- 
  operator []=(int ci, num value) → void 
- 
  
  override