ProVideoController class

Controls video playback and trimming for the video editor.

Constructors

ProVideoController({required Widget videoPlayer, required Duration videoDuration, required Size initialResolution, required int fileSize, int? bitrate, AudioTrack? audioTrack, List<VideoClip>? clips, List<ImageProvider<Object>>? thumbnails, TrimDurationSpan? initialTrimSpan})
Creates a ProVideoController instance.

Properties

audioTrack ↔ AudioTrack?
The currently selected audio track.
getter/setter pair
bitrate ↔ int?
The bitrate of the video in bits per second.
getter/setter pair
callbacks → VideoEditorCallbacks
Returns the configured video editor callbacks.
no setter
callbacksAudio → AudioEditorCallbacks
Returns the configured audio editor callbacks.
no setter
clips ↔ List<VideoClip>?
The list of video clips to be loaded or edited in the current session.
getter/setter pair
configs → VideoEditorConfigs
Returns the video editor configuration settings.
no setter
endTime → Duration
The end time of the trimmed video segment.
no setter
fileSize ↔ int
The size of the video file in bytes.
getter/setter pair
hashCode → int
The hash code for this object.
no setterinherited
initialResolution ↔ Size
The initial resolution of the video.
getter/setter pair
initialTrimSpan → TrimDurationSpan?
The initial trim range applied when the editor is opened.
final
isAudioEnabled → bool
Indicates whether audio is currently enabled for the video.
no setter
isMutedNotifier → ValueNotifier<bool>
Notifies listeners of the current mute state.
latefinal
isPlayingNotifier → ValueNotifier<bool>
Notifies listeners of the current play state.
latefinal
playTimeNotifier → ValueNotifier<Duration>
Notifies listeners of the current playback position.
latefinal
resolutionNotifier → ValueNotifier<Size>
A ValueNotifier that holds the current video resolution.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
showTrimTimeSpanNotifier → ValueNotifier<bool>
Notifier that indicates whether the trim time span UI should be shown.
final
startTime → Duration
The start time of the trimmed video segment.
no setter
thumbnails ↔ List<ImageProvider<Object>>?
The thumbnails getter returns the current list of thumbnails, or null if not set.
getter/setter pair
thumbnailsNotifier → ValueNotifier<List<ImageProvider<Object>>?>
A ValueNotifier that holds a list of ImageProvider objects representing video thumbnails.
final
trimDurationSpanNotifier → ValueNotifier<TrimDurationSpan>
Notifies listeners of the selected trim duration span.
latefinal
videoDuration ↔ Duration
The total duration of the video.
getter/setter pair
videoPlayer → Widget
The video player widget.
final

Methods

dispose() → void
Dispose the video controller.
initialize({required AudioEditorCallbacks callbacksAudioFunction(), required VideoEditorCallbacks callbacksFunction(), required VideoEditorConfigs configsFunction()}) → void
Initializes the controller with provided callback and config functions.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
pause() → void
Pauses video playback and triggers the pause callback.
play() → void
Starts video playback and triggers the play callback.
setMuteState(bool isMuted) → void
Sets the mute state and triggers the mute toggle callback.
setPlayTime(Duration duration) → void
Updates the current play position.
setTrimEnd(Duration duration) → void
Sets the end time for trimming and triggers the trim update callback.
setTrimSpan(TrimDurationSpan span) → void
Updates the trim span and triggers the trim update callback.
setTrimStart(Duration duration) → void
Sets the start time for trimming and triggers the trim update callback.
togglePlayState() → void
Toggles the play state of the video.
toString() → String
A string representation of this object.
inherited

Operators

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