mirror of
https://github.com/mackron/miniaudio.git
synced 2026-04-21 15:56:58 +02:00
Fix a bug with initialization of the encoder in audioconverter.
This commit is contained in:
@@ -301,7 +301,7 @@ int main(int argc, char** argv)
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* Initialize the encoder for the output file. */
|
/* Initialize the encoder for the output file. */
|
||||||
encoderConfig = ma_encoder_config_init(ma_resource_format_wav, format, channels, rate);
|
encoderConfig = ma_encoder_config_init(ma_resource_format_wav, decoder.outputFormat, decoder.outputChannels, decoder.outputSampleRate);
|
||||||
result = ma_encoder_init_file(pOutputFilePath, &encoderConfig, &encoder);
|
result = ma_encoder_init_file(pOutputFilePath, &encoderConfig, &encoder);
|
||||||
if (result != MA_SUCCESS) {
|
if (result != MA_SUCCESS) {
|
||||||
ma_decoder_uninit(&decoder);
|
ma_decoder_uninit(&decoder);
|
||||||
|
|||||||
Reference in New Issue
Block a user