ImagePickerMaster class

A powerful and versatile file picker plugin for Flutter that supports multiple file types including images, videos, audio files, and documents across all platforms (Android, iOS, Windows, macOS, Linux, Web).

This plugin provides a unified API for file selection with features like:

  • Multiple file selection
  • File type filtering
  • Image compression
  • Cross-platform compatibility
  • Support for 170+ file formats

Properties

hashCode → int
The hash code for this object.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

capturePhoto({bool allowCompression = true, int compressionQuality = 80, bool withData = false}) → Future<PickedFile?>
Captures a photo using the device camera.
clearTemporaryFiles() → Future<void>
Clears all temporary files created by the plugin.
cropImageNative({required String path, required double cropX, required double cropY, required double cropW, required double cropH, required double containerW, required double containerH, int rotation = 0, int quality = 85, String format = 'jpeg', int maxSize = 1200}) → Future<String?>
Crops an image natively without going through a Dart isolate.
getPlatformVersion() → Future<String?>
Returns the platform version string.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
pickAudio({bool withData = false}) → Future<PickedFile?>
Picks a single audio file from the device storage.
pickAudios({bool allowMultiple = true, bool withData = false}) → Future<List<PickedFile>?>
Picks multiple audio files from the device storage.
pickDocument({List<String>? allowedExtensions, bool withData = false}) → Future<PickedFile?>
Picks a single document file from the device storage.
pickDocuments({bool allowMultiple = true, List<String>? allowedExtensions, bool withData = false}) → Future<List<PickedFile>?>
Picks multiple document files from the device storage.
pickFiles({FileType type = FileType.all, bool allowMultiple = false, List<String>? allowedExtensions, bool withData = false, bool allowCompression = false, int? compressionQuality}) → Future<List<PickedFile>?>
Picks files from the device storage with customizable options.
pickImage({bool allowCompression = true, int compressionQuality = 80, bool withData = false}) → Future<PickedFile?>
Picks a single image file from the device storage.
pickImages({bool allowMultiple = true, bool allowCompression = true, int compressionQuality = 80, bool withData = false}) → Future<List<PickedFile>?>
Picks multiple image files from the device storage.
pickVideo({bool withData = false}) → Future<PickedFile?>
Picks a single video file from the device storage.
pickVideos({bool allowMultiple = true, bool withData = false}) → Future<List<PickedFile>?>
Picks multiple video files from the device storage.
resizeImageForCropper({required String path, int maxSize = 1024}) → Future<String?>
Resizes an image natively for use in a cropper UI.
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited

Static Properties

instance → ImagePickerMaster
Gets the singleton instance of ImagePickerMaster.
no setter