mirror of
https://github.com/bleackstorm/SteamFrame-FPV-Control-Center.git
synced 2026-12-03 07:31:57 +01:00
fix(gpui): resolve GPU atlas VRAM leak and GStreamer pipeline latency
- Fix unbounded Blade texture atlas allocation in GPUI by recycling textures via window.drop_image() with a 2-frame safety buffer. - Correct RGBA to BGRA color channel order for GPUI polychrome texture atlas. - Optimize GStreamer UDP pipeline: increase socket buffer to 4MB, add rtpjitterbuffer for zero-latency drops, scale before colorspace conversion. - Add log filter controls (All, Warn/Err, Err) to GPUI console drawer. - Benchmark: memory consumption stays completely flat at ~258 MB over time.
This commit is contained in:
1 parent
be48fbdedf
commit
0fbe184716
4 files changed
+105
-18
No files matched your search
+4
-2
@@ -10,6 +10,7 @@ use std::thread;
|
||||
use std::time::Instant;
|
||||
|
||||
#[derive(Clone)]
|
||||
#[allow(dead_code)]
|
||||
pub struct VideoFrame {
|
||||
pub width: u32,
|
||||
pub height: u32,
|
||||
@@ -69,6 +70,7 @@ impl UsbVideoReceiver {
|
||||
let depay_and_parse = if stream_transport.eq_ignore_ascii_case("rtp") {
|
||||
format!(
|
||||
"application/x-rtp,media=video,clock-rate=90000,encoding-name={codec_name},payload=96 ! \
|
||||
rtpjitterbuffer latency=0 drop-on-latency=true ! \
|
||||
{depay} ! {parser} config-interval=-1"
|
||||
)
|
||||
} else {
|
||||
@@ -81,10 +83,10 @@ impl UsbVideoReceiver {
|
||||
);
|
||||
|
||||
format!(
|
||||
"udpsrc address={bind_ip} port={port} buffer-size=524288 retrieve-sender-address=false ! \
|
||||
"udpsrc address={bind_ip} port={port} buffer-size=4194304 retrieve-sender-address=false ! \
|
||||
{depay_and_parse} ! \
|
||||
{decoder} ! \
|
||||
videoconvert n-threads=2 ! videoscale method=1 ! \
|
||||
videoscale ! videoconvert ! \
|
||||
video/x-raw,format=RGBA,width={target_width},height={target_height} ! \
|
||||
appsink name=fpv_sink sync=false max-buffers=1 drop=true emit-signals=true"
|
||||
)
|
||||
|
||||
Reference in new issue
Block a user