Class MpegTrackFragmentHeader


  • public class MpegTrackFragmentHeader
    extends java.lang.Object
    Header for an MP4 track in a fragment.
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      static class  MpegTrackFragmentHeader.Builder
      A helper for building an instance of this class.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      long baseTimecode
      The timecode at which this track is at the start of this fragment
      int dataOffset
      The offset of the data for this track in this fragment
      int[] sampleDurations
      Duration of each sample for this track in this fragment using file timescale
      int[] sampleSizes
      Size of each sample for this track in this fragment
      int trackId
      Track ID which this header is for
    • Constructor Summary

      Constructors 
      Constructor Description
      MpegTrackFragmentHeader​(int trackId, long baseTimecode, int dataOffset, int[] sampleDurations, int[] sampleSizes)  
    • Method Summary

      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • trackId

        public final int trackId
        Track ID which this header is for
      • baseTimecode

        public final long baseTimecode
        The timecode at which this track is at the start of this fragment
      • dataOffset

        public final int dataOffset
        The offset of the data for this track in this fragment
      • sampleDurations

        public final int[] sampleDurations
        Duration of each sample for this track in this fragment using file timescale
      • sampleSizes

        public final int[] sampleSizes
        Size of each sample for this track in this fragment
    • Constructor Detail

      • MpegTrackFragmentHeader

        public MpegTrackFragmentHeader​(int trackId,
                                       long baseTimecode,
                                       int dataOffset,
                                       int[] sampleDurations,
                                       int[] sampleSizes)
        Parameters:
        trackId - Track ID which this header is for
        baseTimecode - The timecode at which this track is at the start of this fragment
        dataOffset - The offset of the data for this track in this fragment
        sampleDurations - Duration of each sample for this track in this fragment using file timescale
        sampleSizes - Size of each sample for this track in this fragment