FreeBSD Bugzilla – Attachment 170051 Details for
Bug 209333
audio/calf: Fix build with libc++ 3.8.0
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Fix argument types for std::min() and std::max() in audio/calf
audio__calf-fix-float-1.diff (text/plain), 4.52 KB, created by
Dimitry Andric
on 2016-05-06 15:59:16 UTC
(
hide
)
Description:
Fix argument types for std::min() and std::max() in audio/calf
Filename:
MIME Type:
Creator:
Dimitry Andric
Created:
2016-05-06 15:59:16 UTC
Size:
4.52 KB
patch
obsolete
>Index: audio/calf/files/patch-src_analyzer.cpp >=================================================================== >--- audio/calf/files/patch-src_analyzer.cpp (nonexistent) >+++ audio/calf/files/patch-src_analyzer.cpp (working copy) >@@ -0,0 +1,17 @@ >+--- src/analyzer.cpp.orig 2014-10-14 18:53:15 UTC >++++ src/analyzer.cpp >+@@ -471,12 +471,12 @@ void analyzer::draw(int subindex, float >+ //pumping up actual signal an erase surrounding >+ // sounds >+ fft_outL[_iter] = 0.25f * std::max(n * 0.6f * \ >+- fabs(fft_outL[_iter]) - var1L , 1e-20); >++ fabsf(fft_outL[_iter]) - var1L , 1e-20f); >+ if(_mode == 3 or _mode == 4) { >+ // do the same with R channel if needed >+ lastoutR = fft_outR[_iter]; >+ fft_outR[_iter] = 0.25f * std::max(n * \ >+- 0.6f * fabs(fft_outR[_iter]) - var1R , 1e-20); >++ 0.6f * fabsf(fft_outR[_iter]) - var1R , 1e-20f); >+ } >+ break; >+ } > >Property changes on: audio/calf/files/patch-src_analyzer.cpp >___________________________________________________________________ >Added: fbsd:nokeywords >## -0,0 +1 ## >+yes >\ No newline at end of property >Added: svn:eol-style >## -0,0 +1 ## >+native >\ No newline at end of property >Added: svn:mime-type >## -0,0 +1 ## >+text/plain >\ No newline at end of property >Index: audio/calf/files/patch-src_modules__dist.cpp >=================================================================== >--- audio/calf/files/patch-src_modules__dist.cpp (nonexistent) >+++ audio/calf/files/patch-src_modules__dist.cpp (working copy) >@@ -0,0 +1,13 @@ >+--- src/modules_dist.cpp.orig 2015-03-13 23:00:12 UTC >++++ src/modules_dist.cpp >+@@ -794,8 +794,8 @@ uint32_t tapesimulator_audio_module::pro >+ lfo2.advance(1); >+ >+ // dot >+- rms = std::max((double)rms, (fabs(Lo) + fabs(Ro)) / 2); >+- input = std::max((double)input, (fabs(Lc) + fabs(Rc)) / 2); >++ rms = std::max(rms, (fabsf(Lo) + fabsf(Ro)) / 2); >++ input = std::max(input, (fabsf(Lc) + fabsf(Rc)) / 2); >+ >+ float values[] = {inL, inR, outs[0][i], outs[1][i]}; >+ meters.process(values); > >Property changes on: audio/calf/files/patch-src_modules__dist.cpp >___________________________________________________________________ >Added: fbsd:nokeywords >## -0,0 +1 ## >+yes >\ No newline at end of property >Added: svn:eol-style >## -0,0 +1 ## >+native >\ No newline at end of property >Added: svn:mime-type >## -0,0 +1 ## >+text/plain >\ No newline at end of property >Index: audio/calf/files/patch-src_modules__limit.cpp >=================================================================== >--- audio/calf/files/patch-src_modules__limit.cpp (nonexistent) >+++ audio/calf/files/patch-src_modules__limit.cpp (working copy) >@@ -0,0 +1,20 @@ >+--- src/modules_limit.cpp.orig 2014-10-14 18:56:24 UTC >++++ src/modules_limit.cpp >+@@ -429,7 +429,7 @@ uint32_t multibandlimiter_audio_module:: >+ } >+ >+ // write multiband coefficient to buffer >+- buffer[pos] = std::min(*params[param_limit] / std::max(fabs(tmpL), fabs(tmpR)), 1.0); >++ buffer[pos] = std::min(*params[param_limit] / std::max(fabsf(tmpL), fabsf(tmpR)), 1.0f); >+ >+ // step forward in multiband buffer >+ pos = (pos + channels) % buffer_size; >+@@ -811,7 +811,7 @@ uint32_t sidechainlimiter_audio_module:: >+ } >+ >+ // write multiband coefficient to buffer >+- buffer[pos] = std::min(*params[param_limit] / std::max(fabs(tmpL), fabs(tmpR)), 1.0); >++ buffer[pos] = std::min(*params[param_limit] / std::max(fabsf(tmpL), fabsf(tmpR)), 1.0f); >+ >+ // step forward in multiband buffer >+ pos = (pos + channels) % buffer_size; > >Property changes on: audio/calf/files/patch-src_modules__limit.cpp >___________________________________________________________________ >Added: fbsd:nokeywords >## -0,0 +1 ## >+yes >\ No newline at end of property >Added: svn:eol-style >## -0,0 +1 ## >+native >\ No newline at end of property >Added: svn:mime-type >## -0,0 +1 ## >+text/plain >\ No newline at end of property
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 209333
: 170051