as.clynx.audio.mux.streams
Class MultiStream

java.lang.Object
  extended by java.io.InputStream
      extended by javax.sound.sampled.AudioInputStream
          extended by as.clynx.audio.mux.streams.AudioStream
              extended by as.clynx.audio.mux.streams.MultiStream
All Implemented Interfaces:
java.io.Closeable

public class MultiStream
extends AudioStream

The class MultiStream.java extends AudioStream. It plays all streams parallel in al channels. it is possible to do that in 2 modes. STATIC MODE: all streams are simply played parrallel in all channels. DYNAMIC MODE: all streams are played parralel in all channels and one stream is played louder for an amount of time, followed by the next stream.

Version:
cLynx v.1.2, JDK 6.0: 12.10.2007
Author:
Andreas Senfter - andreas@senfters.com

Field Summary
 
Fields inherited from class as.clynx.audio.mux.streams.AudioStream
DYNAMIC_MODE, STATIC_MODE
 
Constructor Summary
MultiStream(IAudioFileCollection collection, int mode, SettingControl settings)
          Constructor
 
Method Summary
 int getTargetBufferSize()
          returns the buffersze of the targetBuffer
 int getType()
          returns the type of the mux function
 void setMasterVolume(int l)
          sets the master volume [takes effect in runtime]
 void setVolume(int l)
          sets the volume [takes effect in runtime]
 
Methods inherited from class as.clynx.audio.mux.streams.AudioStream
getFormat, getMode, getSettings, getSourceDataLine, read, setDurationInSeconds, setFadeTimeInSeconds, setFadeValue
 
Methods inherited from class javax.sound.sampled.AudioInputStream
available, close, getFrameLength, mark, markSupported, read, read, reset, skip
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MultiStream

public MultiStream(IAudioFileCollection collection,
                   int mode,
                   SettingControl settings)
Constructor

Parameters:
collection -
mode -
settings -
Method Detail

getTargetBufferSize

public int getTargetBufferSize()
Description copied from class: AudioStream
returns the buffersze of the targetBuffer

Specified by:
getTargetBufferSize in class AudioStream
Returns:
the buffersze of the targetBuffer

setVolume

public void setVolume(int l)
sets the volume [takes effect in runtime]

Parameters:
l -

setMasterVolume

public void setMasterVolume(int l)
sets the master volume [takes effect in runtime]

Parameters:
l -

getType

public int getType()
Description copied from class: AudioStream
returns the type of the mux function

Specified by:
getType in class AudioStream
Returns:
the type of the mux function