CSharpImageLibrary.Headers.TGA_Header.Load C# (CSharp) Method

Load() protected method

Reads the header of a TGA image.
protected Load ( Stream stream ) : long
stream Stream Fully formatted TGA image.
return long
        protected override long Load(Stream stream)
        {
            base.Load(stream);

            // Class already written. Complex and I don't want to rewrite it.
            using (BinaryReader br = new BinaryReader(stream, Encoding.Default, true))
                TargaImage.LoadTGAHeaderInfo(br, header);

            Width = header.Width;
            Height = header.Height;
            return stream.Position;
        }