decodeImageFile function

Image? decodeImageFile(
  1. String filePath
)

Implementation

Image? decodeImageFile(String filePath) {
  final image = decodeImage(File(filePath).readAsBytesSync());
  if (image == null) {
    throw NoDecoderForImageFormatException(filePath);
  }
  return image;
}