rtl_power: MSVC 2010 doesn't have log2()

Signed-off-by: Steve Markgraf <steve@steve-m.de>
This commit is contained in:
Kyle Keen 2013-12-27 00:40:11 +01:00 committed by Steve Markgraf
parent 7855c7c876
commit 3ab6fffbdd

View File

@ -219,6 +219,13 @@ int cic_9_tables[][10] = {
{9, -199, -362, 5303, -25505, 77489, -25505, 5303, -362, -199}, {9, -199, -362, 5303, -25505, 77489, -25505, 5303, -362, -199},
}; };
#ifdef _MSC_VER
double log2(double n)
{
return log(n) / log(2.0);
}
#endif
/* FFT based on fix_fft.c by Roberts, Slaney and Bouras /* FFT based on fix_fft.c by Roberts, Slaney and Bouras
http://www.jjj.de/fft/fftpage.html http://www.jjj.de/fft/fftpage.html
16 bit ints for everything 16 bit ints for everything