ResizeImage constructor
- ImageProvider<
Object> imageProvider, { - int? width,
- int? height,
- ResizeImagePolicy policy = ResizeImagePolicy.exact,
- bool allowUpscaling = false,
Creates an ImageProvider that decodes the image to the specified size.
The cached image will be directly decoded and stored at the resolution
defined by width and height. The image will lose detail and
use less memory if resized to a size smaller than the native size.
At least one of width and height must be non-null.
Implementation
const ResizeImage(
this.imageProvider, {
this.width,
this.height,
this.policy = ResizeImagePolicy.exact,
this.allowUpscaling = false,
}) : assert(width != null || height != null);