org.tritonus.sampled.file
Class WaveTool

java.lang.Object
  extended byorg.tritonus.sampled.file.WaveTool

public class WaveTool
extends Object

Common constants and methods for handling wave files.

Author:
Florian Bomers

Field Summary
static int CHUNK_HEADER_SIZE
           
static int DATA_OFFSET
           
static int FMT_CHUNK_SIZE
           
static AudioFormat.Encoding GSM0610
           
static AudioFormat.Encoding IMA_ADPCM
           
static int MIN_DATA_OFFSET
           
static int MIN_FACT_CHUNK_LENGTH
           
static int MIN_FMT_CHUNK_LENGTH
           
static int RIFF_CONTAINER_CHUNK_SIZE
           
static int WAVE_DATA_MAGIC
           
static int WAVE_FACT_MAGIC
           
static int WAVE_FMT_MAGIC
           
static short WAVE_FORMAT_ALAW
           
static short WAVE_FORMAT_G721_ADPCM
           
static short WAVE_FORMAT_G723_ADPCM
           
static short WAVE_FORMAT_GSM610
           
static short WAVE_FORMAT_IMA_ADPCM
           
static short WAVE_FORMAT_MPEG
           
static short WAVE_FORMAT_MS_ADPCM
           
static short WAVE_FORMAT_PCM
           
static short WAVE_FORMAT_ULAW
           
static short WAVE_FORMAT_UNSPECIFIED
           
static int WAVE_RIFF_MAGIC
           
static int WAVE_WAVE_MAGIC
           
 
Constructor Summary
WaveTool()
           
 
Method Summary
static short getFormatCode(AudioFormat format)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

WAVE_RIFF_MAGIC

public static final int WAVE_RIFF_MAGIC
See Also:
Constant Field Values

WAVE_WAVE_MAGIC

public static final int WAVE_WAVE_MAGIC
See Also:
Constant Field Values

WAVE_FMT_MAGIC

public static final int WAVE_FMT_MAGIC
See Also:
Constant Field Values

WAVE_DATA_MAGIC

public static final int WAVE_DATA_MAGIC
See Also:
Constant Field Values

WAVE_FACT_MAGIC

public static final int WAVE_FACT_MAGIC
See Also:
Constant Field Values

WAVE_FORMAT_UNSPECIFIED

public static final short WAVE_FORMAT_UNSPECIFIED
See Also:
Constant Field Values

WAVE_FORMAT_PCM

public static final short WAVE_FORMAT_PCM
See Also:
Constant Field Values

WAVE_FORMAT_MS_ADPCM

public static final short WAVE_FORMAT_MS_ADPCM
See Also:
Constant Field Values

WAVE_FORMAT_ALAW

public static final short WAVE_FORMAT_ALAW
See Also:
Constant Field Values

WAVE_FORMAT_ULAW

public static final short WAVE_FORMAT_ULAW
See Also:
Constant Field Values

WAVE_FORMAT_IMA_ADPCM

public static final short WAVE_FORMAT_IMA_ADPCM
See Also:
Constant Field Values

WAVE_FORMAT_G723_ADPCM

public static final short WAVE_FORMAT_G723_ADPCM
See Also:
Constant Field Values

WAVE_FORMAT_GSM610

public static final short WAVE_FORMAT_GSM610
See Also:
Constant Field Values

WAVE_FORMAT_G721_ADPCM

public static final short WAVE_FORMAT_G721_ADPCM
See Also:
Constant Field Values

WAVE_FORMAT_MPEG

public static final short WAVE_FORMAT_MPEG
See Also:
Constant Field Values

MIN_FMT_CHUNK_LENGTH

public static final int MIN_FMT_CHUNK_LENGTH
See Also:
Constant Field Values

MIN_DATA_OFFSET

public static final int MIN_DATA_OFFSET
See Also:
Constant Field Values

MIN_FACT_CHUNK_LENGTH

public static final int MIN_FACT_CHUNK_LENGTH
See Also:
Constant Field Values

FMT_CHUNK_SIZE

public static final int FMT_CHUNK_SIZE
See Also:
Constant Field Values

RIFF_CONTAINER_CHUNK_SIZE

public static final int RIFF_CONTAINER_CHUNK_SIZE
See Also:
Constant Field Values

CHUNK_HEADER_SIZE

public static final int CHUNK_HEADER_SIZE
See Also:
Constant Field Values

DATA_OFFSET

public static final int DATA_OFFSET
See Also:
Constant Field Values

GSM0610

public static AudioFormat.Encoding GSM0610

IMA_ADPCM

public static AudioFormat.Encoding IMA_ADPCM
Constructor Detail

WaveTool

public WaveTool()
Method Detail

getFormatCode

public static short getFormatCode(AudioFormat format)