soundPlayback
Class FilePlayback

java.lang.Object
  extended by soundPlayback.FilePlayback
All Implemented Interfaces:
PlaybackSystem

public class FilePlayback
extends java.lang.Object
implements PlaybackSystem

Playback of sound from wav files. Other real time sound sources must handle their own playback so that timing of in and out is synchronised correctly.

Author:
Doug Gillespie
See Also:
DaqSystem

Field Summary
private  FilePlaybackDevice currentDevice
           
protected  java.util.ArrayList<FilePlaybackDevice> filePBDevices
           
private  FilePlaybackDialogComponent filePlaybackDialogComponent
           
private  PlaybackControl playbackControl
           
 
Constructor Summary
FilePlayback(PlaybackControl playbackControl)
           
 
Method Summary
 int getDeviceNumber()
           
 PlaybackDialogComponent getDialogComponent()
           
 int getMaxChannels()
           
 java.lang.String getName()
           
 PlaybackControl getPlaybackControl()
           
 boolean playData(RawDataUnit[] data)
           
 boolean prepareSystem(PlaybackControl playbackControl, int nChannels, float sampleRate)
           
 boolean unPrepareSystem()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

playbackControl

private PlaybackControl playbackControl

filePlaybackDialogComponent

private FilePlaybackDialogComponent filePlaybackDialogComponent

filePBDevices

protected java.util.ArrayList<FilePlaybackDevice> filePBDevices

currentDevice

private FilePlaybackDevice currentDevice
Constructor Detail

FilePlayback

public FilePlayback(PlaybackControl playbackControl)
Method Detail

getMaxChannels

public int getMaxChannels()
Specified by:
getMaxChannels in interface PlaybackSystem

getDeviceNumber

public int getDeviceNumber()

prepareSystem

public boolean prepareSystem(PlaybackControl playbackControl,
                             int nChannels,
                             float sampleRate)
Specified by:
prepareSystem in interface PlaybackSystem

unPrepareSystem

public boolean unPrepareSystem()
Specified by:
unPrepareSystem in interface PlaybackSystem

playData

public boolean playData(RawDataUnit[] data)
Specified by:
playData in interface PlaybackSystem

getDialogComponent

public PlaybackDialogComponent getDialogComponent()
Specified by:
getDialogComponent in interface PlaybackSystem

getName

public java.lang.String getName()
Specified by:
getName in interface PlaybackSystem

getPlaybackControl

public PlaybackControl getPlaybackControl()