Skip to content

docs: explain interleaved stream callback samples - #1430

Open
Charlie284 wants to merge 1 commit into
RustAudio:masterfrom
Charlie284:devin/1795405792-document-channel-interleaving
Open

Charlie284 wants to merge 1 commit into
RustAudio:masterfrom
Charlie284:devin/1795405792-document-channel-interleaving

Conversation

@Charlie284

Copy link
Copy Markdown

Fixes #735.

Documents the interleaved sample layout that stream callbacks receive:

  • Data gets a "Sample layout" section: samples are interleaved by frame (one sample per channel), with a doctest showing how to split a two-channel slice into frames with chunks_exact(channels). It also says interleaving does not define which speaker or input each channel index maps to.
  • The build_input_stream, build_output_stream and duplex stream docs link to that section.
  • One CHANGELOG entry.

Docs only, no runtime changes. Checked on Linux with cargo fmt --check, cargo build/cargo test --workspace (new doctest passes), cargo clippy --all-targets -D warnings, and RUSTDOCFLAGS=-Dwarnings cargo doc --no-deps.

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add (more clear?) information to the docs on how channels work in terms of streams.

1 participant