com.vwp.sound.mod.sound.output
Class SoundDataFormat

java.lang.Object
  extended by com.vwp.sound.mod.sound.output.SoundDataFormat

public class SoundDataFormat
extends java.lang.Object

A class representing the format of a stream of raw sound data. The sample rate, number of bits per sample and the number of channels can be described.


Constructor Summary
SoundDataFormat(int bits, int rate, int channels)
           
 
Method Summary
 int getBits()
           
 int getChannels()
           
 int getRate()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SoundDataFormat

public SoundDataFormat(int bits,
                       int rate,
                       int channels)
Parameters:
bits - the number of bits per sample, per channel (often 8 or 16)
rate - the sample rate (often 44100, 22050 or 11025)
channels - the number of channels (often 1, for mono, or 2, for stereo)
Method Detail

getBits

public int getBits()
Returns:
the number of bits per sample

getRate

public int getRate()
Returns:
the sample rate

getChannels

public int getChannels()
Returns:
the number of channels

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object