|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
entagged.audioformats.asf.data
Class AudioStreamChunk
java.lang.Objectentagged.audioformats.asf.data.Chunk
entagged.audioformats.asf.data.StreamChunk
entagged.audioformats.asf.data.AudioStreamChunk
public class AudioStreamChunk
- extends StreamChunk
This class represents the streamchunk describing an audio stream.
| Field Summary | |
|---|---|
static String[][] |
CODEC_DESCRIPTIONS
Stores the hex values of codec identifiers to their descriptions. |
| Fields inherited from class entagged.audioformats.asf.data.Chunk |
|---|
chunkLength, guid, position |
| Constructor Summary | |
|---|---|
AudioStreamChunk(long pos,
BigInteger chunkLen)
Creates an instance. |
|
| Method Summary | |
|---|---|
long |
getAverageBytesPerSec()
|
int |
getBitsPerSample()
|
long |
getBlockAlignment()
|
long |
getChannelCount()
|
byte[] |
getCodecData()
|
String |
getCodecDescription()
This method will take a look at compressionFormatand returns a
String with its hex value and if known a textual note on what coded it
represents. |
long |
getCompressionFormat()
|
GUID |
getErrorConcealment()
|
int |
getKbps()
This method takes the value of getAverageBytesPerSec()and
calculates the kbps out of it, by simply multiplying by 8 and dividing by
1000. |
long |
getSamplingRate()
|
boolean |
isErrorConcealed()
This mehtod returns whether the audio stream data is error concealed. |
String |
prettyPrint()
(overridden) |
void |
setAverageBytesPerSec(long avgeBytesPerSec)
|
void |
setBitsPerSample(int bps)
Sets the bitsPerSample |
void |
setBlockAlignment(long align)
Sets the blockAlignment. |
void |
setChannelCount(long channels)
|
void |
setCodecData(byte[] codecSpecificData)
Sets the codecData |
void |
setCompressionFormat(long cFormatCode)
|
void |
setErrorConcealment(GUID errConc)
This method sets the error concealment type which is given by two GUIDs. |
void |
setSamplingRate(long sampRate)
|
| Methods inherited from class entagged.audioformats.asf.data.StreamChunk |
|---|
getStreamNumber, getStreamSpecificDataSize, getTimeOffset, getTypeSpecificDataSize, isContentEncrypted, setContentEncrypted, setStreamNumber, setStreamSpecificDataSize, setTimeOffset, setTypeSpecificDataSize |
| Methods inherited from class entagged.audioformats.asf.data.Chunk |
|---|
getChunckEnd, getChunkLength, getGuid, getPosition, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
CODEC_DESCRIPTIONS
public static final String[][] CODEC_DESCRIPTIONS
- Stores the hex values of codec identifiers to their descriptions.
| Constructor Detail |
|---|
AudioStreamChunk
public AudioStreamChunk(long pos, BigInteger chunkLen)
- Creates an instance.
- Parameters:
pos- Position of current chunk within asf file or stream.chunkLen- Length of the entire chunk (including guid and size)
| Method Detail |
|---|
getAverageBytesPerSec
public long getAverageBytesPerSec()
- Returns:
- Returns the averageBytesPerSec.
getBitsPerSample
public int getBitsPerSample()
- Returns:
- Returns the bitsPerSample.
getBlockAlignment
public long getBlockAlignment()
- Returns:
- Returns the blockAlignment.
getChannelCount
public long getChannelCount()
- Returns:
- Returns the channelCount.
getCodecData
public byte[] getCodecData()
- Returns:
- Returns the codecData.
getCodecDescription
public String getCodecDescription()
- This method will take a look at
compressionFormatand returns a String with its hex value and if known a textual note on what coded it represents.
- Returns:
- A description for the used codec.
getCompressionFormat
public long getCompressionFormat()
- Returns:
- Returns the compressionFormat.
getErrorConcealment
public GUID getErrorConcealment()
- Returns:
- Returns the errorConcealment.
getKbps
public int getKbps()
- This method takes the value of
getAverageBytesPerSec()and calculates the kbps out of it, by simply multiplying by 8 and dividing by 1000.
- Returns:
- amount of bits per second in kilo bits.
getSamplingRate
public long getSamplingRate()
- Returns:
- Returns the samplingRate.
isErrorConcealed
public boolean isErrorConcealed()
- This mehtod returns whether the audio stream data is error concealed.
For now only interleaved concealment is known.
- Returns:
trueif error concealment is used.
prettyPrint
public String prettyPrint()
- (overridden)
- Overrides:
prettyPrintin classStreamChunk
- Returns:
- Information of current Chunk Object.
- See Also:
StreamChunk.prettyPrint()
setAverageBytesPerSec
public void setAverageBytesPerSec(long avgeBytesPerSec)
- Parameters:
avgeBytesPerSec- The averageBytesPerSec to set.
setBitsPerSample
public void setBitsPerSample(int bps)
- Sets the bitsPerSample
- Parameters:
bps-
setBlockAlignment
public void setBlockAlignment(long align)
- Sets the blockAlignment.
- Parameters:
align-
setChannelCount
public void setChannelCount(long channels)
- Parameters:
channels- The channelCount to set.
setCodecData
public void setCodecData(byte[] codecSpecificData)
- Sets the codecData
- Parameters:
codecSpecificData-
setCompressionFormat
public void setCompressionFormat(long cFormatCode)
- Parameters:
cFormatCode- The compressionFormat to set.
setErrorConcealment
public void setErrorConcealment(GUID errConc)
- This method sets the error concealment type which is given by two GUIDs.
- Parameters:
errConc- the type of error concealment the audio stream is stored as.
setSamplingRate
public void setSamplingRate(long sampRate)
- Parameters:
sampRate- The samplingRate to set.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
Copyright © 2007-2011 shredzone.org. All Rights Reserved.
