1

Closed

Sound effect problem

description

While most of the sound effects generated in as3sfxr sound correct when generated for XNA, every now and then I find one that doesn't sound quite right.
 
For example, copy/paste this into as3sfxr, and you get a siren like sound effect.
2,0.0028,0.9527,0.1807,0.4139,0.5534,,0.0022,-0.0816,,0.9387,-0.9916,,0.8259,0.0015,0.068,-0.2339,-0.132,0.8973,-0.0149,0.0783,0.0453,,0.5
 
If you use it in XNA SfxrSynth, you get a flat tone. (Something like the test signal that might accompany colorbars in video.)
 
I've checked and double checked, and the code for Reset and CreateSound are virtually identical to the code from as3sfxr. It's possible that it's a subtle difference between C# and ActionScript, but since I don't understand the algorithms used in generating the sound effects, I'm not sure where to look.
Closed Jan 18, 2011 at 4:52 PM by jessechounard
This issue has been resolved.The synthesizer was using C# floats (32 bits) internally, while the synthesizer in as3sfxr was using the AS3 Number type (64 bits) and this caused the different results.Fixed check in with change set 57304.

comments