From 5db925b7445adfae3c3c857e520a0428114b49d1 Mon Sep 17 00:00:00 2001 From: Max Date: Sun, 21 Jan 2024 18:23:05 +0100 Subject: [PATCH 1/2] Add STREAM_HEIGHT option to libcamera.conf --- configs/libcamera.conf | 3 +++ 1 file changed, 3 insertions(+) diff --git a/configs/libcamera.conf b/configs/libcamera.conf index 2130940..824b2b2 100644 --- a/configs/libcamera.conf +++ b/configs/libcamera.conf @@ -9,6 +9,9 @@ PORT=8080 WIDTH=1920 HEIGHT=1080 +# The height to use for the direct stream. Defaults to 480. +STREAM_HEIGHT=480 + # The height to use for the video stream. Defaults to 720. VIDEO_HEIGHT=720 From 31c5803a76de5101136630cb41f8d7133bcbca3d Mon Sep 17 00:00:00 2001 From: Max Date: Sun, 21 Jan 2024 18:24:06 +0100 Subject: [PATCH 2/2] Parse STREAM_HEIGHT option in libcamera.service --- systemd/camera-streamer-libcamera.service | 1 + 1 file changed, 1 insertion(+) diff --git a/systemd/camera-streamer-libcamera.service b/systemd/camera-streamer-libcamera.service index d1f8de8..c0e0f8a 100644 --- a/systemd/camera-streamer-libcamera.service +++ b/systemd/camera-streamer-libcamera.service @@ -14,6 +14,7 @@ ExecStart=/bin/sh -c "exec /usr/bin/camera-streamer \ --camera-path=$(/usr/bin/libcamera-hello --list-cameras | grep -o '/base/soc/[^)]*' | head -n1) \ --camera-format=YUYV \ --camera-width=${WIDTH} --camera-height=${HEIGHT} \ + --camera-stream.height=${STREAM_HEIGHT} \ --camera-video.height=${VIDEO_HEIGHT} \ --camera-snapshot.height=${SNAPSHOT_HEIGHT} \ --camera-fps=${FRAMERATE} \