13
0

Prefer int32_t to int for channel counts

To match the actual type used by ChanCount. Keep the int type in the
structure passed in by the Audio Unit, because we have no control over
it.
This commit is contained in:
Julien "_FrnchFrgg_" RIVAUD 2018-07-31 11:37:33 +02:00
parent 12808c7bd2
commit e9f02e28d3

View File

@ -1328,7 +1328,7 @@ AUPlugin::can_support_io_configuration (const ChanCount& in, ChanCount& out, Cha
#endif
// preferred setting (provided by plugin_insert)
const int preferred_out = out.n_audio ();
const int32_t preferred_out = out.n_audio ();
bool found = false;
bool exact_match = false;
@ -1379,7 +1379,7 @@ AUPlugin::can_support_io_configuration (const ChanCount& in, ChanCount& out, Cha
/* now allow potentially "imprecise" matches */
int32_t audio_out = -1;
float penalty = 9999;
int used_possible_in = 0;
int32_t used_possible_in = 0;
#if defined (__clang__)
# pragma clang diagnostic push
# pragma clang diagnostic ignored "-Wtautological-compare"
@ -1403,7 +1403,7 @@ AUPlugin::can_support_io_configuration (const ChanCount& in, ChanCount& out, Cha
_output_configs.insert (0);
#define UPTO(nch) { \
for (int n = 1; n <= nch; ++n) { \
for (int32_t n = 1; n <= nch; ++n) { \
_output_configs.insert (n); \
} \
}