fillUnsafe method
inherited
Fill the buffer with the given pixel
.
This is equivalent to calling setUnsafe for every pixel in the buffer.
If a target
rectangle is provided, only the pixels within that rectangle
will be filled. If the rectangle is outside the bounds of the buffer, the
behavior is undefined.
Example
final pixels = IntPixels(2, 2);
pixels.fillUnsafe(0xFFFFFFFF);
pixels.fillUnsafe(0x00000000, Rect.fromLTWH(1, 0, 1, 2));
Implementation
@override
void fillUnsafe(T pixel, [Rect? target]) {
lodim.fillRectLinear(data, pixel, width: width, bounds: target);
}