Source/NFX/IOMiscUtils.cs
/// <summary>
/// Reads a short encoded as little endian from buffer at the specified index
/// </summary>
Reads a short encoded as little endian from buffer at the specified index
Reads a short encoded as little endian from buffer at the specified index
public static short ReadLEShort(this byte[] buf, ref int idx)
        {
            return (short)(
                         (((int)buf[idx++]      ) & 0xff) +
                         (((int)buf[idx++] << 8 ) & 0xff00)
                        );
        }
public static short ReadLEShort ( this byte [ ] buf , ref int idx ) { return ( short ) ( ( ( ( int ) buf [ idx ++ ] ) & 0xff ) + ( ( ( int ) buf [ idx ++ ] << 8 ) & 0xff00 ) ) ; }
Reads a short encoded as little endian from buffer at the specified index
Reads a short encoded as little endian from buffer at the specified index
byte[]
this
int
ref