Re: [LAU] Need some programming help.

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: <linux-audio-user@...>
Date: Friday, November 22, 2013 - 12:36 am

On Thu, Nov 21, 2013 at 07:22:31PM +0000, Will Godfrey wrote:

I'm noticing a possible bug generator in a diff between
`ZynAddSubFX-2.4.3' and `yoshimi-1.1.0':

diff -u ZynAddSubFX-2.4.3/src/UI/ADnoteUI.fl \
yoshimi-1.1.0/src/UI/ADnoteUI.fl | grep lrintf
+ callback {pars->VoicePar[nvoice].PVolume = lrintf(o->value());}
+ callback {pars->VoicePar[nvoice].Presonance = lrintf(o->value());}
[...]

!! | wc -l
72

The method `value' of Fl_Valuator returns a "double" and `lrintf'
requires "float".

The implementation of `lrintf' depends on the machine (for example, in
glibc-2.15, it uses the instruction CVTSD2SI for x86_64).

You could try `lrint' or the follow trick:

http://music.columbia.edu/pipermail/music-dsp/2013-September/071566.html
_______________________________________________
Linux-audio-user mailing list
Linux-audio-user@lists.linuxaudio.org
http://lists.linuxaudio.org/listinfo/linux-audio-user

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[LAU] Need some programming help., Will Godfrey, (Mon Nov 18, 9:14 pm)
Re: [LAU] Need some programming help., Tito Latini, (Tue Nov 19, 12:01 pm)
Re: [LAU] Need some programming help., Will Godfrey, (Thu Nov 21, 7:22 pm)
Re: [LAU] Need some programming help., Tito Latini, (Fri Nov 22, 12:36 am)
Re: [LAU] Need some programming help., Will Godfrey, (Sun Mar 2, 11:19 pm)
Re: [LAU] Need some programming help., Tito Latini, (Mon Mar 3, 5:59 pm)
Re: [LAU] Need some programming help., Will J Godfrey, (Mon Mar 3, 6:50 pm)
Re: [LAU] Need some programming help., James Morris, (Tue Nov 19, 12:53 am)