auditory.sampled
Class SpeedChangeOp

java.lang.Object
  extended by auditory.sampled.AbstractBufferedSoundOp
      extended by auditory.sampled.AbstractBufferedSoundUnaryOp
          extended by auditory.sampled.SpeedChangeOp
All Implemented Interfaces:
BufferedSoundUnaryOp

public class SpeedChangeOp
extends AbstractBufferedSoundUnaryOp

A BufferedSoundUnaryOp that changes the speed at which a signal is presented

See Also:
"The Design and Implementation of Multimedia Software © 2011"

Constructor Summary
SpeedChangeOp(double multiplier)
          Explicit Value Constructor
 
Method Summary
 void applyFilter(double[] source, double[] destination)
          Copy the signal
 BufferedSound createCompatibleDestinationSound(BufferedSound src)
          Creates a BufferedSound with a different sampling rate.
 
Methods inherited from class auditory.sampled.AbstractBufferedSoundUnaryOp
applyFilter, filter
 
Methods inherited from class auditory.sampled.AbstractBufferedSoundOp
checkArguments
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SpeedChangeOp

public SpeedChangeOp(double multiplier)
Explicit Value Constructor

Parameters:
multiplier - The multiplier to use
Method Detail

createCompatibleDestinationSound

public BufferedSound createCompatibleDestinationSound(BufferedSound src)
Creates a BufferedSound with a different sampling rate.

Overrides:
createCompatibleDestinationSound in class AbstractBufferedSoundOp
Parameters:
src - The source BufferedSound

applyFilter

public void applyFilter(double[] source,
                        double[] destination)
Copy the signal

Specified by:
applyFilter in class AbstractBufferedSoundUnaryOp
Parameters:
source - The source signal
destination - The resulting signal


Design and Implementation of Multimedia Software, Jones and Bartlett Publishers