fix: demote Pi5 hw H265 decoder — sw fallback for non-standard resolutions

This commit is contained in:
Mitchell R 2026-05-10 20:52:25 +02:00
parent 246febcc80
commit 61ab099f87

View file

@ -4,6 +4,7 @@ mod pipeline;
mod ui; mod ui;
use gtk4::prelude::{ApplicationExt, ApplicationExtManual}; use gtk4::prelude::{ApplicationExt, ApplicationExtManual};
use tracing::info;
use tracing_subscriber::EnvFilter; use tracing_subscriber::EnvFilter;
fn main() { fn main() {
@ -12,6 +13,12 @@ fn main() {
.init(); .init();
gstreamer::init().expect("Failed to init GStreamer"); gstreamer::init().expect("Failed to init GStreamer");
// Demote Pi5 hw H265 decoder — rejects non-standard resolutions like 960x1080
if let Some(factory) = gstreamer::ElementFactory::find("v4l2slh265dec") {
factory.set_rank(gstreamer::Rank::NONE);
info!("demoted v4l2slh265dec to NONE (sw fallback)");
}
let app = ui::build_app(); let app = ui::build_app();
// Pass empty args to GTK — server URL handled via env or argv directly // Pass empty args to GTK — server URL handled via env or argv directly
app.set_flags(gtk4::gio::ApplicationFlags::NON_UNIQUE); app.set_flags(gtk4::gio::ApplicationFlags::NON_UNIQUE);