Esempio n. 1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="StartOfFrame" /> class.
 /// </summary>
 /// <param name="type">The type.</param>
 /// <param name="buffer">The buffer.</param>
 public StartOfFrame(SegmentTypes type, ByteBuffer buffer)
     : base(type, buffer)
 {
     Components = new Component[MAX_COMPONENTS];
     for (int x = 0; x < Components.Length; ++x)
     {
         Components[x] = new Component();
     }
     Progressive = type == SegmentTypes.StartOfFrame2;
 }
Esempio n. 2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="SegmentBase" /> class.
 /// </summary>
 /// <param name="type">The type.</param>
 /// <param name="bytes">The bytes.</param>
 protected SegmentBase(SegmentTypes type, ByteBuffer bytes)
 {
     Bytes    = bytes;
     Type     = type;
     TempData = new byte[2 * Block.BlockSize];
 }