use MPV commands directly
This commit is contained in:
parent
86b06bff7a
commit
0b614e8ce5
6 changed files with 20 additions and 16 deletions
|
@ -7,6 +7,7 @@ All notable changes to this project will be documented in this file.
|
|||
### Added
|
||||
|
||||
- Map: create shortcut to custom region and filters
|
||||
- Video: frame stepping forward/backward actions
|
||||
|
||||
### Fixed
|
||||
|
||||
|
|
|
@ -214,10 +214,15 @@ class MpvVideoController extends AvesVideoController {
|
|||
|
||||
@override
|
||||
Future<void> skipFrames(int frameCount) async {
|
||||
final platform = _instance.platform;
|
||||
if (platform is NativePlayer) {
|
||||
if (frameCount > 0) {
|
||||
await _instance.frameStep();
|
||||
await platform.command(['frame-step']);
|
||||
} else if (frameCount < 0) {
|
||||
await _instance.frameBackStep();
|
||||
await platform.command(['frame-back-step']);
|
||||
}
|
||||
} else {
|
||||
throw Exception('Platform player ${platform.runtimeType} does not support frame stepping');
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -180,8 +180,8 @@ packages:
|
|||
dependency: "direct main"
|
||||
description:
|
||||
path: media_kit
|
||||
ref: frame-stepping
|
||||
resolved-ref: "209221d605a0b2c34379e799a8e001cc359e6183"
|
||||
ref: fd-support
|
||||
resolved-ref: f5d6f97bc74bed33f231ea238fb47af0c57d2e07
|
||||
url: "https://github.com/deckerst/media-kit.git"
|
||||
source: git
|
||||
version: "1.1.11"
|
||||
|
@ -197,8 +197,8 @@ packages:
|
|||
dependency: "direct main"
|
||||
description:
|
||||
path: media_kit_video
|
||||
ref: frame-stepping
|
||||
resolved-ref: "209221d605a0b2c34379e799a8e001cc359e6183"
|
||||
ref: HEAD
|
||||
resolved-ref: fe317dba5d9e1bc25cb0b564a1f25607b0c7de2f
|
||||
url: "https://github.com/deckerst/media-kit.git"
|
||||
source: git
|
||||
version: "1.2.5"
|
||||
|
|
|
@ -24,12 +24,11 @@ dependency_overrides:
|
|||
media_kit:
|
||||
git:
|
||||
url: https://github.com/deckerst/media-kit.git
|
||||
ref: frame-stepping
|
||||
ref: fd-support
|
||||
path: media_kit
|
||||
media_kit_video:
|
||||
git:
|
||||
url: https://github.com/deckerst/media-kit.git
|
||||
ref: frame-stepping
|
||||
path: media_kit_video
|
||||
|
||||
dev_dependencies:
|
||||
|
|
|
@ -904,8 +904,8 @@ packages:
|
|||
dependency: "direct overridden"
|
||||
description:
|
||||
path: media_kit
|
||||
ref: frame-stepping
|
||||
resolved-ref: "209221d605a0b2c34379e799a8e001cc359e6183"
|
||||
ref: fd-support
|
||||
resolved-ref: f5d6f97bc74bed33f231ea238fb47af0c57d2e07
|
||||
url: "https://github.com/deckerst/media-kit.git"
|
||||
source: git
|
||||
version: "1.1.11"
|
||||
|
@ -921,8 +921,8 @@ packages:
|
|||
dependency: "direct overridden"
|
||||
description:
|
||||
path: media_kit_video
|
||||
ref: frame-stepping
|
||||
resolved-ref: "209221d605a0b2c34379e799a8e001cc359e6183"
|
||||
ref: HEAD
|
||||
resolved-ref: fe317dba5d9e1bc25cb0b564a1f25607b0c7de2f
|
||||
url: "https://github.com/deckerst/media-kit.git"
|
||||
source: git
|
||||
version: "1.2.5"
|
||||
|
|
|
@ -124,12 +124,11 @@ dependency_overrides:
|
|||
media_kit:
|
||||
git:
|
||||
url: https://github.com/deckerst/media-kit.git
|
||||
ref: frame-stepping
|
||||
ref: fd-support
|
||||
path: media_kit
|
||||
media_kit_video:
|
||||
git:
|
||||
url: https://github.com/deckerst/media-kit.git
|
||||
ref: frame-stepping
|
||||
path: media_kit_video
|
||||
|
||||
dev_dependencies:
|
||||
|
|
Loading…
Reference in a new issue