UiCanvas.forRecorder constructor
Creates a canvas with picture recording for cached tile generation.
This constructor creates a canvas that records drawing operations into a picture that can be cached and reused for improved performance.
width Width of the canvas in logical pixels
height Height of the canvas in logical pixels
Implementation
UiCanvas.forRecorder(double width, double height)
: _pictureRecorder = ui.PictureRecorder(),
_size = ui.Size(width, height),
assert(width >= 0),
assert(height >= 0) {
_uiCanvas = ui.Canvas(_pictureRecorder!);
}