Capítulo 713 de 988

Chapter 713: createAudioDecoder()

Core Idea

:::warning We are phasing out Remotion WebCodecs and are moving to Mediabunny!

Key Concepts

  • Differences to AudioDecoder
  • API
  • track
  • onFrame
  • onError
  • controller?
  • logLevel?
  • Return type

Code Examples

const track = {} as unknown as MediaParserAudioTrack;


const decoder = await createAudioDecoder({
  track,
  onFrame: console.log,
  onError: console.error,
});
  • What it demonstrates: Usage pattern for createAudioDecoder() from the official docs.

Key Takeaways

  1. Understand differences to audiodecoder when working with createAudioDecoder().
  2. Understand api when working with createAudioDecoder().
  3. Understand track when working with createAudioDecoder().
  4. Understand onframe when working with createAudioDecoder().
  5. Understand onerror when working with createAudioDecoder().

Connects To

  • Buffer Writer: related page in the WebCodecs (@remotion/webcodecs) section.
  • can Copy Audio Track: related page in the WebCodecs (@remotion/webcodecs) section.
  • can Copy Video Track: related page in the WebCodecs (@remotion/webcodecs) section.