From 1b926c001a174ff217c8944e7d39b337f3a5f5b0 Mon Sep 17 00:00:00 2001 From: Kostya Shishkov Date: Mon, 16 Nov 2026 20:34:56 +0100 Subject: [PATCH] nihav_codec_support: fix documentation --- nihav-codec-support/src/codecs/mod.rs | 1 + nihav-codec-support/src/dsp/qmf.rs | 8 ++++---- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/nihav-codec-support/src/codecs/mod.rs b/nihav-codec-support/src/codecs/mod.rs index 3f98be4..00aaf37 100644 --- a/nihav-codec-support/src/codecs/mod.rs +++ b/nihav-codec-support/src/codecs/mod.rs @@ -125,6 +125,7 @@ impl IPShuffler { /// }, /// // handle the rest of cases /// }; +/// } /// if is_random_access_frame { /// shuffler.clear(); // remove all saved references /// } diff --git a/nihav-codec-support/src/dsp/qmf.rs b/nihav-codec-support/src/dsp/qmf.rs index 90cedc4..2d11002 100644 --- a/nihav-codec-support/src/dsp/qmf.rs +++ b/nihav-codec-support/src/dsp/qmf.rs @@ -1,6 +1,6 @@ //! Quadrature Mirror Filter used in various audio codecs like MPEG Audio. -///! 32-band QMF. +/// 32-band QMF. pub struct QMF { hist: [f32; 1024], pos: usize, @@ -180,14 +180,14 @@ fn dct32(src: &[f32; 32], dst: &mut [f32]) { } impl QMF { - ///! Constructs a new `QMF` context. + /// Constructs a new `QMF` context. pub fn new() -> Self { Self { hist: [0.0; 1024], pos: 0, } } - ///! Performs reconstruction of audio from provided sub-band samples. + /// Performs reconstruction of audio from provided sub-band samples. pub fn synth(&mut self, src: &[f32; 32], dst: &mut [f32]) { self.pos = self.pos.wrapping_sub(32) & 0x1FF; dct32(src, &mut self.hist[self.pos..][..32]); @@ -214,7 +214,7 @@ impl QMF { dst[i] = acc; } } - ///! Resets internal filter state. + /// Resets internal filter state. pub fn reset(&mut self) { self.hist = [0.0; 1024]; self.pos = 0; -- 2.47.3