getMultiImage method

  1. @Deprecated('Switch to using pickMultiImage instead')
Future<List<PickedFile>?> getMultiImage({
  1. double? maxWidth,
  2. double? maxHeight,
  3. int? imageQuality,
})

Returns a List<PickedFile> object wrapping the images that were picked.

The returned List<PickedFile> is intended to be used within a single app session. Do not save the file path and use it across sessions.

Where iOS supports HEIC images, Android 8 and below doesn't. Android 9 and above only support HEIC images if used in addition to a size modification, of which the usage is explained below.

This method is not supported in iOS versions lower than 14.

If specified, the images will be at most maxWidth wide and maxHeight tall. Otherwise the images will be returned at it's original width and height. The imageQuality argument modifies the quality of the images, ranging from 0-100 where 100 is the original/max quality. If imageQuality is null, the images with the original quality will be returned. Compression is only supported for certain image types such as JPEG and on Android PNG and WebP, too. If compression is not supported for the image that is picked, a warning message will be logged.

The method could throw PlatformException if the app does not have permission to access the camera or photos gallery, no camera is available, plugin is already in use, temporary file could not be created (iOS only), plugin activity could not be allocated (Android only) or due to an unknown error.

See also getImage to allow users to only pick a single image.

Implementation

@Deprecated('Switch to using pickMultiImage instead')
Future<List<PickedFile>?> getMultiImage({
  double? maxWidth,
  double? maxHeight,
  int? imageQuality,
}) {
  return platform.pickMultiImage(
    maxWidth: maxWidth,
    maxHeight: maxHeight,
    imageQuality: imageQuality,
  );
}