From 2c348cecb68bd3a71d388547d6b3330f9cebbfad Mon Sep 17 00:00:00 2001 From: Chris Robinson Date: Sat, 14 Sep 2019 16:55:28 -0700 Subject: Fix some more implicit conversions noted by GCC --- alc/mixer/mixer_neon.cpp | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'alc/mixer/mixer_neon.cpp') diff --git a/alc/mixer/mixer_neon.cpp b/alc/mixer/mixer_neon.cpp index 852bef38..2f11273a 100644 --- a/alc/mixer/mixer_neon.cpp +++ b/alc/mixer/mixer_neon.cpp @@ -55,10 +55,10 @@ const ALfloat *Resample_(const InterpState*, const ALfloat *RES if(dst_iter != dst.end()) { src += static_cast(vgetq_lane_s32(pos4, 0)); - frac = vgetq_lane_s32(frac4, 0); + frac = static_cast(vgetq_lane_s32(frac4, 0)); do { - *(dst_iter++) = lerp(src[0], src[1], frac * (1.0f/FRACTIONONE)); + *(dst_iter++) = lerp(src[0], src[1], static_cast(frac) * (1.0f/FRACTIONONE)); frac += increment; src += frac>>FRACTIONBITS; @@ -84,14 +84,15 @@ const ALfloat *Resample_(const InterpState *state, const ALflo // Calculate the phase index and factor. #define FRAC_PHASE_BITDIFF (FRACTIONBITS-BSINC_PHASE_BITS) const ALuint pi{frac >> FRAC_PHASE_BITDIFF}; - const ALfloat pf{(frac & ((1<(frac & ((1<(pi*4)}; const float *scd{fil + m}; const float *phd{scd + m}; const float *spd{phd + m}; @@ -179,8 +180,8 @@ void Mix_(const al::span InSamples, const al::span 0) ? 1.0f / static_cast(Counter) : 0.0f}; const bool reached_target{InSamples.size() >= Counter}; const auto min_end = reached_target ? InSamples.begin() + Counter : InSamples.end(); - const auto aligned_end = minz(InSamples.size(), (min_end-InSamples.begin()+3) & ~3u) + - InSamples.begin(); + const auto aligned_end = minz(static_cast(min_end-InSamples.begin()+3) & ~3u, + InSamples.size()) + InSamples.begin(); for(FloatBufferLine &output : OutBuffer) { ALfloat *RESTRICT dst{al::assume_aligned<16>(output.data()+OutPos)}; -- cgit v1.2.3