style: apply rustfmt to establish clean baseline before refactor
Pre-refactor baseline state: - 79 lib tests + 3 integration tests pass (1 integration test #[ignore]) - cargo clippy --all-targets -- -D warnings clean - cargo build --release clean No semantic changes; only rustfmt drift correction across 6 files.
This commit is contained in:
+9
-13
@@ -90,7 +90,6 @@ pub struct PartialOutputInfo {
|
||||
pub done_count: u32,
|
||||
}
|
||||
|
||||
|
||||
/// Marker for wlr-output-management heads seen during probing; tracked by name
|
||||
/// in `EncConstructionStage::ProbingOutputs.wlr_heads`.
|
||||
// `pub(crate)` (not module-private): exposed via `EncConstructionStage::ProbingOutputs.wlr_heads`
|
||||
@@ -121,7 +120,10 @@ impl StreamingEncoder {
|
||||
}
|
||||
}
|
||||
|
||||
fn encode_frame(&mut self, hw_frame: &ffmpeg_next::frame::Video) -> anyhow::Result<crate::avhw::EncodeStages> {
|
||||
fn encode_frame(
|
||||
&mut self,
|
||||
hw_frame: &ffmpeg_next::frame::Video,
|
||||
) -> anyhow::Result<crate::avhw::EncodeStages> {
|
||||
match self {
|
||||
StreamingEncoder::Mp4(enc) => enc.encode_frame(hw_frame),
|
||||
StreamingEncoder::WebRtc(enc) => enc.encode_frame(hw_frame),
|
||||
@@ -704,9 +706,7 @@ impl<S: CaptureSource> State<S> {
|
||||
continue;
|
||||
}
|
||||
count += 1;
|
||||
if let Err(e) = wrtc
|
||||
.write_h264_frame(&enc_frame.data, enc_frame.pts_ticks)
|
||||
{
|
||||
if let Err(e) = wrtc.write_h264_frame(&enc_frame.data, enc_frame.pts_ticks) {
|
||||
tracing::debug!("WebRTC write frame error: {e}");
|
||||
}
|
||||
self.stats.record_send(0.0, None);
|
||||
@@ -881,7 +881,8 @@ impl<S: CaptureSource> State<S> {
|
||||
}
|
||||
} else {
|
||||
// done_count >= 1 implies transform arrived (Geometry precedes Done).
|
||||
if info.done_count < 1 || !wlr_manager_done || info.transform.is_none() {
|
||||
if info.done_count < 1 || !wlr_manager_done || info.transform.is_none()
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
@@ -1154,10 +1155,7 @@ impl<S: CaptureSource> Dispatch<WlOutput, OutputId> for State<S> {
|
||||
};
|
||||
|
||||
match event {
|
||||
OutputEvent::Geometry {
|
||||
transform,
|
||||
..
|
||||
} => {
|
||||
OutputEvent::Geometry { transform, .. } => {
|
||||
let t = match transform {
|
||||
wayland_client::WEnum::Value(WlTransform::Normal) => Transform::Normal,
|
||||
wayland_client::WEnum::Value(WlTransform::_90) => Transform::Normal90,
|
||||
@@ -1527,9 +1525,7 @@ impl<S: CaptureSource> Dispatch<ZwlrOutputHeadV1, ()> for State<S> {
|
||||
..
|
||||
} = &mut state.stage
|
||||
{
|
||||
wlr_heads
|
||||
.entry(name.clone())
|
||||
.or_insert(WlrHeadInfo {});
|
||||
wlr_heads.entry(name.clone()).or_insert(WlrHeadInfo {});
|
||||
wlr_head_proxy_to_name.insert(proxy.id(), name);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user