mp4(H264容器)的详细文件格式分析

十六进制码流分析:

      ftyp Box
      00 00 00 1C:  size ,28,表示此BOX有28个字节,表示长度的四个字节也计算在内。以下同
      66 74 79 70:  type,表示BOX TYPE,此处为ftyp
      6D 70 34 32:  可能是兼容的格式信息,/mp42
      00 00 00 00:  可能是插入的空字节,/也可能是version ,flags
      6D 70 34 32:  可能是兼容的格式信息,mp42/   major-brand
      6D 70 34 31:  可能是兼容的格式信息,mp41/ minor-version
      69 73 6F 6D:  isom, ftyp中的最后一个标识,compatible-brands[];  // to end of the  box

      The brand ‘mp41’ is defined as identifying version 1 of this specification
      (ISO/IEC 14496-1:2001), and the brand ‘mp42’ identifies this version of
      the specification;  at least one of these brands shall appear in the
      compatible-brands list in the file-type box, in all files conforming to
      this specification.

      moov Box
      00 03 B0 59:  size of moov.241753个字节
      6D 6F 6F 76:  moov

      mvhd Box
      00 00 00 6C:  size,mvhd Box的大小为108个字节
      6D 76 68 64:  mvhd
      00 00 00 00:  version,flags
      BE EE 87 C5:  creation-time创建文件的时间,是距离1904年1月1日0点的秒数
      BE EE 87 C5:  modifiation-time修改文件的时间,
      00 01 5F 90:  timescale时标,时间刻度的单位,为1/90 000秒
      01 A8 61 B8:  duration持续时间
      00 01 00 00:  rate播放描述的等级
      01 00:    volume播放时的音量
      00 00:    保留的16bits的0
      00 00 00 00:  保留的32bits的0
      00 00 00 00:   保留的32bits的0
      00 01 00 00   00 00 00 00   00 00 00 00   00 00 00 00
      00 01 00 00   00 00 00 00   00 00 00 00   00 00 00 00
      40 00 00 00    :  matrix给视频提供的转换矩阵
      00 00 00 00   00 00 00 00   00 00 00 00
      00 00 00 00  00 00 00 00   00 00 00 00:  6个32bits的pre-defined 的0
      00 01 00 CA:  next-track-ID下一个轨迹ID

      iods Box
      00 00 00 21:  size of iods,33个字节
      69 6F 64 73:  iods, Initial Object Descriptor
      00 00 00 00:  version,flags
      10 13 00 4F:  可能是OD, Object Descriptor
      FF FF 0F FE:
      FF 0E 04 00:
      00 00 01 0E:
      04 00 00 00:
      02

      udta Box
      00 00 06 8F:  size of udta ,1679
      75 64 74 61:  udta,


      uuid Box
      00 00 04 A9:  size of uuid,1193
      75 75 69 64:  uuid
      F7 8C AA 0C 36 BE 4C E9 88 D2 03 C2 56 DA BE B2  :  由于boxtype =
      uuid而定义的16个字节的usertype

      EES-3-0-410
      VE
      AE
      AudioEncoder-2-1-11
      V bitRate=2000000bps
      V keyFrame Period In Ms=10000
      V number of Pass=2
      V progressive Interlaced=0
      V rateControlMode=cbr
      V smoothVsSharp=0
      V sourceNature=natural
      V useBFrame =false.此处表明本码流没有使用B帧
      V videoEncoderType=mpeg4
      V advVideo EncoderType=mpeg4
      V allowBitRateUnderflow=false
      V change Rgb Yuv Conversion=false
      V setCustomBitmapSize=false
      V useCustomPixedAspectRatio=false
      V useExpertFeaturesASP=false
      V useMotionFiltering=false
      V useVideoPacket=false
      V vbvSizeInMs=1000
      V burnLogo=false
      V changeframerate=false
      V useColorAdjustment=false
      V useCropFilter=false
      V useScaleFilter=false
      V useSpatialFilter=false
      V useTimecodes=false

      A audioEncoderType=aac
      A bitRate=64000bps
      A useAutomaticBandwidth=true
      A useMS=true
      A balanceLeftRight=0
      A volumeInDB=0
      starttime=0
      stoptime=9223372036854775807,
      MTUSize=1448
      exportType=mp4
      hinted=true
      progressiveDownload=true
      allowDebugInformationInStream=true
      avoidQuickTime6Warnings=false
      forceETV15compatibility=false
      forcePlayerCompatibility=false
      multiThreadedOptimization=0
      openAVIWith=DirectShow
      previewOnOff=1
      previewlayout=0
      showEncodingStatistics=true
      .......................


      hnti Box
      00 00 01 DE:size of hnti,478
      68 6E 74 69:hnti

      rtp Box
      00 00 01 D6:size of rtp,470
      72 74 70 20:rtp
      73 64 70 20:sdp
      a=mpeg4-iod:”data:application/mpeg4-iod;
      base64

      ................................

      trak Box
      00 00 01 A4:  size of trak,420
      74 72 61 6B:  trak

      tkhd Box
      00 00 00 5C:  size of tkhd,92
      74 6B 68 64:  tkhd, track head box
      00 00 00 01:  00,version;  00 00 01,track enable flags
      BE EE 87 C5:  creation-time创建文件的时间
      BE EE 87 C5:  modifiation-time修改文件的时间,两个时间应该相同
      00 00 00 01:  track-ID
      00 00 00 00:  保留的32bits的0
      01 A8 5E 16:  duration持续的时间
      00 00 00 00   00 00 00 00:  保留的2个32bits的0
      00 00:layer 0
      00 00:pre-defined 0
      00 00:volume,as non audio,if audio ,0x0100
      00 00:reserved 0
      00 01 00 00   00 00 00 00
      00 00 00 00    00 00 00 00    00 01 00 00    00 00 00 00
      00 00 00 00    00 00 00 00    40 00 00 00    :matrix
      00 00 00 00:width,if track_is_visual 0x01400000 else 0
      00 00 00 00:height,if track_is_visual 0x00F00000 else 0


      mdia Box
      00 00 01 28:  size of mdia,296
      6D 64 69 61:  mdia


      mdhd Box
      00 00 00 20:  size of mdhd ,32
      6D 64 68 64:  mdhd
      00 00 00 00:  version
      BE EE 87 C5:  creation-time
      BE EE 87 C5:  modification-time
      00 00 03 E8:  timescale
      00 04 B7 17:  duration
      0  :pad
      10101 01110 00100:  3个5bits的language
      00 00 :pre-defined 0

 

      hdlr Box
      00 00 00 21:size of hdlr,33
      68 64 6C 72:  hdlr
      00 00 00 00:  version
      00 00 00 00:  pre-defined 0
      6F 64 73 6D:  odsm,handler-type. ObjectDescriptorStream
      00 00 00 00   00 00 00 00   00 00 00 00 :  3个reserved
      00  :string  name

      minf  Box
      00 00 00 DF:  size of minf,223
      6D 69 6E 66:  minf

      nmhd Box
      00 00 00 0C:  size of nmhd,12
      6E 6D 68 64:  nmhd
      00 00 00 00:  version

      dinf Box
      00 00 00 24:  size of dinf,36
      64 69 6E 66:  dinf

      dref Box
      00 00 00 1C:  size of dref,28
      64 72 65 66:  dref
      00 00 00 00:  version
      00 00 00 01:  entry-count

      url Box
      00 00 00 0C: size of url ,12
      75 72 6C 20:  url
      00 00 00 01:  location

      stbl Box
      00 00 00 A7:  size of stbl,167
      73 74 62 6C:  stbl

      stsd Box
      00 00 00 43:  size of stsd,67
      73 74 73 64:  stsd
      00 00 00 00:  version,flags
      00 00 00 01:  entry-count

      mp4s Box
      00 00 00 33:  size of mp4s, 51
      6D 70 34 73:  mp4s
      00 00 00 00:  version
      00 00 00 01:  ES

      esds Box
      00 00 00 23:  size of esds,35
      65 73 64 73:  esds
      00 00 00 00:  version
      03 15 00 00:
      00 04 0D 01:
      05 00 00 C8:
      00 00 00 00:
      00 00 00 00:
      06 01 02:

      stts Box
      00 00 00 18:   size of stts,24
      73 74 74 73:  stts
      00 00 00 00:  version
      00 00 00 01:  entry-count
      00 00 00 01:  sample-count
      00 04 B7 17:  sample-delta

      stsc Box
      00 00 00 1C:  size of stsc ,28
      73 74 73 63:  stsc
      00 00 00 00:  version
      00 00 00 01:  entry-count
      00 00 00 01:  first-chunk
      00 00 00 01:  samples-per-chunk
      00 00 00 01:  sample-description-index

      stsz Box
      00 00 00 14:  size of stsz,20
      73 74 73 7A:  stsz
      00 00 00 00:  version
      00 00 00 12:  sample-size
      00 00 00 01:  sample-count

      stco Box
      00 00 00 14:  size of stco,20
      73 74 63 6F:  stco
      00 00 00 00:  version
      00 00 00 01:  entry-count
      00 03 B0 7D:  chunk-offset

      tref Box
      00 00 00 18:  size of tref,24
      74 72 65 66:  tref

      mpod Box
      00 00 00 10:  size of mpod,16
      6D 70 6F 64:  mpod
      00 00 00 C9:
      00 00 00 65:

      trak Box
      00 00 01  91: size of trak,401
      74 72 61 6B:  trak

      tkhd Box
      00 00 00 5C:  size of tkhd,92
      74 6B 68 64:  tkhd
      00 00 00 01:  00,version;  00 00 01,track enable flags
      BE EE 87 C5:  creation-time创建文件的时间
      BE EE 87 C5:  modifiation-time修改文件的时间,两个时间应该相同
      00 00 00 02:  track-ID
      00 00 00 00:  保留的32bits的0
      01 A8 5E 16:  duration持续的时间
      00 00 00 00   00 00 00 00:  保留的2个32bits的0
      00 00:layer 0
      00 00:pre-defined 0
      00 00:volume,as non audio,if audio ,0x0100
      00 00:reserved 0
      00 01 00 00   00 00 00 00
      00 00 00 00    00 00 00 00    00 01 00 00    00 00 00 00
      00 00 00 00    00 00 00 00    40 00 00 00    :matrix
      00 00 00 00:width,if track_is_visual 0x01400000 else 0
      00 00 00 00:height,if track_is_visual 0x00F00000 else 0

      mdia Box
      00 00 01 2D:size of mdia,301
      6D 64 69 61:mdia

      mdhd Box
      00 00 00 20:  32
      6D 64 68 64:mdhd
      00 00 00 00 :version,flags
      BE EE 87 C5: creation-time创建文件的时间
      BE EE 87C5: modifiation-time修改文件的时间,两个时间应该相同
      00 00 03 E8: timescale时标
      00 04 B7 17: duration持续的时间
      55 C4:pad, 3个5bits的language
      00 00: pre-defined 0

      hdlr Box
      00 00 00 21:size of hdlr ,33
      68 64 6C 72:  hdlr
      00 00 00 00:  version
      00 00 00 00:  pre-defined 0
      73 64 73 6D:  sdsm,handler-type, SceneDescriptionStream
      00 00 00 00   00 00 00 00   00 00 00 00 :  3个reserved
      00  :string  name

      minf  Box
      00 00 00 E4:  size of minf,228
      6D 69 6E 66:  minf

      nmhd Box
      00 00 00 0C:  size of nmhd,12
      6E 6D 68 64:  nmhd
      00 00 00 00:  version

      dinf Box
      00 00 00 24:  size of dinf,36
      64 69 6E 66:  dinf

      dref Box
      00 00 00 1C:  size of dref,28
      64 72 65 66:  dref
      00 00 00 00:  version
      00 00 00 01:  entry-count

      url Box
      00 00 00 0C: size of url ,12
      75 72 6C 20:  url
      00 00 00 01:  location

      stbl Box
      00 00 00 AC:  size of stbl,172
      73 74 62 6C:  stbl

      stsd Box
      00 00 00 48:  size of stsd,72
      73 74 73 64:  stsd
      00 00 00 00:  version,flags
      00 00 00 01:  entry-count

      mp4s Box
      00 00 00 38:  size of mp4s, 56
      6D 70 34 73:  mp4s
      00 00 00 00:  version
      00 00 00 01:  ES

      esds Box
      00 00 00 28:  size of esds,40
      65 73 64 73:  esds
      00 00 00 00:  version
      03 1A 00 00:
      00 04 12 02:
      0D 00 00 20:
      00 00 00 00:
      00 00 00 00:
      05 03 00 00:
      40 06 01 02:

      stts Box
      00 00 00 18:   size of stts,24
      73 74 74 73:  stts
      00 00 00 00:  version
      00 00 00 01:  entry-count
      00 00 00 01:  sample-count
      00 04 B7 17:  sample-delta

      stsc Box
      00 00 00 1C:  size of stsc ,28
      73 74 73 63:  stsc
      00 00 00 00:  version
      00 00 00 01:  entry-count
      00 00 00 01:  first-chunk
      00 00 00 01:  samples-per-chunk
      00 00 00 01:  sample-description-index

      stsz Box
      00 00 00 14:  size of stsz,20
      73 74 73 7A:  stsz
      00 00 00 00:  version
      00 00 00 18:  sample-size
      00 00 00 01:  sample-count

      stco Box
      00 00 00 14:  size of stco,20
      73 74 63 6F:  stco
      00 00 00 00:  version
      00 00 00 01:  entry-count
      00 03 B0 8F:  chunk-offset


      trak Box
      00 01 71 55:size of trak,
      74 72 61 6B:trak

      tkhd Box
      00 00 00 5C:  size of tkhd,92
      74 6B 68 64:  tkhd, track head box
      00 00 00 01:  00,version;  00 00 01,track enable flags
      BE EE 87 C5:  creation-time创建文件的时间
      BE EE 87 C5:  modifiation-time修改文件的时间,两个时间应该相同
      00 00 00 C9:  track-ID
      00 00 00 00:  保留的32bits的0
      01 A8 61 B8:  duration持续的时间
      00 00 00 00   00 00 00 00:  保留的2个32bits的0
      00 00:layer 0
      00 00:pre-defined 0
      00 00:volume,as non audio,if audio ,0x0100
      00 00:reserved 0
      00 01 00 00   00 00 00 00
      00 00 00 00    00 00 00 00    00 01 00 00    00 00 00 00
      00 00 00 00    00 00 00 00    40 00 00 00    :matrix
      02 D0 00 00:width,if track_is_visual 0x01400000 else 0
      01 E0 00 00:height,if track_is_visual 0x00F00000 else 0

      mdia Box
      00 01 70 CD:  size of mdia
      6D 64 69 61:  mdia


      mdhd Box
      00 00 00 20:  size of mdhd ,32
      6D 64 68 64:  mdhd
      00 00 00 00:  version
      BE EE 87 C5:  creation-time
      BE EE 87 C5:  modification-time
      00 01 5F 90:  timescale
      01 A8 61 B8:  duration
      0  :pad
      10101 01110 00100:  3个5bits的language
      00 00 :pre-defined 0

      hdlr Box
      00 00 00 21:size of hdlr,33
      68 64 6C 72:  hdlr
      00 00 00 00:  version
      00 00 00 00:  pre-defined 0
      76 69 64 65:  vide,handler-type,表示此trak为视频
      00 00 00 00   00 00 00 00   00 00 00 00 :  3个reserved
      00  :string  name


      minf  Box
      00 01 70 84:  size of minf,94340
      6D 69 6E 66:  minf

      vmhd Box
      00 00 00 14:  size of nmhd
      76 6D 68 64:  nmhd
      00 00 00 01:  version,flags
      00 00 00 00:
      00 00 00 00:

 


      dinf Box
      00 00 00 24:  size of dinf,36
      64 69 6E 66:  dinf

      dref Box
      00 00 00 1C:  size of dref,28
      64 72 65 66:  dref
      00 00 00 00:  version
      00 00 00 01:  entry-count

      url Box
      00 00 00 0C: size of url ,12
      75 72 6C 20:  url
      00 00 00 01:  location

      stbl Box
      00 01 70 44:  size of stbl
      73 74 62 6C:  stbl

      stsd Box
      00 00 00 AC:  size of stsd,72
      73 74 73 64:  stsd
      00 00 00 00:  version,flags
      00 00 00 01:  entry-count

      mp4v Box
      00 00 00 9C:  size of mp4v
      6D 70 34 76:  mp4v
      00 00 00 00:  version
      00 00 00 01:  ES
      00 00 00 00 00 00 :
      00 00 00 00 00 00 00 00 00 00 02 D0 01 E0 00 48
      00 00 00 48 00 00 00 00 00 00 00 01 00 00 00 00
      00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
      00 00 00 00 00 00 00 00 00 00 00 00 00 18 FF FF

      esds Box
      00 00 00 46:  size of esds
      65 73 64 73:  esds
      00 00 00 00:  version
      03 38 00 00:
      00 04 30 20:
      11 03 D0 90:
      00 1E 84 80:
      00 1E 84 80:
      05 21 00 00:
      01 B0 00 00:
      00 01 B5 0E:
      A0 20 20 2F:
      00 00 01 00:
      00 00 01 20:
      00 C7 88 BA:
      98 51 68 43:
      C1 46 3F 06:
      01 02 :

      stts Box
      00 00 E7 90:   size of stts
      73 74 74 73:  stts
      00 00 00 00:  version
      00 00 1C F0:  entry-count
      00 00 00 01:  sample-count
      00 00 0B BB:  sample-delta
      00 00 00 01
      00 00 11 97
      00 00 00 01
      00 00 0B BB
      00 00 00 01
      00 00 11 9A
      ...........

      stsc Box
      00 00 0E 8C:  size of stsc ,
      73 74 73 63:  stsc
      00 00 00 00:  version
      00 00 01 35:  entry-count

      00 00 00 01:  first-chunk
      00 00 00 15:  samples-per-chunk
      00 00 00 01:  sample-description-index

      00 00 00 02
      00 00 00 18
      00 00 00 01

      00 00 00 03
      00 00 00 18
      00 00 00 01

      00 00 00 04
      00 00 00 18
      00 00 00 01
      .............

      stsz Box
      00 00 73 D8  size of stsz,20
      73 74 73 7A:  stsz
      00 00 00 00:  version
      00 00 00 00:  sample-size
      00 00 1C F1:  sample-count
      00 00 86
      24(从此开始,为当前chunk中每帧视频数据的字节大小,此大小与offset相对应,用offset找到偏移的绝对地址(指向mdat
      box中)后,从000001B6的第一个字节开始,加上对应的视频字节数,就是本帧的大小。一个视频chunk中首先是连续的视频帧,然后也包含其他数据,暂不清楚视频数据后面的数据类型)
      00 00 08 F9
      00 00 3B 04
      00 00 1D F2
      00 00 49 00
      00 00 60 A6
      00 00 2E 30
      00 00 33 F9
      00 00 22 19
      00 00 15 DB
      00 00 17 47
      00 00 1D 16
      00 00 3A 4A
      00 00 1C 1B
      00 00 2C EA
      00 00 37 28
      00 00 3D 70
      00 00 36 0B
      00 00 16 D0
      00 00 39 0F
      00 00 22 79
      第一个chunk中所有的视频帧大小结束
      下面为当前chunk中视频数据后面暂不清楚为什么数据类型的开始
      00 00 15 DB
      00 00 17 47
      ................

 

      stco Box
      00 00 04 E4:  size of stco,20
      73 74 63 6F:  stco
      00 00 00 00:  version
      00 00 01 35:  entry-count
      00 03 B0 A7:  chunk-offset(帧数据偏移的绝对地址(指向mdat
      box中),此处为视频数据,一个chunk约包含1S的数据,但不固定)
      00 07 F1 5D
      00 0B 58 D7
      00 0E 58 9D
      00 11 A5 3E
      00 15 11 0B
      00 18 15 4E

 

      stss Box
      00 00 00 B8:size
      73 74 73 73:stss
      00 00 00 00:version,flags
      00 00 00 2A:entry_count
      00 00 00 01
      00 00 00 12
      00 00 00 38
      00 00 01 63
      00 00 02 8E
      00 00 03 B9
      00 00 04 E4
      00 00 05 83
      00 00 06 AE
      00 00 07 26
      00 00 07 47
      00 00 07 68
      00 00 08 67
      00 00 08 73


      ...............

      udta Box
      00 00 00 24:
      75 64 74 61:

      uuid Box
      00 00 00 1C:  size of uuid
      75 75 69 64:  uuid
      F7 8C AA 0C 36 BE 4C E9 87 D2 03 C2 56 DA BE B2  :  由于boxtype =
      uuid而定义的16个字节的usertype
      与前面不同
      00 01 19 9A

      trak Box
      00 01 72 D5
      74 72 61 6B

      tkhd Box
      00 00 00 5C:  size of tkhd,92
      74 6B 68 64:  tkhd, track head box
      00 00 00 00:  00,version;  00 00 00,track enable flags
      BE EE 87 C5:  creation-time创建文件的时间
      BE EE 87 C5:  modifiation-time修改文件的时间,两个时间应该相同
      00 01 00 C9:  track-ID
      00 00 00 00:  保留的32bits的0
      01 A8 61 B8:  duration持续的时间
      00 00 00 00   00 00 00 00:  保留的2个32bits的0
      00 00:layer 0
      00 00:pre-defined 0
      00 00:volume,as non audio,if audio ,0x0100
      00 00:reserved 0
      00 01 00 00   00 00 00 00
      00 00 00 00    00 00 00 00    00 01 00 00    00 00 00 00
      00 00 00 00    00 00 00 00    40 00 00 00    :matrix
      00 00 00 00:width,if track_is_visual 0x01400000 else 0
      00 00 00 00:height,if track_is_visual 0x00F00000 else 0

      mdia Box
      00 01 70 5D:  size of mdia
      6D 64 69 61:  mdia


      mdhd Box
      00 00 00 20:  size of mdhd ,32
      6D 64 68 64:  mdhd
      00 00 00 00:  version
      BE EE 87 C5:  creation-time
      BE EE 87 C5:  modification-time
      00 01 5F 90:  timescale
      01 A8 61 B8:  duration
      0  :pad
      10101 01110 00100:  3个5bits的language
      00 00 :pre-defined 0


      hdlr Box
      00 00 00 21:size of hdlr,33
      68 64 6C 72:  hdlr
      00 00 00 00:  version
      00 00 00 00:  pre-defined 0
      68 69 6E 74:  hint,handler-type
      00 00 00 00   00 00 00 00   00 00 00 00 :  3个reserved
      00  :string  name

      minf  Box
      00 01 70 14:  size of minf
      6D 69 6E 66:  minf

      hmhd Box
      00 00 00 1C
      68 6D 68 64
      00 00 00 00
      05 A8 05 3B
      00 1E 84 80
      00 18 70 4E
      00 1E 84 80


      dinf Box
      00 00 00 24:  size of dinf,36
      64 69 6E 66:  dinf

      dref Box
      00 00 00 1C:  size of dref,28
      64 72 65 66:  dref
      00 00 00 00:  version
      00 00 00 01:  entry-count

      url Box
      00 00 00 0C: size of url ,12
      75 72 6C 20:  url
      00 00 00 01:  location

      stbl Box
      00 01 6F CC:  size of stbl,
      73 74 62 6C:  stbl

      stsd Box
      00 00 00 34:  size of stsd,
      73 74 73 64:  stsd
      00 00 00 00:  version,flags
      00 00 00 01:  entry-count


      rtp
      00 00 00 24
      72 74 70 20:rtp
      00 00 00 00
      00 00 00 01
      00 01 00 01
      00 00 05 A8


      tims
      00 00 00 0C
      74 69 6D 73
      00 01 5F 90

      stts
      00 00 E7 90
      73 74 74 73
      00 00 00 00:  version
      00 00 1C F0:  entry-count
      00 00 00 01:  sample-count
      00 00 0B BB:  sample-delta
      00 00 00 01
      00 00 11 97
      00 00 00 01
      00 00 0B BB
      00 00 00 01
      00 00 11 9A
      ..................

      stsc
      00 00 0E 8C
      73 74 73 63
      00 00 00 00:  version
      00 00 01 35:  entry-count

      00 00 00 01:  first-chunk
      00 00 00 18:  samples-per-chunk
      00 00 00 01:  sample-description-index

      00 00 00 02
      00 00 00 18
      00 00 00 01

      00 00 00 03
      00 00 00 18
      00 00 00 01

      ..............

 


      stsz Box
      00 00 73 D8:  size of stsz,20
      73 74 73 7A:  stsz
      00 00 00 00:  version
      00 00 00 00:  sample-size
      00 00 1C F1:  sample-count

      ..................

      stco
      00 00 04 E4
      73 74 63 6F
      00 00 00 00:  version
      00 00 01 35:  entry-count
      00 07 B1 24:chunk_offset
      00 0B 20 81


      ..............

      stss
      00 00 00 B8
      73 74 73 73
      .............

      tref
      00 00 00 14
      74 72 65 66

      hint
      00 00 00 0C
      68 69 6E 74
      00 00 00 C9

      udta
      00 00 02 00
      75 64 74 61

      hinf
      00 00 00 E2
      68 69 6E 66

      trpy
      00 00 00 10
      74 72 70 79
      00 00 00 00
      03 B8 8E 51

      nump
      00 00 00 10
      6E 75 6D 70
      00 00 00 00
      00 00 B6 0A

      tpyl
      00 00 00 10
      74 70 79 6C
      00 00 00 00
      03 B0 05 D9

      totl
      00 00 00 0C
      74 6F 74 6C
      03 B8 8E 51

      npck
      00 00 00 0C
      6E 70 63 6B
      00 00 B6 0A

      tpay
      00 00 00 0C
      74 70 61 79
      03 B0 05 D9

      dmed
      00 00 00 10
      64 6D 65 64
      00 00 00 00
      03 B0 05 B8

      dimm
      00 00 00 10
      64 69 6D 6D
      00 00 00 00
      00 00 00 21

      drep
      00 00 00 10
      64 72 65 70
      00 00 00 00
      00 00 00 00

      tmin
      00 00 00 0C
      74 6D 69 6E
      FF FF FC 18

      tmax
      00 00 00 0C
      74 6D 61 78
      00 00 00 00

      pmax
      00 00 00 0C
      70 6D 61 78
      00 00 05 A8

      dmax
      00 00 00 0C
      64 6D 61 78
      00 00 00 32

      payt
      00 00 00 26
      70 61 79 74
      00 00 00 60 19
      a=rtpmap:96 MP4V-ES/90000
      hnti
      sdp m=video 0 RTP/AVP 96
      b=AS:2048
      a=rtpmap:96 MP4V-ES/90000
      a=fmtp:96 profile-level-id=254;config=
      a=cliprect:0,0,480,720
      a=mpeg4-esid:201
      a=x-envivio-verid:0001199A
      a=control:trackID=65737

      trak
      00 00 AB 60
      74 72 61 6B

      tkhd Box
      00 00 00 5C:  size of tkhd,92
      74 6B 68 64:  tkhd
      00 00 00 01:  00,version;  00 00 01,track enable flags
      BE EE 87 C5:  creation-time创建文件的时间
      BE EE 87 C5:  modifiation-time修改文件的时间,两个时间应该相同
      00 00 00 65:  track-ID
      00 00 00 00:  保留的32bits的0
      01 A8 07 40:  duration持续的时间
      00 00 00 00   00 00 00 00:  保留的2个32bits的0
      00 00:layer 0
      00 00:pre-defined 0
      00 00:volume,as non audio,if audio ,0x0100
      00 00:reserved 0
      00 01 00 00   00 00 00 00
      00 00 00 00    00 00 00 00    00 01 00 00    00 00 00 00
      00 00 00 00    00 00 00 00    40 00 00 00    :matrix
      00 00 00 00:width,if track_is_visual 0x01400000 else 0
      00 00 00 00:height,if track_is_visual 0x00F00000 else 0

      mdia Box
      00 00 AA D8:size of mdia,301
      6D 64 69 61:mdia

      mdhd Box
      00 00 00 20:  32
      6D 64 68 64:mdhd
      00 00 00 00 :version,flags
      BE EE 87 C5: creation-time创建文件的时间
      BE EE 87C5: modifiation-time修改文件的时间,两个时间应该相同
      00 00 7D 00: timescale时标
      00 96 C4 00: duration持续的时间
      55 C4:pad, 3个5bits的language
      00 00: pre-defined 0

      hdlr Box
      00 00 00 21:size of hdlr ,33
      68 64 6C 72:  hdlr
      00 00 00 00:  version
      00 00 00 00:  pre-defined 0
      73 6F 75 6E:  soun,handler-type,表示此trak为音频
      00 00 00 00   00 00 00 00   00 00 00 00 :  3个reserved
      00  :string  name

 

      minf Box
      00 00 AA 8F:size of minf
      6D 69 6E 66:minf

      smhd Box
      00 00 00 10:size of smhd
      73 6D 68 64:smhd
      00 00 00 00:version
      00 00 :balance,
      balance is a fixed-point 8.8 number that places mono audio tracks in a
      stereo space; 0 is center (the normal value); full left is -1.0 and full
      right is 1.0.
      00 00:reserved

      dinf Box
      00 00 00 24:size of dinf
      64 69 6E 66:dinf

      dref Box
      00 00 00 1C:  size of dref,28
      64 72 65 66:  dref
      00 00 00 00:  version
      00 00 00 01:  entry-count


      url Box
      00 00 00 0C: size of url ,12
      75 72 6C 20:  url
      00 00 00 01:  location


      stbl Box
      00 00 AA 53:  size of stbl
      73 74 62 6C:  stbl

      stsd Box
      00 00 00 5B:  size of stsd
      73 74 73 64:  stsd
      00 00 00 00:  version,flags
      00 00 00 01:  entry-count


      mp4a Box
      00 00 00 4B:
      6D 70 34 61:mp4a
      00 00 00 00:version
      00 00 00 01:ES
      00 00 00 00
      00 00 00 00
      00 02 00 10
      00 00 00 00
      7D 00 00 00

      esds box
      00 00 00 27
      65 73 64 73
      00 00 00 00:  version
      03 19 00 00:
      00 04 11 40:
      15 00 06 00:
      00 00 FA 00:
      00 00 FA 00:
      05 02 12 90:
      06 01 02 :

      stts
      00 00 00 18
      73 74 74 73:stts
      00 00 00 00:  version
      00 00 00 01:  entry-count
      00 00 25 B1:  sample-count
      00 00 04 00:  sample-delta

      stsc Box
      00 00 0E 38:  size of stsc 
      73 74 73 63:  stsc
      00 00 00 00:  version
      00 00 01 2E:  entry-count
      00 00 00 01:  first-chunk
      00 00 00 20:  samples-per-chunk
      00 00 00 01:  sample-description-index
      00 00 00 02
      00 00 00 20
      00 00 00 01
      00 00 00 03
      00 00 00 20
      00 00 00 01
      00 00 00 04
      00 00 00 20
      00 00 00 01

      ..........................

      stsz box
      00 00 96 D8:  size of stsz,
      73 74 73 7A:  stsz
      00 00 00 00:  version
      00 00 00 00:  sample-size
      00 00 25 B1:  sample-count

      .................................

      stco
      00 00 04 C8
      73 74 63 6F:stco
      00 00 00 00:  version
      00 00 01 2E:  entry-count
      00 07 C9 54:  chunk-offset
      00 0B 32 0D
      00 0E 32 9B
      ............................

      udta box
      00 00 00 24
      75 64 74 61

      uuid
      00 00 00 1C
      75 75 69 64
      F7 8C AA 0C 36 BE 4C E9 87 D2 03 C2 56 DA BE
      B2  :  由于boxtype = uuid而定义的16个字节的usertype
      00 01 19 9A


      trak
      00 00 16 76
      74 72 61 6B:  trak

      tkhd Box
      00 00 00 5C:  size of tkhd,92
      74 6B 68 64:  tkhd, track head box
      00 00 00 00:  00,version;  00 00 00,track enable flags
      BE EE 87 C5:  creation-time创建文件的时间
      BE EE 87 C5:  modifiation-time修改文件的时间,两个时间应该相同
      00 01 00 65:  track-ID
      00 00 00 00:  保留的32bits的0
      01 A8 07 40:  duration持续的时间
      00 00 00 00   00 00 00 00:  保留的2个32bits的0
      00 00:layer 0
      00 00:pre-defined 0
      00 00:volume,as non audio,if audio ,0x0100
      00 00:reserved 0
      00 01 00 00   00 00 00 00
      00 00 00 00    00 00 00 00    00 01 00 00    00 00 00 00
      00 00 00 00    00 00 00 00    40 00 00 00    :matrix
      00 00 00 00:width,if track_is_visual 0x01400000 else 0
      00 00 00 00:height,if track_is_visual 0x00F00000 else 0

      mdia box
      00 00 13 F9
      6D 64 69 61

      mdhd box
      00 00 00 20
      6D 64 68 64:mdhd
      00 00 00 00
      BE EE 87 C5
      BE EE 87 C5
      00 00 7D 00:timescale
      00 96 C4 00:duration
      55 C4=
      0  :pad
      10101 01110 00100:  3个5bits的language
      00 00 :pre-defined 0


      hdlr box
      00 00 00 21:size of hdlr,33
      68 64 6C 72:  hdlr
      00 00 00 00:  version
      00 00 00 00:  pre-defined 0
      68 69 6E 74:  hint,handler-type
      00 00 00 00   00 00 00 00   00 00 00 00 :  3个reserved
      00  :string  name

 


      minf  Box
      00 00 13 B0:  size of minf
      6D 69 6E 66:  minf

      hmhd box
      00 00 00 1C
      68 6D 68 64
      00 00 00 00
      05 A8 :maxPDU
      01 0C :avgPDU
      00 00 FA 00: maxbitrate
      00 00 FA 00: avgbitrate
      00 00 FA 00:此处应该为保留的0,有误?

      dinf Box
      00 00 00 24:  size of dinf,36
      64 69 6E 66:  dinf

      dref Box
      00 00 00 1C:  size of dref,28
      64 72 65 66:  dref
      00 00 00 00:  version
      00 00 00 01:  entry-count

      url Box
      00 00 00 0C: size of url ,12
      75 72 6C 20:  url
      00 00 00 01:  location


      stbl box
      00 00 13 68
      73 74 62 6C:  stbl

      stsd Box
      00 00 00 34:  size of stsd,67
      73 74 73 64:  stsd
      00 00 00 00:  version,flags
      00 00 00 01:  entry-count

      rtp box
      00 00 00 24
      72 74 70 20:rtp
      00 00 00 00
      00 00
      00 01: hinttrackversion
      00 01: highestcompatibleversion
      00 01 00 00 : maxpacketsize
      05 A8: additionaldata[]

 

      tims box
      00 00 00 0C
      74 69 6D 73
      00 00 7D 00: timescale

 


      stts box
      00 00 00 18
      73 74 74 73
      00 00 00 00:  version
      00 00 00 01:  entry-count
      00 00 25 B1:  sample-count
      00 00 04 00:  sample-delta

      stsc Box
      00 00 0E 38:  size of stsc
      73 74 73 63:  stsc
      00 00 00 00:  version
      00 00 01 2E:  entry-count
      00 00 00 01:  first-chunk
      00 00 00 20:  samples-per-chunk
      00 00 00 01:  sample-description-index

      00 00 00 02:  first-chunk
      00 00 00 20:  samples-per-chunk
      00 00 00 01:  sample-description-index

      00 00 00 03:  first-chunk
      00 00 00 20:  samples-per-chunk
      00 00 00 01:  sample-description-index

      00 00 00 04:  first-chunk
      00 00 00 20:  samples-per-chunk
      00 00 00 01:  sample-description-index


      .............................

      stsz Box
      00 00 00 14:  size of stsz,20
      73 74 73 7A:  stsz
      00 00 00 00:  version
      00 00 00 30:  sample-size
      00 00 25 B1:  sample-count

      stco Box
      00 00 04 C8:  size of stco
      73 74 63 6F:  stco
      00 00 00 00:  version
      00 00 01 2E:  entry-count
      00 07 EB 5D:  chunk-offset
      00 0B 52 D7
      ...........................

      tref Box
      00 00 00 14:  size of tref,
      74 72 65 66:  tref

      hint box
      00 00 00 0C
      68 69 6E 74
      00 00 00 65:track-IDS

      udta box
      00 00 02 05
      75 64 74 61

      hinf box
      00 00 00 EA
      68 69 6E 66

      trpy Box
      00 00 00 10:size of trpy,16
      74 72 70 79:trpy
      00 00 00 00 00 28 0E DE: uint(64)  bytessent;   // total bytes sent,
      including 12-byte RTP headers


      nump Box
      00 00 00 10:size of nump,16
      6E 75 6D 70:nump
      00 00 00 00 00 00 25 B1: uint(64)  packetssent

      tpyl Box
      00 00 00 10:size of tpyl,16
      74 70 79 6C:tpyl
      00 00 00 00 00 26 4A 92: uint(64)  bytessent;  // total bytes sent, not
      including RTP headers


      totl Box
      00 00 00 0C:size of totl,12
      74 6F 74 6C:totl
      00 28 0E DE: bytessent; }  // total bytes sent, including 12-byte RTP
      headers

      npck Box
      00 00 00 0C:size of npck,12
      6E 70 63 6B:npck
      00 00 25 B1: packetssent; }  // total packets sent

      tpay Box
      00 00 00 0C:size of tpay,12
      74 70 61 79:tpay
      00 26 4A 92: bytessent; }  // total bytes sent, not including RTP headers   dmed Box
      00 00 00 10:16
      64 6D 65 64:dmed
      00 00 00 00 00 25 B3 CE: bytessent; }  // total bytes sent from media    tracks

      dimm Box
      00 00 00 10:16
      64 69 6D 6D:dimm
      00 00 00 00 00 00 96 C4: bytessent; }  // total bytes sent immediate mode

 

      drep Box
      00 00 00 10:16
      64 72 65 70:drep
      00 00 00 00 00 00 00 00: bytessent; }  // total bytes in repeated packets


      tmin Box
      00 00 00 0C:12
      74 6D 69 6E: tmin
      FF FF FF 40: time;     // smallest relative transmission time, milliseconds


      tmax Box
      00 00 00 0C:12
      74 6D 61 78:tmax
      00 00 00 00: time; }    // largest relative transmission time,milliseconds


      pmax Box
      00 00 00 0C:12
      70 6D 61 78:pamx
      00 00 01 45: bytes; }      // largest packet sent, including RTP header


      dmax Box
      00 00 00 0C:12
      64 6D 61 78:dmax
      00 00 00 20: time; }      // longest packet duration, milliseconds

      payt Box
      00 00 00 2E:
      70 61 79 74:payt
      00 00 00 61: payloadID
      21 : count,
      a=rtpmap:97 mpeg4-generic/32000/2


      hnti Box
      00 00 01 13:
      68 6E 74 69:hnti

      sdp Box
      00 00 01 0B:
      73 64 70 20:sdp
      sdptext[]:
      m=audio 0 RTP/AVP 97
      b=AS:75
      a=rtpmap:97 mpeg4-generic/32000/2
      a=fmtp:97 profile-level-id =15
      config=1290
      streamtype=5
      mode=AAC-hbr
      SizeLength=13
      IndexLength=3
      IndexDeltaLength=3
      a=mpeg4-esid:101
      a=x-envivio=verid:0001199A
      a=control:trackID=65637

      mdat box
      03 F1 27 F4
      6D 64 61 74:mdat


本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.mzph.cn/news/454938.shtml

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

hdu 5925 搜索

题意&#xff1a;一个图&#xff0c;n个障碍&#xff0c;求联通块 思路&#xff1a; 图很大&#xff0c;障碍物很少。把联通的障碍物块抠出来&#xff0c;然后暴力。 代码&#xff1a; #include<bits/stdc.h> using namespace std; #define MEM(a,b) memset(a,b,sizeof(a…

分析数据库CitusDB:提供弹性计算能力

本文讲的是分析数据库CitusDB&#xff1a;提供弹性计算能力,企业数据库市场很庞大&#xff0c;在这个领域既有Oracle这样行家&#xff0c;也有IBM(DB2)和微软(SQL Server)这样的跨界巨头。它们都与中小企业常用到的开源数据库MySQL一样&#xff0c;都属于传统关系型数据库。似乎…

mysql不能创建innodb类型表_MYSQL have_innodb DISABLED无法创建innodb类型的表

今天在一台MYSQL服务器上发现&#xff0c;明明用了engineinnodb创建的表&#xff0c;结果创建出来却成了myisam的表。再看show variables like %innodb%;have_innodb 成了DISABLED。经过一番试验&#xff0c;发现是我关闭数据库后&#xff0c;直接删除ibdata1文件造成的。删除该…

[bzoj1059]矩阵游戏

虽然是一道水难题&#xff0c;但是我这种蒟蒻还是要讲一讲的。 Description 小Q是一个非常聪明的孩子&#xff0c;除了国际象棋&#xff0c;他还很喜欢玩一个电脑益智游戏——矩阵游戏。矩阵游戏在一个N*N黑白方阵进行&#xff08;如同国际象棋一般&#xff0c;只是颜色是随意的…

H264 RTP头分析

h264 RTP头解析流程 结合NALDecoder.c分析 协议分析 &#xff1a;每一个RTP数据报都由头部&#xff08;Header&#xff09;和负载&#xff08;Payload&#xff09;两个部分组成&#xff0c;其中头部前 12 个字节的含义是固定的&#xff0c;而负载则可以是音频或者视频数据。 一…

golang mysql 插入_Mysql学习(一)添加一个新的用户并用golang操作Mysql

Mysql添加一个新的用户并赋予权限添加一个自己的用户到mysql首先我们需要先用root用户登录mysql&#xff0c;但是刚安装完没有密码&#xff0c;我们先跳过密码ailumiyanaailumiyana:~/Git_Project/Go_Test$ sudo mysqld_safe --skip-grant-tables2019-01-07T01:35:51.559420Z m…

云计算构建基石之Hyper-V:虚拟机管理

本文讲的是云计算构建基石之Hyper-V:虚拟机管理,作为云计算的重要基石&#xff0c;虚拟化技术的好坏起着关键作用。Hyper-V作为微软重要的虚拟化解决技术&#xff0c;在微软云计算构建解决方案中&#xff0c;更是关键至关键&#xff0c;基础之基础。在本系列文章中&#xff0c;…

Delphi语言最好的JSON代码库 mORMot学习笔记1

mORMot没有控件安装&#xff0c;直接添加到lib路径,工程中直接添加syncommons&#xff0c;syndb等到uses里 --------------------------------------------------------- 在进行网络编程中需要JSON对象的构建与解析&#xff0c;这个Delphi XE自带&#xff1a;{$IF CompilerVers…

3GP文件格式分析

1. 概述现在很多智能手机都支持多媒体功能&#xff0c;特别是音频和视频播放功能&#xff0c;而3GP文件格式是手机端普遍支持的视频文件格式。目前很多手机都支持h263视频编码格式的视频文件播放&#xff0c;还有些手机支持h264。音频文件格式普遍支持amr&#xff0c;有些手…

mysql group concat_MySQL 的 GROUP_CONCAT 函数详解

GROUP_CONCAT(expr) 函数会从 expr 中连接所有非 NULL 的字符串。如果没有非 NULL 的字符串&#xff0c;那么它就会返回 NULL。语法如下&#xff1a;GROUP_CONCAT 语法规则它在递归查询中用的比较多&#xff0c;但要使用好它并不容易。所以让我们一起来看看吧&#xff1a;假设有…

ORACLE数据库 常用命令和Sql常用语句

ORACLE 账号相关 如何获取表及权限 1.COPY表空间backup scottexp登录管理员账号system2.创建用户 create user han identified(认证) by mima default tablespace users&#xff08;默认的表空间&#xff09; quota&#xff08;配额&#xff09;10M on users;创建账号分配权限g…

光荣之路测试开发面试linux考题之四:性能命令

Hi,大家好我是tom,I am back.今天要给大家讲讲linux系统一些性能相关命令。 1.fdisk 磁盘管理 是一个强大的危险命令&#xff0c;所有涉及磁盘的操作都由该命令完成&#xff0c;包括&#xff1a;新增磁盘、增删改磁盘分区等。 1.fdisk -l 查看磁盘分区情况 Disk /dev/sda: 27.8…

一起学并发编程 - 优雅关闭

Java中原来在Thread中提供了stop()方法来终止线程&#xff0c;但这个方法是不安全的&#xff0c;所以一般不建议使用。文本将介绍两种可以优雅的终止线程的方式...<!-- more --> 第一种 在JAVA《Java多线程模式》中有一种叫Two-Phase Termination&#xff08;两步终止&am…

mac安装完mysql后关机特别慢_mysql-Mac终端下遇到的问题总结

为了方便启动mysql服务&#xff0c;修改/etc/.bash_profile文件&#xff0c;如下alias mysql"/usr/local/mysql/bin/mysql"alias mysqladmin"/usr/local/mysql/bin/mysqladmin"或者alias mysqlstart"sudo /usr/local/mysql/support-files/mysql.serve…

sending data mysql slow Mysql查询非常慢的可能原因

1.用explain看看mysql的执行情况,可以得知,task_id扫描了近20万条数据,而且这个task_id不是索引 2.为这个task_id所在的表,将此字段添加索引后,查询就变得很快了 转载于:https://www.cnblogs.com/Skrillex/p/7365590.html

mybatis 添加语句返回对象_mybatis的insert语句插入数据时的返回值的实现

mybatis的insert语句插入数据时的返回值的实现,语句,返回值,那条,都是,站长站mybatis的insert语句插入数据时的返回值的实现易采站长站&#xff0c;站长之家为您整理了mybatis的insert语句插入数据时的返回值的实现的相关内容。mybatis的sql语句一般是配置在配置文件中&#xf…

打包上架

昨天写的打包上架&#xff0c;分组到了文章&#xff0c;发现不便查看贴链接到这里&#xff1a; http://www.cnblogs.com/ITCoderW/articles/7597969.html 最近一个版本的审核的过程 当我们上传到APP Store一个新的版本后 登录ITunes Connect就可以看到相应的版本的审核的状态 粗…

inet_pton函数和inet_ntop函数的用法及简单实现

http://blog.csdn.net/eagle51/article/details/53157643?utm_sourceitdadao&utm_mediumreferral 这两个函数是随IPv6出现的新函数&#xff0c;对于IPv4地址和IPv6地址都适用。函数名中的p和n非别代表表达&#xff08;presentation&#xff09;和数值&#xff08;numeric&…

mysql 5.7 延迟同步_MySQL5.6升级5.7时出现主从延迟问题排查过程

最近在做zabbix的数据库MySQL5.6升级5.7时&#xff0c;出现主从延迟问题&#xff0c;这个问题困扰了很久没有解决&#xff0c;昨天终于解决了&#xff0c;整理了一下整个排查过程&#xff0c;分享给大家。环境说明&#xff1a;mysql主库为5.6的版本&#xff0c;有四个从库&…

架构设计--仅是软件开发之第二大影响力?!

SDWest2006&#xff08;译注1&#xff09;对我来说是个有趣的大会。我除了星期三之外&#xff08;当时我正飞往费城参加一个客户会议 因此错过了Jolt颁奖部分&#xff09;每天都在演讲。我也参加了一些谈话和会议&#xff1b;其中最引人关注的是Mike Cohn的计划与估算的谈话。…