mirror of
https://github.com/vgmstream/vgmstream.git
synced 2025-01-17 23:36:41 +01:00
Allow to disable mpg123 stderr output for recoverable MPEGs (FSBs)
This commit is contained in:
parent
ad3b081681
commit
790bb79cc9
@ -87,14 +87,11 @@ void decode_cbd2_int(VGMSTREAMCHANNEL * stream, sample * outbuf, int channelspac
|
|||||||
void decode_ws(VGMSTREAM * vgmstream, int channel, sample * outbuf, int channelspacing, int32_t first_sample, int32_t samples_to_do);
|
void decode_ws(VGMSTREAM * vgmstream, int channel, sample * outbuf, int channelspacing, int32_t first_sample, int32_t samples_to_do);
|
||||||
|
|
||||||
#ifdef VGM_USE_MPEG
|
#ifdef VGM_USE_MPEG
|
||||||
void decode_fake_mpeg2_l2(VGMSTREAMCHANNEL * stream,
|
|
||||||
mpeg_codec_data * data,
|
|
||||||
sample * outbuf, int32_t samples_to_do);
|
|
||||||
mpeg_codec_data *init_mpeg_codec_data(STREAMFILE *streamfile, off_t start_offset, long given_sample_rate, int given_channels, coding_t *coding_type, int * actual_sample_rate, int * actual_channels);
|
mpeg_codec_data *init_mpeg_codec_data(STREAMFILE *streamfile, off_t start_offset, long given_sample_rate, int given_channels, coding_t *coding_type, int * actual_sample_rate, int * actual_channels);
|
||||||
|
void decode_fake_mpeg2_l2(VGMSTREAMCHANNEL * stream, mpeg_codec_data * data, sample * outbuf, int32_t samples_to_do);
|
||||||
|
void decode_mpeg(VGMSTREAMCHANNEL * stream, mpeg_codec_data * data, sample * outbuf, int32_t samples_to_do, int channels);
|
||||||
long mpeg_bytes_to_samples(long bytes, const struct mpg123_frameinfo *mi);
|
long mpeg_bytes_to_samples(long bytes, const struct mpg123_frameinfo *mi);
|
||||||
void decode_mpeg(VGMSTREAMCHANNEL * stream,
|
void mpeg_set_error_logging(mpeg_codec_data * data, int enable);
|
||||||
mpeg_codec_data * data,
|
|
||||||
sample * outbuf, int32_t samples_to_do, int channels);
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef VGM_USE_G7221
|
#ifdef VGM_USE_G7221
|
||||||
|
@ -226,4 +226,11 @@ long mpeg_bytes_to_samples(long bytes, const struct mpg123_frameinfo *mi) {
|
|||||||
return (int64_t)bytes * mi->rate * 8 / (mi->bitrate * 1000);
|
return (int64_t)bytes * mi->rate * 8 / (mi->bitrate * 1000);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* disables/enables stderr output, useful for MPEG known to contain recoverable errors
|
||||||
|
*/
|
||||||
|
void mpeg_set_error_logging(mpeg_codec_data * data, int enable) {
|
||||||
|
mpg123_param(data->m, MPG123_ADD_FLAGS, MPG123_QUIET, !enable);
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user