Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

com.anotherbigidea.flash.sound
Class MP3Frame  view MP3Frame download MP3Frame.java

java.lang.Object
  extended bycom.anotherbigidea.flash.sound.MP3Frame

public class MP3Frame
extends java.lang.Object

An MP3 sound data frame.


Field Summary
protected  int bit_rate
           
protected  int bitRate
           
static int CHANNEL_MODE_DUAL_CHANNEL
           
static int CHANNEL_MODE_JOINT_STEREO
           
static int CHANNEL_MODE_MONO
           
static int CHANNEL_MODE_STEREO
           
protected  int channelMode
           
protected  boolean copyrighted
           
protected  byte[] data
           
protected  int emphasis
           
static int EMPHASIS_50_15_MS
           
static int EMPHASIS_CCIT_J17
           
static int EMPHASIS_NONE
           
static int EMPHASIS_RESERVED
           
private static int FRAME_SAMPLES_MPEG_1
           
private static int FRAME_SAMPLES_MPEG_2
           
protected  boolean isProtected
           
protected  int modeExtension
           
static int MPEG_Layer_1
           
static int MPEG_Layer_2
           
static int MPEG_Layer_3
           
static int MPEG_Version_1
           
static int MPEG_Version_2
           
static int MPEG_Version_2_5
           
protected static int[] MPEG10SampleRates
           
protected static int[] MPEG1BitRates
           
protected static int[] MPEG20SampleRates
           
protected static int[] MPEG25SampleRates
           
protected static int[] MPEG2BitRates
           
protected  int mpegLayer
           
protected  int mpegVersion
           
protected  boolean original
           
protected  boolean padded
           
protected  int sample_rate
           
protected  int sampleRate
           
 
Constructor Summary
MP3Frame()
           
 
Method Summary
 int getBitRate()
           
 int getDataLength()
           
 int getSampleRate()
           
 int getSamplesPerFrame()
           
 boolean isStereo()
           
static MP3Frame readFrame(java.io.InputStream in)
          Read the next MP3 frame from the stream - return null if no more
 java.lang.String toString()
          Convert this Object to a human-readable String.
 void write(java.io.OutputStream out)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

MPEG_Version_2_5

public static final int MPEG_Version_2_5
See Also:
Constant Field Values

MPEG_Version_2

public static final int MPEG_Version_2
See Also:
Constant Field Values

MPEG_Version_1

public static final int MPEG_Version_1
See Also:
Constant Field Values

MPEG_Layer_3

public static final int MPEG_Layer_3
See Also:
Constant Field Values

MPEG_Layer_2

public static final int MPEG_Layer_2
See Also:
Constant Field Values

MPEG_Layer_1

public static final int MPEG_Layer_1
See Also:
Constant Field Values

CHANNEL_MODE_STEREO

public static final int CHANNEL_MODE_STEREO
See Also:
Constant Field Values

CHANNEL_MODE_JOINT_STEREO

public static final int CHANNEL_MODE_JOINT_STEREO
See Also:
Constant Field Values

CHANNEL_MODE_DUAL_CHANNEL

public static final int CHANNEL_MODE_DUAL_CHANNEL
See Also:
Constant Field Values

CHANNEL_MODE_MONO

public static final int CHANNEL_MODE_MONO
See Also:
Constant Field Values

EMPHASIS_NONE

public static final int EMPHASIS_NONE
See Also:
Constant Field Values

EMPHASIS_50_15_MS

public static final int EMPHASIS_50_15_MS
See Also:
Constant Field Values

EMPHASIS_RESERVED

public static final int EMPHASIS_RESERVED
See Also:
Constant Field Values

EMPHASIS_CCIT_J17

public static final int EMPHASIS_CCIT_J17
See Also:
Constant Field Values

MPEG1BitRates

protected static final int[] MPEG1BitRates

MPEG2BitRates

protected static final int[] MPEG2BitRates

MPEG10SampleRates

protected static final int[] MPEG10SampleRates

MPEG20SampleRates

protected static final int[] MPEG20SampleRates

MPEG25SampleRates

protected static final int[] MPEG25SampleRates

FRAME_SAMPLES_MPEG_1

private static int FRAME_SAMPLES_MPEG_1

FRAME_SAMPLES_MPEG_2

private static int FRAME_SAMPLES_MPEG_2

mpegVersion

protected int mpegVersion

mpegLayer

protected int mpegLayer

isProtected

protected boolean isProtected

bitRate

protected int bitRate

sampleRate

protected int sampleRate

padded

protected boolean padded

channelMode

protected int channelMode

modeExtension

protected int modeExtension

copyrighted

protected boolean copyrighted

original

protected boolean original

emphasis

protected int emphasis

data

protected byte[] data

bit_rate

protected int bit_rate

sample_rate

protected int sample_rate
Constructor Detail

MP3Frame

public MP3Frame()
Method Detail

getBitRate

public int getBitRate()

getSampleRate

public int getSampleRate()

isStereo

public boolean isStereo()

getDataLength

public int getDataLength()

getSamplesPerFrame

public int getSamplesPerFrame()

readFrame

public static MP3Frame readFrame(java.io.InputStream in)
                          throws java.io.IOException
Read the next MP3 frame from the stream - return null if no more


write

public void write(java.io.OutputStream out)
           throws java.io.IOException

toString

public java.lang.String toString()
Description copied from class: java.lang.Object
Convert this Object to a human-readable String. There are no limits placed on how long this String should be or what it should contain. We suggest you make it as intuitive as possible to be able to place it into System.out.println() 55 and such.

It is typical, but not required, to ensure that this method never completes abruptly with a java.lang.RuntimeException.

This method will be called when performing string concatenation with this object. If the result is null, string concatenation will instead use "null".

The default implementation returns getClass().getName() + "@" + Integer.toHexString(hashCode()).