TiffParallelDecoder class

Decodes a TIFF/BigTIFF page in horizontal bands across a pool of isolates — the parallel counterpart to TiffImage.decodeRegionRgba8's single-call, single-core decode, for a page too large to want to decode serially. Every knob here (band height, chunk memory budget, worker count) is an explicit parameter the caller supplies — this class reads no process/OS memory state of its own and makes no assumption about how many CPU cores are safe to use; that judgment belongs to the caller, which is in a much better position to know what else is competing for the same machine's memory and cores.

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Methods

decodeBanded({required String filePath, required int pageIndex, required int bandHeight, required int maxBytesPerChunk, required int workerCount, required void onBand(TiffBand band), void setUpIsolate()?}) Future<void>
Decodes page pageIndex of the file at filePath in horizontal bands, spread across up to workerCount isolates — each opens its own handle on filePath (a decoded TiffImage and its underlying file handle can't cross an isolate boundary, so there's no way to share one already-open document across workers). onBand is called back on the caller's isolate once per decoded band, so it can do arbitrary work per band — write a file, accumulate into a buffer, feed a progress counter — without that work itself needing to be isolate-safe. Bands from different workers can interleave, so don't assume they arrive in increasing TiffBand y order across the whole page (they do arrive in order within any one worker's own share of it).