UMediaConfig class
Player settings: buffering, hardware decoding, audio focus, wake lock, notification. UMediaConfig.music
Constructors
- UMediaConfig({bool autoPlay = false, bool muted = false, double volume = 1, double speed = 1, URepeatMode repeat = URepeatMode.off, bool shuffle = false, UHwAccel hwAccel = UHwAccel.auto, int minBufferMs = 15000, int maxBufferMs = 50000, int bufferForPlaybackMs = 2500, int bufferForPlaybackAfterRebufferMs = 5000, int maxCacheBytes = 0, Duration positionUpdateInterval = const Duration(milliseconds: 250), UAudioFocusPolicy focusPolicy = UAudioFocusPolicy.exclusive, bool pauseOnBecomingNoisy = true, bool wakeLock = true, bool allowBackgroundPlayback = false, bool preloadNext = true, bool gapless = true, Duration? crossfade, String? preferredAudioLanguage, String? preferredSubtitleLanguage, bool subtitlesEnabled = true, int maxHeight = 0, int maxCellularHeight = 0, bool abrEnabled = true, int preferredHeight = 0, int retryLimit = 3, Duration retryDelay = const Duration(seconds: 2), Duration connectTimeout = const Duration(seconds: 15), UMediaLogLevel logLevel = UMediaLogLevel.error})
-
const
Properties
- abrEnabled → bool
-
final
- allowBackgroundPlayback → bool
-
final
- autoPlay → bool
-
final
- bufferForPlaybackAfterRebufferMs → int
-
final
- bufferForPlaybackMs → int
-
final
- connectTimeout → Duration
-
final
- crossfade → Duration?
-
final
- focusPolicy → UAudioFocusPolicy
-
final
- gapless → bool
-
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- hwAccel → UHwAccel
-
final
- logLevel → UMediaLogLevel
-
final
- maxBufferMs → int
-
final
- maxCacheBytes → int
-
final
- maxCellularHeight → int
-
final
- maxHeight → int
-
final
- minBufferMs → int
-
final
- muted → bool
-
final
- pauseOnBecomingNoisy → bool
-
final
- positionUpdateInterval → Duration
-
final
- preferredAudioLanguage → String?
-
final
- preferredHeight → int
-
final
- preferredSubtitleLanguage → String?
-
final
- preloadNext → bool
-
final
- repeat → URepeatMode
-
final
- retryDelay → Duration
-
final
- retryLimit → int
-
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- shuffle → bool
-
final
- speed → double
-
final
- subtitlesEnabled → bool
-
final
- volume → double
-
final
- wakeLock → bool
-
final
Methods
-
copyWith(
{bool? autoPlay, bool? muted, double? volume, double? speed, URepeatMode? repeat, bool? shuffle, int? maxHeight, bool? abrEnabled, bool? allowBackgroundPlayback, bool? subtitlesEnabled, String? preferredSubtitleLanguage, String? preferredAudioLanguage, Duration? crossfade}) → UMediaConfig -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toMap(
) → Map< String, Object?> -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Constants
- music → const UMediaConfig
- video → const UMediaConfig