Back to Remotion

getDefaultAudioCodec()

packages/docs/docs/webcodecs/get-default-audio-codec.mdx

4.0.4731023 B
Original Source

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

Part of the @remotion/webcodecs package.

:::warning Unstable API: This package is experimental. We might change the API at any time, until we remove this notice. :::

Gets the default audio codec for a container that @remotion/webcodecs uses if no other audio codec was specified.

tsx
import {getDefaultAudioCodec} from '@remotion/webcodecs';

getDefaultAudioCodec({container: 'webm'}); // 'opus'

Currently, the only supported container is webm, for which the default audio codec is opus.

Default audio codecs

import {DefaultAudioCodecs} from './DefaultAudioCodecs';

<DefaultAudioCodecs />

See also