summaryrefslogtreecommitdiff
path: root/multimedia/mediamtx/files
diff options
context:
space:
mode:
Diffstat (limited to 'multimedia/mediamtx/files')
-rw-r--r--multimedia/mediamtx/files/patch-internal_staticsources_handler.go30
-rw-r--r--multimedia/mediamtx/files/patch-mediamtx.yml65
-rw-r--r--multimedia/mediamtx/files/patch-rpicamera77
3 files changed, 63 insertions, 109 deletions
diff --git a/multimedia/mediamtx/files/patch-internal_staticsources_handler.go b/multimedia/mediamtx/files/patch-internal_staticsources_handler.go
new file mode 100644
index 000000000000..da301f21b561
--- /dev/null
+++ b/multimedia/mediamtx/files/patch-internal_staticsources_handler.go
@@ -0,0 +1,30 @@
+--- internal/staticsources/handler.go.orig 2025-08-16 07:32:58 UTC
++++ internal/staticsources/handler.go
+@@ -13,7 +13,7 @@ import (
+ "github.com/bluenviron/mediamtx/internal/logger"
+ sshls "github.com/bluenviron/mediamtx/internal/staticsources/hls"
+ ssmpegts "github.com/bluenviron/mediamtx/internal/staticsources/mpegts"
+- ssrpicamera "github.com/bluenviron/mediamtx/internal/staticsources/rpicamera"
++// ssrpicamera "github.com/bluenviron/mediamtx/internal/staticsources/rpicamera"
+ ssrtmp "github.com/bluenviron/mediamtx/internal/staticsources/rtmp"
+ ssrtp "github.com/bluenviron/mediamtx/internal/staticsources/rtp"
+ ssrtsp "github.com/bluenviron/mediamtx/internal/staticsources/rtsp"
+@@ -146,12 +146,12 @@ func (s *Handler) Initialize() {
+ Parent: s,
+ }
+
+- case s.Conf.Source == "rpiCamera":
+- s.instance = &ssrpicamera.Source{
+- RTPMaxPayloadSize: s.RTPMaxPayloadSize,
+- LogLevel: s.LogLevel,
+- Parent: s,
+- }
++// case s.Conf.Source == "rpiCamera":
++// s.instance = &ssrpicamera.Source{
++// RTPMaxPayloadSize: s.RTPMaxPayloadSize,
++// LogLevel: s.LogLevel,
++// Parent: s,
++// }
+
+ default:
+ panic("should not happen")
diff --git a/multimedia/mediamtx/files/patch-mediamtx.yml b/multimedia/mediamtx/files/patch-mediamtx.yml
index 323871f2aded..6321735174c7 100644
--- a/multimedia/mediamtx/files/patch-mediamtx.yml
+++ b/multimedia/mediamtx/files/patch-mediamtx.yml
@@ -1,20 +1,17 @@
---- mediamtx.yml.orig 2025-04-15 18:39:24 UTC
+--- mediamtx.yml.orig 2025-08-12 20:37:33 UTC
+++ mediamtx.yml
-@@ -423,8 +423,7 @@ pathDefaults:
+@@ -450,7 +450,6 @@ pathDefaults:
# * whep://existing-url -> the stream is pulled from another WebRTC server / camera
# * wheps://existing-url -> the stream is pulled from another WebRTC server / camera with HTTPS
# * redirect -> the stream is provided by another path or server
- # * rpiCamera -> the stream is provided by a Raspberry Pi Camera
-- # The following variables can be used in the source string:
-+ # The following variables can be used in the source string:
+ # The following variables can be used in the source string:
# * $MTX_QUERY: query parameters (passed by first reader)
# * $G1, $G2, ...: regular expression groups, if path name is
- # a regular expression.
-@@ -513,99 +512,6 @@ pathDefaults:
- # path which clients will be redirected to.
+@@ -564,101 +563,7 @@ pathDefaults:
# It can be can be a relative path (i.e. /otherstream) or an absolute RTSP URL.
sourceRedirect:
--
+
- ###############################################
- # Default path settings -> Raspberry Pi Camera source (when source is "rpiCamera")
-
@@ -42,22 +39,20 @@
- # values: normal, short, long, custom.
- rpiCameraExposure: normal
- # Auto-white-balance mode.
-- # values: auto, incandescent, tungsten, fluorescent, indoor, daylight, cloudy, custom.
+- # (auto, incandescent, tungsten, fluorescent, indoor, daylight, cloudy or custom).
- rpiCameraAWB: auto
- # Auto-white-balance fixed gains. This can be used in place of rpiCameraAWB.
- # format: [red,blue].
- rpiCameraAWBGains: [0, 0]
-- # Denoise operating mode.
-- # values: off, cdn_off, cdn_fast, cdn_hq.
+- # Denoise operating mode (off, cdn_off, cdn_fast, cdn_hq).
- rpiCameraDenoise: "off"
- # Fixed shutter speed, in microseconds.
- rpiCameraShutter: 0
-- # Metering mode of the AEC/AGC algorithm.
-- # values: centre, spot, matrix, custom.
+- # Metering mode of the AEC/AGC algorithm (centre, spot, matrix or custom).
- rpiCameraMetering: centre
- # Fixed gain.
- rpiCameraGain: 0
-- # EV compensation of the image [-10, 10].
+- # EV compensation of the image in range [-10, 10].
- rpiCameraEV: 0
- # Region of interest, in format x,y,width,height (all normalized between 0 and 1).
- rpiCameraROI:
@@ -70,14 +65,11 @@
- rpiCameraMode:
- # frames per second.
- rpiCameraFPS: 30
-- # Autofocus mode.
-- # values: auto, manual, continuous.
+- # Autofocus mode (auto, manual or continuous).
- rpiCameraAfMode: continuous
-- # Autofocus range.
-- # values: normal, macro, full.
+- # Autofocus range (normal, macro or full).
- rpiCameraAfRange: normal
-- # Autofocus speed.
-- # values: normal, fast.
+- # Autofocus speed (normal or fast).
- rpiCameraAfSpeed: normal
- # Lens position (for manual autofocus only), will be set to focus to a specific distance
- # calculated by the following formula: d = 1 / value
@@ -85,7 +77,7 @@
- # 0.5 moves the lens to focus on objects 2m away.
- # 2 moves the lens to focus on objects 50cm away.
- rpiCameraLensPosition: 0.0
-- # Specifies the autofocus window, in the form x,y,width,height where the coordinates
+- # Autofocus window, in the form x,y,width,height where the coordinates
- # are given as a proportion of the entire image.
- rpiCameraAfWindow:
- # Manual flicker correction period, in microseconds.
@@ -95,18 +87,27 @@
- # Text that is printed on each frame.
- # format is the one of the strftime() function.
- rpiCameraTextOverlay: '%Y-%m-%d %H:%M:%S - MediaMTX'
-- # Codec. Available values: auto, hardwareH264, softwareH264, mjpeg.
+- # Codec (auto, hardwareH264, softwareH264 or mjpeg).
+- # When is "auto" and stream is primary, it defaults to hardwareH264 (if available) or softwareH264.
+- # When is "auto" and stream is secondary, it defaults to mjpeg.
- rpiCameraCodec: auto
-- # Period between H264 IDR frames.
+- # Period between IDR frames (when codec is hardwareH264 or softwareH264).
- rpiCameraIDRPeriod: 60
-- # H264 Bitrate.
+- # Bitrate (when codec is hardwareH264 or softwareH264).
- rpiCameraBitrate: 5000000
-- # H264 profile.
-- rpiCameraProfile: main
-- # H264 level.
-- rpiCameraLevel: '4.1'
-- # JPEG quality.
-- rpiCameraJPEGQuality: 60
-
- ###############################################
+- # Hardware H264 profile (baseline, main or high) (when codec is hardwareH264).
+- rpiCameraHardwareH264Profile: main
+- # Hardware H264 level (4.0, 4.1 or 4.2) (when codec is hardwareH264).
+- rpiCameraHardwareH264Level: '4.1'
+- # Software H264 profile (baseline, main or high) (when codec is softwareH264).
+- rpiCameraSoftwareH264Profile: baseline
+- # Software H264 level (4.0, 4.1 or 4.2) (when codec is softwareH264).
+- rpiCameraSoftwareH264Level: '4.1'
+- # M-JPEG JPEG quality (when codec is mjpeg).
+- rpiCameraMJPEGQuality: 60
+-
+- ###############################################
++ #################################################
# Default path settings -> Hooks
+
+ # Command to run when this path is initialized.
diff --git a/multimedia/mediamtx/files/patch-rpicamera b/multimedia/mediamtx/files/patch-rpicamera
deleted file mode 100644
index 57a37027af30..000000000000
--- a/multimedia/mediamtx/files/patch-rpicamera
+++ /dev/null
@@ -1,77 +0,0 @@
-From 341c1ad77717c9957993b9abebcc627007f10f15 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Krystian=20Chachu=C5=82a?= <krystian@krystianch.com>
-Date: Thu, 30 Jan 2025 23:03:57 +0100
-Subject: [PATCH] rpicamera: disable
-
----
- internal/staticsources/rpicamera/camera.go | 2 +-
- internal/staticsources/rpicamera/camera_disabled.go | 2 --
- internal/staticsources/rpicamera/camera_32.go | 2 +-
- internal/staticsources/rpicamera/camera_64.go | 2 +-
- internal/staticsources/rpicamera/params_serialize.go | 2 +-
- internal/staticsources/rpicamera/pipe.go | 2 +-
- 6 files changed, 6 insertions(+), 8 deletions(-)
-
-diff --git a/internal/staticsources/rpicamera/camera.go b/internal/staticsources/rpicamera/camera.go
-index 9db131f4..b8a41317 100644
---- internal/staticsources/rpicamera/camera.go
-+++ internal/staticsources/rpicamera/camera.go
-@@ -1,4 +1,4 @@
--//go:build (linux && arm) || (linux && arm64)
-+//go:build exclude
-
- package rpicamera
-
-diff --git a/internal/staticsources/rpicamera/camera_disabled.go b/internal/staticsources/rpicamera/camera_disabled.go
-index ac84ee59..e54ccaa3 100644
---- internal/staticsources/rpicamera/camera_disabled.go
-+++ internal/staticsources/rpicamera/camera_disabled.go
-@@ -1,5 +1,3 @@
--//go:build !linux || (!arm && !arm64)
--
- package rpicamera
-
- import (
-diff --git a/internal/staticsources/rpicamera/component_32.go b/internal/staticsources/rpicamera/camera_32.go
-index b7d19f11..51615164 100644
---- internal/staticsources/rpicamera/camera_32.go
-+++ internal/staticsources/rpicamera/camera_32.go
-@@ -1,4 +1,4 @@
--//go:build linux && arm
-+//go:build exclude
-
- package rpicamera
-
-diff --git a/internal/staticsources/rpicamera/component_64.go b/internal/staticsources/rpicamera/camera_64.go
-index 690bf567..ed2e89dd 100644
---- internal/staticsources/rpicamera/camera_64.go
-+++ internal/staticsources/rpicamera/camera_64.go
-@@ -1,4 +1,4 @@
--//go:build linux && arm64
-+//go:build exclude
-
- package rpicamera
-
-diff --git a/internal/staticsources/rpicamera/params_serialize.go b/internal/staticsources/rpicamera/params_serialize.go
-index d9e023b1..845725f3 100644
---- internal/staticsources/rpicamera/params_serialize.go
-+++ internal/staticsources/rpicamera/params_serialize.go
-@@ -1,4 +1,4 @@
--//go:build (linux && arm) || (linux && arm64)
-+//go:build exclude
-
- package rpicamera
-
-diff --git a/internal/staticsources/rpicamera/pipe.go b/internal/staticsources/rpicamera/pipe.go
-index 44eb3bf1..00be2658 100644
---- internal/staticsources/rpicamera/pipe.go
-+++ internal/staticsources/rpicamera/pipe.go
-@@ -1,4 +1,4 @@
--//go:build (linux && arm) || (linux && arm64)
-+//go:build exclude
-
- package rpicamera
-
---
-2.47.1
-