Demo entry 6754373

zz

   

Submitted by zz on Jul 11, 2018 at 04:56
Language: C++. Code size: 1.5 kB.

/*!
 * RNCFFT is a class for calculating FFT in RNC algorithm.
 */
class RNCFFT
{
public:

    /** @brief Default constructor. It does not allocate memory!
    */
    RNCFFT();
    /** @brief Default destructor.
    */
    ~RNCFFT();

    /* @brief Initializes rncFFT object
     * @param[in] fftLength -- length of FFT
    */
    void init(int fftLength);

    /** @brief Calculates FFT
     *   @param[in] realBuffer -- input data
     *   @param[out] realBuffer -- real part of the output spectrum
     *   @param[out] imagBuffer -- imaginary part of the output spectrum
     */
    void calcFFT(float *realBuffer, float *imagBuffer);
private:
    int     m_fftLength;                                        // FFT size
    float * m_cosTwiddle;                                  // cos twiddle factor table
    float * m_sinTwiddle;                                   // sin twiddle factor table
    int   * m_lookupTable;                                  // look up table
    int   * m_reverseLookUpTable;                    // reversed look up table
    int     m_lookUpTableSize;                           // size of the look up table
    int     m_numStages;                                     // number of stages
    float * m_FFTTwiddle;                                // FFT twiddle factor table
    unsigned char *m_brev;                               // brev table
    std::complex<float> * m_outputBuffer;      // temporary complex spectrum of the input signal
};

This snippet took 0.00 seconds to highlight.

Back to the Entry List or Home.

Delete this entry (admin only).