getScaledFileInfo method

  1. @override
ScaleInfo getScaledFileInfo(
  1. File file,
  2. int? width,
  3. int? height
)
override

Implementation

@override
ScaleInfo getScaledFileInfo(File file, int? width, int? height) {
  final format = _getCompressionFormat(file);

  final directory = file.parent;
  final destPath = directory.path +
      "/" +
      p.basenameWithoutExtension(file.path) +
      sprintf(tmpFileSuffix, [width ?? 1, height ?? 1]) +
      _extensionFormats[format]!;
  final scaleFile = File(destPath);
  return ScaleInfo(scaleFile, width ?? 1, height ?? 1, format);
}