Beispiel #1
0
 public PdtReader(IBinaryStream input, PdtMetaData info)
 {
     m_input  = input;
     m_info   = info;
     m_output = new byte[m_info.Width * m_info.Height * 4];
     if (0 == m_info.AlphaOffset)
     {
         Format = PixelFormats.Bgr32;
     }
     else
     {
         Format = PixelFormats.Bgra32;
     }
 }
Beispiel #2
0
        public PdtReader(IBinaryStream input, PdtMetaData info)
        {
            m_input = input;
            m_info  = info;
            if (0 != m_info.AlphaOffset)
            {
                Format = PixelFormats.Bgra32;
            }
            else if (1 == m_info.Version)
            {
                Format = PixelFormats.Indexed8;
            }
            else
            {
                Format = PixelFormats.Bgr32;
            }

            m_output = new byte[m_info.Width * m_info.Height * Format.BitsPerPixel / 8];
        }
Beispiel #3
0
 public PdtReader(Stream input, PdtMetaData info)
 {
     m_input = new ArcView.Reader (input);
     m_info = info;
     m_output = new byte[m_info.Width * m_info.Height * 4];
     if (0 == m_info.AlphaOffset)
         Format = PixelFormats.Bgr32;
     else
         Format = PixelFormats.Bgra32;
 }