Пример #1
0
        /// <summary>
        /// Read a 24bit value based on the current stream and bit position
        /// </summary>
        public Int24 ReadInt24()
        {
            byte[] bytes = ReadBytes(24);
            Array.Resize(ref bytes, 4);
            Int24 value = BitConverter.ToInt32(bytes, 0);

            return(value);
        }
Пример #2
0
 /// <summary>
 /// Write a 24bit value based on the current stream and bit position
 /// </summary>
 public void WriteInt24(Int24 value)
 {
     WriteBytes(BitConverter.GetBytes((int)value), 24);
 }