コード例 #1
0
 public void ToBuffer(ref FMp4MessagePackWriter writer)
 {
     Start(ref writer);
     if (TrackFragmentRandomAccessBox != null)
     {
         TrackFragmentRandomAccessBox.ToBuffer(ref writer);
     }
     if (MovieFragmentRandomAccessOffsetBox != null)
     {
         MovieFragmentRandomAccessOffsetBox.ToBuffer(ref writer);
     }
     End(ref writer);
 }
コード例 #2
0
        public void ToBuffer(ref FMp4MessagePackWriter writer)
        {
            Start(ref writer);
            if (TrackFragmentRandomAccessBox != null)
            {
                TrackFragmentRandomAccessBox.ToBuffer(ref writer);
            }
            if (MovieFragmentRandomAccessOffsetBox != null)
            {
                MovieFragmentRandomAccessOffsetBox.ToBuffer(ref writer);
            }
            End(ref writer);
            var mfraSizePosition = writer.GetMfraSizePosition();

            if (mfraSizePosition > 0)
            {
                writer.WriteInt32Return(writer.GetCurrentPosition() - SizePosition, mfraSizePosition);
                writer.ClearMfraSizePosition();
            }
        }