Merge pull request #120 from Ouack23/master
Cast float* in SRC lib calls to delete fpermissive compilation error
This commit is contained in:
commit
c681c908f6
|
@ -164,7 +164,7 @@ FaacEncoder :: write ( const void * buf,
|
||||||
if ( converter ) {
|
if ( converter ) {
|
||||||
unsigned int converted;
|
unsigned int converted;
|
||||||
#ifdef HAVE_SRC_LIB
|
#ifdef HAVE_SRC_LIB
|
||||||
src_short_to_float_array ((short *) b, converterData.data_in, samples);
|
src_short_to_float_array ((short *) b, (float *) converterData.data_in, samples);
|
||||||
converterData.input_frames = nSamples;
|
converterData.input_frames = nSamples;
|
||||||
converterData.data_out = resampledOffset + (resampledOffsetSize * channels);
|
converterData.data_out = resampledOffset + (resampledOffsetSize * channels);
|
||||||
int srcError = src_process (converter, &converterData);
|
int srcError = src_process (converter, &converterData);
|
||||||
|
|
|
@ -403,7 +403,7 @@ OpusLibEncoder :: write ( const void * buf,
|
||||||
#ifdef HAVE_SRC_LIB
|
#ifdef HAVE_SRC_LIB
|
||||||
(void)inCount;
|
(void)inCount;
|
||||||
converterData.input_frames = processed;
|
converterData.input_frames = processed;
|
||||||
src_short_to_float_array (shortBuffer, converterData.data_in, totalSamples);
|
src_short_to_float_array (shortBuffer, (float *) converterData.data_in, totalSamples);
|
||||||
int srcError = src_process (converter, &converterData);
|
int srcError = src_process (converter, &converterData);
|
||||||
if (srcError)
|
if (srcError)
|
||||||
throw Exception (__FILE__, __LINE__, "libsamplerate error: ", src_strerror (srcError));
|
throw Exception (__FILE__, __LINE__, "libsamplerate error: ", src_strerror (srcError));
|
||||||
|
|
|
@ -337,7 +337,7 @@ VorbisLibEncoder :: write ( const void * buf,
|
||||||
int converted;
|
int converted;
|
||||||
#ifdef HAVE_SRC_LIB
|
#ifdef HAVE_SRC_LIB
|
||||||
converterData.input_frames = nSamples;
|
converterData.input_frames = nSamples;
|
||||||
src_short_to_float_array (shortBuffer, converterData.data_in, totalSamples);
|
src_short_to_float_array (shortBuffer, (float *) converterData.data_in, totalSamples);
|
||||||
int srcError = src_process (converter, &converterData);
|
int srcError = src_process (converter, &converterData);
|
||||||
if (srcError)
|
if (srcError)
|
||||||
throw Exception (__FILE__, __LINE__, "libsamplerate error: ", src_strerror (srcError));
|
throw Exception (__FILE__, __LINE__, "libsamplerate error: ", src_strerror (srcError));
|
||||||
|
|
|
@ -155,7 +155,7 @@ aacPlusEncoder :: write ( const void * buf,
|
||||||
if ( converter ) {
|
if ( converter ) {
|
||||||
unsigned int converted;
|
unsigned int converted;
|
||||||
#ifdef HAVE_SRC_LIB
|
#ifdef HAVE_SRC_LIB
|
||||||
src_short_to_float_array ((short *) b, converterData.data_in, samples);
|
src_short_to_float_array ((short *) b, (float *) converterData.data_in, samples);
|
||||||
converterData.input_frames = nSamples;
|
converterData.input_frames = nSamples;
|
||||||
converterData.data_out = resampledOffset + (resampledOffsetSize * channels);
|
converterData.data_out = resampledOffset + (resampledOffsetSize * channels);
|
||||||
int srcError = src_process (converter, &converterData);
|
int srcError = src_process (converter, &converterData);
|
||||||
|
|
Loading…
Reference in New Issue