public final class Track extends Object
Modifier and Type | Class and Description |
---|---|
static interface |
Track.Transformation
The transformation to apply to samples in the track, if any.
|
Modifier and Type | Field and Description |
---|---|
long |
durationUs
The duration of the track in microseconds, or
C.TIME_UNSET if unknown. |
long[] |
editListDurations
Durations of edit list segments in the movie timescale.
|
long[] |
editListMediaTimes
Media times for edit list segments in the track timescale.
|
Format |
format
The format.
|
int |
id
The track identifier.
|
long |
movieTimescale
The movie timescale.
|
int |
nalUnitLengthFieldLength
For H264 video tracks, the length in bytes of the NALUnitLength field in each sample.
|
int |
sampleTransformation
One of
TRANSFORMATION_* . |
long |
timescale
The track timescale, defined as the number of time units that pass in one second.
|
static int |
TRANSFORMATION_CEA608_CDAT
A transformation for caption samples in cdat atoms.
|
static int |
TRANSFORMATION_NONE
A no-op sample transformation.
|
int |
type
|
Constructor and Description |
---|
Track(int id,
int type,
long timescale,
long movieTimescale,
long durationUs,
Format format,
int sampleTransformation,
TrackEncryptionBox[] sampleDescriptionEncryptionBoxes,
int nalUnitLengthFieldLength,
long[] editListDurations,
long[] editListMediaTimes) |
Modifier and Type | Method and Description |
---|---|
TrackEncryptionBox |
getSampleDescriptionEncryptionBox(int sampleDescriptionIndex)
Returns the
TrackEncryptionBox for the given sample description index. |
public static final int TRANSFORMATION_NONE
public static final int TRANSFORMATION_CEA608_CDAT
public final int id
public final int type
public final long timescale
public final long movieTimescale
public final long durationUs
C.TIME_UNSET
if unknown.public final Format format
public final int sampleTransformation
TRANSFORMATION_*
. Defines the transformation to apply before outputting each
sample.public final long[] editListDurations
public final long[] editListMediaTimes
public final int nalUnitLengthFieldLength
public Track(int id, int type, long timescale, long movieTimescale, long durationUs, Format format, int sampleTransformation, @Nullable TrackEncryptionBox[] sampleDescriptionEncryptionBoxes, int nalUnitLengthFieldLength, long[] editListDurations, long[] editListMediaTimes)
public TrackEncryptionBox getSampleDescriptionEncryptionBox(int sampleDescriptionIndex)
TrackEncryptionBox
for the given sample description index.sampleDescriptionIndex
- The given sample description indexTrackEncryptionBox
for the given sample description index. Maybe null if no
such entry exists.