pub struct ExternalCamera {
pub label: String,
pub url: String,
pub stream_url: Option<String>,
pub park_tuning: Option<ParkTuning>,
pub select_tuning: Option<SelectTuning>,
}Expand description
One configured external IP camera: a human label plus the snapshot URL the server proxies. The URL is an internal LAN address kept server-side — it’s only exposed on the gated config endpoint, never on the open camera listing.
Fields§
§label: String§url: String§stream_url: Option<String>Optional live MJPEG stream URL (e.g. an MJPEG /stream endpoint). When
present the server can reverse-proxy a continuous multipart stream instead
of polling url for single JPEGs. None = snapshot-only.
park_tuning: Option<ParkTuning>Optional per-camera live-park detection tuning. Present (with a stream_url)
makes the camera eligible for the park timelapse slot; the values are
camera-specific (framing), so there are no shared defaults. None = no live
park preview for this camera.
select_tuning: Option<SelectTuning>Optional per-camera burst-SELECTION tuning (the select_smooth knobs:
min_outlier/min_left_density/min_confidence/select_candidate_frac + left_frac). When
present, the serve assembles a smooth recording into a CLEAN one-frame-per-layer
timelapse (pick the parked frame per burst); absent → the raw all-frames assemble.
Implementations§
Source§impl ExternalCamera
impl ExternalCamera
Sourcepub fn new(
label: Option<String>,
url: String,
stream_url: Option<String>,
index: usize,
) -> Self
pub fn new( label: Option<String>, url: String, stream_url: Option<String>, index: usize, ) -> Self
Build from an optional label + snapshot URL + optional stream URL, filling
a blank label with a stable external N (1-based index). A blank stream
URL normalises to None. park_tuning starts None; set it with
with_park_tuning.
Sourcepub fn with_park_tuning(self, tuning: Option<ParkTuning>) -> Self
pub fn with_park_tuning(self, tuning: Option<ParkTuning>) -> Self
Attach (or clear) the per-camera live-park tuning. Chained after new.
Sourcepub fn with_select_tuning(self, tuning: Option<SelectTuning>) -> Self
pub fn with_select_tuning(self, tuning: Option<SelectTuning>) -> Self
Attach (or clear) the per-camera smooth-selection tuning. Chained after new.
Trait Implementations§
Source§impl Clone for ExternalCamera
impl Clone for ExternalCamera
Source§fn clone(&self) -> ExternalCamera
fn clone(&self) -> ExternalCamera
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ExternalCamera
impl Debug for ExternalCamera
Source§impl PartialEq for ExternalCamera
impl PartialEq for ExternalCamera
Source§fn eq(&self, other: &ExternalCamera) -> bool
fn eq(&self, other: &ExternalCamera) -> bool
self and other values to be equal, and is used by ==.