Skip to content

NIP-71 feat: video multiple audio tracks#2255

Open
1-leo wants to merge 4 commits intonostr-protocol:masterfrom
1-leo:master
Open

NIP-71 feat: video multiple audio tracks#2255
1-leo wants to merge 4 commits intonostr-protocol:masterfrom
1-leo:master

Conversation

@1-leo
Copy link

@1-leo 1-leo commented Mar 6, 2026

adds audio imeta tags:

  ["imeta",
    "url https://myaudio.com/audio/en/12345.mp4",
    "x b2e0a7a82ac9f3f3a71f1d9a78c381d5be9d1cf19dce258765c17c8a76287c93",
    "m audio/mp4",
    "l", "en", "ISO-639-1", "ov",
    "fallback https://myotherserver.com/audio/en/12345.mp4",
    "fallback https://andanotherserver.com/audio/en/12345.mp4",
    "service nip96",
    "bitrate  320000",
    "duration 29.24"
  ],

allows:

  • Audio-only streaming (video podcasts)
  • Switching resolution while audio stays stable
  • Multiple audio languages and formats (DTS, etc.)
  • Reduced storage if servers do not embed audio directly into video files

caveats:
Clients should check if audio tracks are available.
This is especially important if servers optimize for storage by not embedding audio directly into the video files.

@vitorpamplona
Copy link
Collaborator

IMO, Audio MUST always have waveforms. Follow https://github.com/nostr-protocol/nips/blob/master/A0.md for guidance there.

@1-leo
Copy link
Author

1-leo commented Mar 6, 2026

IMO, Audio MUST always have waveforms. Follow https://github.com/nostr-protocol/nips/blob/master/A0.md for guidance there.

Is there a recommended length or max length? for videos waveform could be quite long

@vitorpamplona
Copy link
Collaborator

But this is only for audio, right? Maybe for hour-long podcasts, waveform is less interesting...

@1-leo
Copy link
Author

1-leo commented Mar 6, 2026

Yes, it's the audio track of the video. For something like YouTube Music, a waveform could be interesting.

@1-leo 1-leo marked this pull request as ready for review March 8, 2026 09:22
@flox1an
Copy link

flox1an commented Mar 10, 2026

The mimetype audio/mp4 does not make sense IMHO ... audio/m4a or audio/mp3 would make sense.

I'm not sure how this would work in a player. The NIP-71 semantic of the imeta tags is, that these files are alternatives to each other. This would work for an "audio-only" stream.

Using this to add multiple audio streams to a video is a completely different semantic. Is there a video player that uses different audio files to augment a video? Usually video and audio are muxed to a single stream.

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.

3 participants