MCPcopy Create free account
hub / github.com/PerroEngine/Perro / compressed_bytes

Method compressed_bytes

perro_source/audio_stack/perro_pawdio/src/mic.rs:165–167  ·  view source on GitHub ↗
(&self)

Source from the content-addressed store, hash-verified

163 }
164
165 fn unpack_v1(bytes: &[u8]) -> Result<Self, String> {
166 let channels = u16::from_le_bytes([bytes[6], bytes[7]]);
167 let sample_rate = u32::from_le_bytes([bytes[8], bytes[9], bytes[10], bytes[11]]);
168 let frames = u32::from_le_bytes([bytes[12], bytes[13], bytes[14], bytes[15]]) as usize;
169 let payload = &bytes[PMIC_HEADER_LEN..];
170 let samples = decode_pcm_payload(payload, frames, channels)?;

Callers

nothing calls this directly

Calls 1

packMethod · 0.45

Tested by

no test coverage detected