Previous 199869 Revisions Next

r29289 Saturday 5th April, 2014 at 06:32:27 UTC by hap
rm unused colortable
[src/osd/windows]drawgdi.c

trunk/src/osd/windows/drawgdi.c
r29288r29289
2727struct gdi_info
2828{
2929   BITMAPINFO              bminfo;
30   RGBQUAD                 colors[256];
3130   UINT8 *                 bmdata;
3231   size_t                  bmsize;
3332};
r29288r29289
8887   // fill in the bitmap info header
8988   gdi->bminfo.bmiHeader.biSize            = sizeof(gdi->bminfo.bmiHeader);
9089   gdi->bminfo.bmiHeader.biPlanes          = 1;
90   gdi->bminfo.bmiHeader.biBitCount        = 32;
9191   gdi->bminfo.bmiHeader.biCompression     = BI_RGB;
9292   gdi->bminfo.bmiHeader.biSizeImage       = 0;
9393   gdi->bminfo.bmiHeader.biXPelsPerMeter   = 0;
r29288r29289
9595   gdi->bminfo.bmiHeader.biClrUsed         = 0;
9696   gdi->bminfo.bmiHeader.biClrImportant    = 0;
9797
98   // initialize the palette to a gray ramp
99   for (int i = 0; i < 256; i++)
100   {
101      gdi->colors[i].rgbRed               = i;
102      gdi->colors[i].rgbGreen             = i;
103      gdi->colors[i].rgbBlue              = i;
104      gdi->colors[i].rgbReserved          = i;
105   }
106
10798   return 0;
10899}
109100
r29288r29289
182173   // fill in bitmap-specific info
183174   gdi->bminfo.bmiHeader.biWidth = pitch;
184175   gdi->bminfo.bmiHeader.biHeight = -height;
185   gdi->bminfo.bmiHeader.biBitCount = 32;
186176
187177   // blit to the screen
188178   StretchDIBits(dc, 0, 0, width, height,

Previous 199869 Revisions Next


© 1997-2024 The MAME Team