Package ipsk.db.speech
Class AudioFormat
- java.lang.Object
-
- ipsk.db.speech.AudioFormat
-
@Entity public class AudioFormat extends java.lang.Object
Audio format.- Author:
- K.Jaensch, klausj@phonetik.uni-muenchen.de
-
-
Constructor Summary
Constructors Constructor Description AudioFormat()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
getBigEndian()
int
getChannels()
Number of channels.java.lang.String
getEncoding()
Encoding name.int
getFrameSize()
Framesize in bytes of one audio frame.java.lang.String
getName()
Get name of audio format.java.util.Set<Project>
getProjects()
int
getQuantisation()
Get quantisation (sample size in bits), e.g. 16 for CD-DA Quality.double
getSampleRate()
Get samplerate.void
setBigEndian(boolean b)
Set to true if the byte order is big endian.void
setChannels(int i)
Set number of channels.void
setEncoding(java.lang.String encoding)
void
setFrameSize(int i)
Set frame size.void
setName(java.lang.String string)
set the name of the audi format.void
setProjects(java.util.Set<Project> projects)
void
setQuantisation(int quantisation)
Set quantisation in bits.void
setSampleRate(double d)
Set sample rate in Hz.java.lang.String
toString()
-
-
-
Method Detail
-
setName
public void setName(java.lang.String string)
set the name of the audi format. Something like 'CD quality'.- Parameters:
string
-
-
getName
public java.lang.String getName()
Get name of audio format.
-
getEncoding
public java.lang.String getEncoding()
Encoding name. JavaSound terms should be used. ('PCM_SIGNED')- Returns:
- encoding as string
-
setEncoding
public void setEncoding(java.lang.String encoding)
-
getChannels
public int getChannels()
Number of channels.- Returns:
- channels
-
getFrameSize
public int getFrameSize()
Framesize in bytes of one audio frame. For PCM encoding this is equal to the size of one sample multiplied by the number of channels.- Returns:
- frame size in bytes
-
getSampleRate
public double getSampleRate()
Get samplerate.- Returns:
- samplerate in Hz
-
getQuantisation
public int getQuantisation()
Get quantisation (sample size in bits), e.g. 16 for CD-DA Quality.- Returns:
- quantisation
-
getBigEndian
public boolean getBigEndian()
-
setBigEndian
public void setBigEndian(boolean b)
Set to true if the byte order is big endian.- Parameters:
b
-
-
setChannels
public void setChannels(int i)
Set number of channels.- Parameters:
i
-
-
setFrameSize
public void setFrameSize(int i)
Set frame size.- Parameters:
i
-
-
setSampleRate
public void setSampleRate(double d)
Set sample rate in Hz.- Parameters:
d
-
-
setQuantisation
public void setQuantisation(int quantisation)
Set quantisation in bits.- Parameters:
quantisation
-
-
getProjects
public java.util.Set<Project> getProjects()
-
setProjects
public void setProjects(java.util.Set<Project> projects)
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-