Skip to content

Decide timing and seams of format changes via in-place stream/start #294

Closed

Description

@maximmaxim345

roles/player/v1.md says the first chunk in the new format MUST follow the last chunk in the previous format, and that servers MUST NOT resend audio already sent.

When should the player hear the new format?

  1. After the audio already sent (current spec). Gapless and nothing is sent twice, but it's only heard once the buffer plays out.
  2. Same, but audio still queued on the server doesn't count as sent, so the server can drop it. Spec clarification only.
  3. Right away, with a new opt-in message that drops buffered audio from a timestamp onward (kepstin's idea on Discord, also useful for changing the next track).
  4. Right away, with stream/clear. Works today, but leaves a gap and resends the whole buffer.

A server sharing one encoder between players can only switch at that encoder's next chunk boundary. How should that be handled?

  1. Allow a gap shorter than one chunk, no overlap. No client change, since players already fill gaps with silence. aiosendspin does this today.
  2. Keep the exact rule and bridge with a short chunk from a separate encoder. More server work, and awkward for Opus.
  3. Allow an overlap and define which copy the player keeps. Needs a client change.

Related:

Activity

  1. shadialhasan commented on Oct 1, 2026

    @shadialhasan
  2. changed the title [-]Allow a small seam when a format change continues the player timeline[/-] [+]Decide timing and seams of format changes via in-place `stream/start`[/+] on Oct 7, 2026
  3. self-assigned this
    on Oct 7, 2026
  4. added a commit that references this issue on Nov 19, 2026
    e170f05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions