Add embedded mpv player (render API + QOpenGLWidget)
New ytsage/gui/ytsage_gui_player.py: - MpvRenderWidget hosts libmpv through MpvRenderContext in a QOpenGLWidget - works on native Wayland where wid-embedding cannot - with all mpv-thread callbacks marshalled to the GUI thread via queued signals only. - PlayerPanel adds transport controls: play/pause, seek slider, time display, quality selector (caps ytdl-format height and reloads in place), speed, volume (persisted), subtitle toggle, fullscreen (reparent to top-level window), and Space/F/Escape keys. - Playback resolves watch URLs through mpv's ytdl_hook pointed at the app-managed SHA256-verified yt-dlp binary (script-opts ytdl_hook-ytdl_path), inheriting cookies and proxy settings via ytdl-raw-options - stream freshness, DASH muxing and nsig handling stay in yt-dlp's hands. New ytsage/core/ytsage_mpv.py probes libmpv availability; without it the Watch UI shows a per-OS install hint and everything else works. python-mpv added to dependencies (libmpv itself is a system package). Config gains player.* and feed.* defaults. Verified on Wayland: real YouTube video streams with position/duration signals flowing and no thread-safety errors. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -639,5 +639,14 @@
|
||||
"update_success": "✅ Deno has been successfully updated!",
|
||||
"update_failed": "❌ Update failed: {error}",
|
||||
"check_failed": "Failed to check for updates. Please check your internet connection."
|
||||
},
|
||||
"player": {
|
||||
"quality_auto": "Auto",
|
||||
"subtitles": "CC",
|
||||
"unavailable": "Video player unavailable",
|
||||
"now_playing": "Now Playing",
|
||||
"queue": "Queue",
|
||||
"play": "Play",
|
||||
"pause": "Pause"
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user