/Users/richardeakin/projects/libsms/trunk/src/tables.c File Reference

sin and sinc tables. More...

#include "sms.h"
Include dependency graph for tables.c:

Functions

int sms_prepSine (int nTableSize)
 prepares the sine table
void sms_clearSine ()
 clear sine table
sfloat sms_sine (sfloat fTheta)
 table-lookup sine method
static sfloat Sinc (sfloat x, sfloat N)
 Sinc method to generate the lookup table.
int sms_prepSinc (int nTableSize)
 prepare the Sinc table
void sms_clearSinc ()
 clear sine table
sfloat sms_sinc (sfloat fTheta)
 global sinc table-lookup method

Variables

static sfloat fSineScale
 value to scale the sine-table-lookup phase
static sfloat fSineIncr
 inverse of fSineScale - turns a division into multiplication
static sfloat fSincScale
 value to scale the sinc-table-lookup phase
static sfloat * sms_tab_sine
 global pointer to the sine table
static sfloat * sms_tab_sinc
 global pointer to the sinc table

Detailed Description

sin and sinc tables.

contains functions for creating and indexing the tables


Function Documentation

static sfloat Sinc ( sfloat  x,
sfloat  N 
) [static]

Sinc method to generate the lookup table.

Referenced by sms_prepSinc().

void sms_clearSinc ( void   ) 

clear sine table

References sms_tab_sinc.

Referenced by sms_free().

void sms_clearSine ( void   ) 

clear sine table

References sms_tab_sine.

Referenced by sms_free().

int sms_prepSinc ( int  nTableSize  ) 

prepare the Sinc table

used for the main lobe of a frequency domain BlackmanHarris92 window

Parameters:
nTableSize size of table
Returns:
error code
See also:
SMS_MALLOC in SMS_ERRORS

References fSincScale, sfloat, Sinc(), SMS_MALLOC, SMS_OK, sms_tab_sinc, and TWO_PI.

Referenced by sms_init().

Here is the call graph for this function:

int sms_prepSine ( int  nTableSize  ) 

prepares the sine table

Parameters:
nTableSize size of table
Returns:
error code
See also:
SMS_MALLOC in SMS_ERRORS

References fSineIncr, fSineScale, sfloat, SMS_MALLOC, SMS_OK, sms_tab_sine, and TWO_PI.

Referenced by sms_init().


Variable Documentation

sfloat fSincScale [static]

value to scale the sinc-table-lookup phase

Referenced by sms_prepSinc(), and sms_sinc().

sfloat fSineIncr [static]

inverse of fSineScale - turns a division into multiplication

Referenced by sms_prepSine(), and sms_sine().

sfloat fSineScale [static]

value to scale the sine-table-lookup phase

Referenced by sms_prepSine().

sfloat* sms_tab_sinc [static]

global pointer to the sinc table

Referenced by sms_clearSinc(), sms_prepSinc(), and sms_sinc().

sfloat* sms_tab_sine [static]

global pointer to the sine table

Referenced by sms_clearSine(), sms_prepSine(), and sms_sine().

 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines

Generated on Thu Oct 29 04:08:07 2009 for libsms by  doxygen 1.6.1