// Macro for killing denormalled numbers // // Written by Jezar at Dreampoint, June 2000 // http://www.dreampoint.co.uk // Based on IS_DENORMAL macro by Jon Watte // This code is public domain #ifndef _denormals_ #define _denormals_ /* #define undenormalise(sample) \ if(((*(unsigned int*)&sample)&0x7f800000)==0) sample=0.0f */ static inline void undenormalise(float &sample) { union { float f; unsigned int u; } v; v.f = sample; if( !(v.u & 0x7f800000) ) sample=0.f; } #endif//_denormals_ //ends