net.sf.fmj.media.codec.video.jpeg
Class JpegRTPHeader

java.lang.Object
  extended by net.sf.fmj.media.codec.video.jpeg.JpegRTPHeader

public class JpegRTPHeader
extends java.lang.Object

A JPEG/RTP header. A special header is added to each packet that immediately follows the RTP header: 0 1 2 3 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Type specific | Fragment Offset | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Type | Q | Width | Height | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+


Field Summary
static int HEADER_SIZE
          In bytes.
 
Constructor Summary
JpegRTPHeader(byte typeSpecific, int fragmentOffset, byte type, byte q, byte width, byte height)
           
 
Method Summary
 boolean equals(java.lang.Object o)
           
 int getFragmentOffset()
           
 int getHeightInBlocks()
           
 int getHeightInPixels()
           
 int getQ()
           
 int getType()
           
 int getTypeSpecific()
           
 int getWidthInBlocks()
           
 int getWidthInPixels()
           
 int hashCode()
           
static JpegRTPHeader parse(byte[] data, int offset)
           
 byte[] toBytes()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

HEADER_SIZE

public static final int HEADER_SIZE
In bytes.

See Also:
Constant Field Values
Constructor Detail

JpegRTPHeader

public JpegRTPHeader(byte typeSpecific,
                     int fragmentOffset,
                     byte type,
                     byte q,
                     byte width,
                     byte height)
Method Detail

parse

public static JpegRTPHeader parse(byte[] data,
                                  int offset)

toBytes

public byte[] toBytes()

getWidthInPixels

public int getWidthInPixels()

getHeightInPixels

public int getHeightInPixels()

getWidthInBlocks

public int getWidthInBlocks()

getHeightInBlocks

public int getHeightInBlocks()

getFragmentOffset

public int getFragmentOffset()

getQ

public int getQ()

getType

public int getType()

getTypeSpecific

public int getTypeSpecific()

toString

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

equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object