framed
Class DCT

java.lang.Object
  extended by framed.DCT
All Implemented Interfaces:
FrameSource

public class DCT
extends java.lang.Object
implements FrameSource


Constructor Summary
DCT(FrameSource source, boolean scale)
          Construct a new FFT object.
DCT(FrameSource source, boolean scale, boolean computeShortTimeEnergy)
           
 
Method Summary
 int getFrameSize()
          Return the length of the frames (needed for the read call)
 boolean read(double[] buf)
          Read the next frame and apply DCT.
 java.lang.String toString()
          Return a String representation of the FrameSource
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

DCT

public DCT(FrameSource source,
           boolean scale)
Construct a new FFT object. Frame size stays unchanged, first coefficient is replaced by the short time energy (in case of a Mel filter bank input the sum over the bands)


DCT

public DCT(FrameSource source,
           boolean scale,
           boolean computeShortTimeEnergy)
Method Detail

getFrameSize

public int getFrameSize()
Description copied from interface: FrameSource
Return the length of the frames (needed for the read call)

Specified by:
getFrameSize in interface FrameSource

read

public boolean read(double[] buf)
             throws java.io.IOException
Read the next frame and apply DCT.

Specified by:
read in interface FrameSource
Parameters:
buf - buffer to save the frame; implementing objects may depend on a constant dimensionduring subsequent calls
Returns:
true on success, false if the stream terminated before the window was filled
Throws:
java.io.IOException

toString

public java.lang.String toString()
Description copied from interface: FrameSource
Return a String representation of the FrameSource

Specified by:
toString in interface FrameSource
Overrides:
toString in class java.lang.Object