net.jinx.audio.synth.source
Class StreamSource

java.lang.Object
  extended by net.jinx.audio.synth.source.StreamSource
All Implemented Interfaces:
SampleProcessor

public class StreamSource
extends java.lang.Object
implements SampleProcessor


Constructor Summary
StreamSource(javax.sound.sampled.AudioInputStream source)
           
StreamSource(java.io.File file)
           
StreamSource(java.net.URL url)
           
 
Method Summary
 SampleFormat getCompatibleFormat()
           
 SampleFormat getFormat()
           
 boolean isSource()
           
 void process(java.nio.DoubleBuffer sample)
           
 boolean setFormat(SampleFormat fmt)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StreamSource

public StreamSource(java.io.File file)
             throws javax.sound.sampled.UnsupportedAudioFileException,
                    java.io.IOException
Throws:
javax.sound.sampled.UnsupportedAudioFileException
java.io.IOException

StreamSource

public StreamSource(java.net.URL url)
             throws javax.sound.sampled.UnsupportedAudioFileException,
                    java.io.IOException
Throws:
javax.sound.sampled.UnsupportedAudioFileException
java.io.IOException

StreamSource

public StreamSource(javax.sound.sampled.AudioInputStream source)
Method Detail

setFormat

public boolean setFormat(SampleFormat fmt)
Specified by:
setFormat in interface SampleProcessor

getFormat

public SampleFormat getFormat()
Specified by:
getFormat in interface SampleProcessor

getCompatibleFormat

public SampleFormat getCompatibleFormat()

process

public void process(java.nio.DoubleBuffer sample)
Specified by:
process in interface SampleProcessor

isSource

public boolean isSource()
Specified by:
isSource in interface SampleProcessor