* opt: ao

* multi select

---------

Co-authored-by: dom <githubaccount56556@proton.me>
This commit is contained in:
My-Responsitories
2026-01-26 14:11:48 +08:00
committed by GitHub
parent 038f03a4e7
commit bfb2becb2d
10 changed files with 123 additions and 65 deletions

View File

@@ -796,8 +796,7 @@ class PlPlayerController {
await pp.setProperty("af", "scaletempo2=max-speed=8");
if (Platform.isAndroid) {
await pp.setProperty("volume-max", "100");
final ao = Pref.useOpenSLES ? "opensles,aaudio" : "aaudio,opensles";
await pp.setProperty("ao", ao);
await pp.setProperty("ao", Pref.audioOutput);
}
// video-sync=display-resample
await pp.setProperty("video-sync", Pref.videoSync);

View File

@@ -0,0 +1,14 @@
import 'package:PiliPlus/models/common/enum_with_label.dart';
enum AudioOutput implements EnumWithLabel {
aaudio('AAudio'),
opensles('OpenSL ES'),
audiotrack('AudioTrack')
;
static final defaultValue = values.map((e) => e.name).join(',');
@override
final String label;
const AudioOutput(this.label);
}