MediaOptimizationService class
Constructors
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
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
cleanupTempFiles(
) → Future< void> - Pulisci i file temporanei creati durante l'ottimizzazione
-
fixExifRotation(
String imagePath) → Future< File> - Fix EXIF rotation issue basato sulla soluzione di Dominik Roszkowski https://roszkowski.dev/how-to-fix-rotated-image-from-camera-in-flutter/
-
optimizeImage(
XFile imageFile) → Future< XFile> - Ottimizza un'immagine mantenendo la qualità ma riducendo le dimensioni
-
optimizeVideo(
XFile videoFile, BuildContext context, {String uploadingMessage = 'Uploading video...', String waitMessage = 'Please wait', String compressionError = 'Video compression error'}) → Future< XFile?> - Comprimi un video mantenendo buona qualità ma riducendo dimensioni per upload veloce
-
validateVideoLength(
XFile videoFile, {BuildContext? context, String? videoTooLongMessage, String? videoErrorMessage}) → Future< bool> - Valida che un video non superi i 2 minuti di durata