Class FFTDataList

java.lang.Object
fftManager.fftorganiser.FFTDataList

public class FFTDataList extends Object
List of FFT Data provided by the FFTDataOrganiser. This should be interleaved by channel and makes a 'friendly' lump of FFT data to use with various localisation algorithms.
Author:
Doug Gillespie
  • Constructor Details

    • FFTDataList

      public FFTDataList(double sampleRate)
      Construct an FFT data list object.
  • Method Details

    • addData

      public boolean addData(FFTDataUnit fftDataUnit)
      Add an FFTDataUnit to the list.
      Parameters:
      fftDataUnit -
      Returns:
      true if all the FFT's are all still the same length.
    • mergeIn

      public int mergeIn(FFTDataList otherList)
      Merge the other list into this one ....
      Parameters:
      otherList - Other list of FFT data (can be null in which case nothing will happen);
      Returns:
      number of FFT data units added
    • getChannelData

      public FFTDataUnit[] getChannelData(int iChannel)
      Get the FFT data units for a single channel.
      Parameters:
      iChannel - channel index
      Returns:
      list for a single channel.
    • getChannelSeparatedData

      public FFTDataUnit[][] getChannelSeparatedData()
      Get all the data separated by channel. The order will be sequential since all the data are being picked by channel map.
      Returns:
      arrays of all data by channel
    • interleaveOK

      public boolean interleaveOK()
      Check channel ordering is all OK still.
      Returns:
      true if channels correctly interleaved.
    • getFftDataUnits

      public ArrayList<FFTDataUnit> getFftDataUnits()
      Returns:
      the fftDataUnits
    • getChannelMap

      public int getChannelMap()
      Returns:
      the channelMap
    • getChannelCount

      public int[] getChannelCount()
      Returns:
      the channelCount
    • getMinChannelCount

      public int getMinChannelCount()
      Returns:
      the minChannelCount
    • getMaxChannelCount

      public int getMaxChannelCount()
      Returns:
      the maxChannelCount
    • getMinFFTLength

      public int getMinFFTLength()
      Returns:
      the minFFTLength
    • getMaxFFTLength

      public int getMaxFFTLength()
      Returns:
      the maxFFTLength
    • getSampleRate

      public double getSampleRate()
      FFTDataList carries it's own sample rate, this is so that it can be easily used with upsampled data during localisation, i.e. the sample rate in the data may no longer be the same as the sample rate in the source of the data !
      Returns:
      the sampleRate in Hz