VideoPlayerController.file constructor
VideoPlayerController.file(
- File file, {
- Future<
ClosedCaptionFile> ? closedCaptionFile, - VideoPlayerOptions? videoPlayerOptions,
Constructs a VideoPlayerController playing a video from a file.
This will load the file from the file-URI given by:
'file://${file.path}'
.
Implementation
VideoPlayerController.file(File file,
{Future<ClosedCaptionFile>? closedCaptionFile, this.videoPlayerOptions})
: _closedCaptionFileFuture = closedCaptionFile,
dataSource = 'file://${file.path}',
dataSourceType = DataSourceType.file,
package = null,
formatHint = null,
httpHeaders = const <String, String>{},
super(VideoPlayerValue(duration: Duration.zero));