data property
Raw pixel data for the image.
For single-frame images this is exactly frameSize bytes.
For multi-frame images (e.g. animated GIFs) this is frameSize * frameCount bytes.
Implementation
@override get data {
structOnOp((p) => _dataPtr = p.readerAt(_o[.data]).Uint8Pointer());
if (_dataPtr.isNotNull) _data = _dataPtr.view(dataLength);
return _data;
}
Raw pixel data for the image.
For single-frame images this is exactly frameSize bytes.
For multi-frame images (e.g. animated GIFs) this is frameSize * frameCount bytes.
Implementation
@override set data(Uint8List value) {
assert(value.length <= dataLength);
_data = value;
structOnOp((p) => _dataPtr = p.readerAt(_o[.data]).Uint8Pointer());
if (_dataPtr.isNotNull) _dataPtr.setAll(value);
}