Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.red5.io.mp4
Class MP4Frame

    java.lang.Object
      org.red5.io.mp4.MP4Frame

All Implemented Interfaces:
  Comparable<MP4Frame>

    public class MP4Frame

extends Object
implements Comparable<MP4Frame>

Represents an MP4 frame / chunk sample

Author:
  Paul Gregoire (mondain@gmail.com)

Constructor Summary
`MP4Frame()`

Method Summary
`int` | `compareTo(MP4Frame that)` The frames are expected to be sorted by their timestamp
`boolean` | `equals(Object obj)`
`long` | `getOffset()` Returns the offset of the data chunk in the media source.
`int` | `getSize()` Returns the size of the data chunk.
`double` | `getTime()` Returns the timestamp.
`byte` | `getType()` Returns the data type, being audio or video.
`int` | `hashCode()`
`boolean` | `isKeyFrame()` Returns whether or not this chunk represents a key frame.
`void` | `setKeyFrame(boolean keyFrame)`
`void` | `setOffset(long offset)`
`void` | `setSize(int size)`
`void` | `setTime(double time)`
`void` | `setType(byte type)`
`String` | `toString()`

Methods inherited from class java.lang.Object
`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

Constructor Detail

### MP4Frame

    public MP4Frame()

Method Detail

### getType

    public byte getType()

  Returns the data type, being audio or video.

  Returns:
    the data type

### setType

    public void setType(byte type)

### getOffset

    public long getOffset()

  Returns the offset of the data chunk in the media source.

  Returns:
    the offset in bytes

### setOffset

    public void setOffset(long offset)

### getSize

    public int getSize()

  Returns the size of the data chunk.

  Returns:
    the size in bytes

### setSize

    public void setSize(int size)

### getTime

    public double getTime()

  Returns the timestamp.

  Returns:
    the timestamp

### setTime

    public void setTime(double time)

### isKeyFrame

    public boolean isKeyFrame()

  Returns whether or not this chunk represents a key frame.

  Returns:
    true if a key frame

### setKeyFrame

    public void setKeyFrame(boolean keyFrame)

### hashCode

    public int hashCode()

  Overrides:
    `hashCode` in class `Object`

### equals

    public boolean equals(Object obj)

  Overrides:
    `equals` in class `Object`

### toString

    public String toString()

  Overrides:
    `toString` in class `Object`

### compareTo

    public int compareTo(MP4Frame that)

  The frames are expected to be sorted by their timestamp

  Specified by:
    `compareTo` in interface `Comparable<MP4Frame>`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2006-2010 The Red5 Project