Beispiel #1
0
        public int LastByte()
        {
            var prevPos = ContentStream.Position;

            ContentStream.Position = ContentStream.Length - 1;

            var ret = ContentStream.ReadByte();

            return(ret);
        }
Beispiel #2
0
 private static void ReadChunkHeader(ContentStream stream, ref Chunk c)
 {
     if (stream.Remaining > 0)
     {
         byte header = stream.ReadByte();
         c.Type  = (ushort)((header >> 6) & 0x03);
         c.Extra = (ushort)(header & 0x3F);
         // DO NOT CHANGE THE CHANNEL COMPONENTS
         if (c.Type == 3)
         {
             throw new InvalidDataException("Invalid RLAD header size type.");
         }
     }
 }