mirror of
https://github.com/arcodange-org/mediabunny.git
synced 2026-09-28 03:13:51 +02:00
Add WAVE muxer
This commit is contained in:
@@ -3,6 +3,7 @@ import { IsobmffMuxer } from './isobmff/isobmff-muxer';
|
||||
import { MatroskaMuxer } from './matroska/matroska-muxer';
|
||||
import { Muxer } from './muxer';
|
||||
import { Output } from './output';
|
||||
import { WaveMuxer } from './wave/wave-muxer';
|
||||
|
||||
/** @public */
|
||||
export abstract class OutputFormat {
|
||||
@@ -197,3 +198,26 @@ export class WebMOutputFormat extends MkvOutputFormat {
|
||||
return '';
|
||||
}
|
||||
}
|
||||
|
||||
/** @public */
|
||||
export class WaveOutputFormat extends OutputFormat {
|
||||
/** @internal */
|
||||
_createMuxer(output: Output) {
|
||||
return new WaveMuxer(output);
|
||||
}
|
||||
|
||||
/** @internal */
|
||||
_getName() {
|
||||
return 'WAVE';
|
||||
}
|
||||
|
||||
getSupportedCodecs() {
|
||||
return WaveOutputFormat.getSupportedCodecs();
|
||||
}
|
||||
|
||||
static getSupportedCodecs(): MediaCodec[] {
|
||||
return [
|
||||
'pcm-u8', 'pcm-s16', 'pcm-s24', 'pcm-s32', 'pcm-f32', 'ulaw', 'alaw',
|
||||
];
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user