Ejemplo n.º 1
0
 public GbpReader(IBinaryStream input, GbpMetaData info)
 {
     m_input = input;
     m_info  = info;
     if (32 == info.BPP)
     {
         Format = PixelFormats.Bgra32;
     }
     else
     {
         Format = PixelFormats.Bgr32;
     }
     m_output = new byte[4 * (int)m_info.Width * (int)m_info.Height];
 }
Ejemplo n.º 2
0
        public GbpReader(IBinaryStream input, GbpMetaData info)
        {
            m_input = input;
            m_info  = info;
            if (32 == info.BPP)
            {
                Format = PixelFormats.Bgra32;
            }
            else
            {
                Format = PixelFormats.Bgr32;
            }

            m_width    = (int)m_info.Width;
            m_height   = (int)m_info.Height;
            m_output   = new byte[4 * m_width * m_height];
            m_channels = m_info.BPP / 8;
            bits_pos   = new int[m_channels + 1];
            data_pos   = new int[m_channels + 1];
        }