startDecode method
Start decoding the data as an animation sequence, but don't actually process the frames until they are requested with decodeFrame.
Implementation
@override
DecodeInfo? startDecode(Uint8List bytes) {
// Use a heuristic to detect potential apple PVRTC formats
if (_countBits(bytes.length) == 1) {
// very likely to be apple PVRTC
final info = _decodeApplePvrtcHeader(bytes);
if (info != null) {
_data = bytes;
return _info = info;
}
}
var info = _decodePvr3Header(bytes);
if (info != null) {
_data = bytes;
return _info = info;
}
info = _decodePvr2Header(bytes);
if (info != null) {
_data = bytes;
return _info = info;
}
return null;
}