|
楼主 |
发表于 2007-6-15 17:58:03
|
显示全部楼层
是啊,每一行偏移了一个像素点。
可是我在MMI里面找不着确切的地方。
LcdDrv.c我看了,比如
void LCDrBlockWrite(uint16 x1,uint16 y1,uint16 x2,uint16 y2)
{
uint16 LCDrx;
uint16 LCDry;
LCDrSetPageAddr((uint8)y1, (uint8)y2); // Page Address
LCDrSetColAddr((uint8)x1, (uint8)x2); // Column Address
LCDrWrStart(); // Write Command
for(LCDry=y1;LCDry<=y2;LCDry++) // Filling the LCD RAM
for(LCDrx=x1;LCDrx<=x2;LCDrx++)
{
LCDrRAMWrite(gShadowBuffer[LCDry][LCDrx]);
}
}
MainLcd.c我也看了,比如
void update_screen()
{
hdc = GetDC(hWnd);
hdcMem = CreateCompatibleDC(hdc);
hbmp = CreateCompatibleBitmap(hdc, LCD_WIDTH, LCD_HEIGHT);
SelectObject(hdcMem, hbmp);
if (simulator_frame_buffer != NULL)
{
SetDIBits(NULL, hbmp, 0, LCD_HEIGHT, simulator_frame_buffer, &bitmap_info, DIB_RGB_COLORS);
}
BitBlt( hdc,
SIMULATOR_SKIN_LCD_X,
SIMULATOR_SKIN_LCD_Y,
SIMULATOR_SKIN_LCD_X + LCD_WIDTH - 1,
SIMULATOR_SKIN_LCD_Y + LCD_HEIGHT - 1,
hdcMem, 0, 0, SRCCOPY);
ReleaseDC(hWnd, hdc);
DeleteDC(hdcMem);
DeleteObject(hbmp);
}
可是这里都是正确的,改不出来。
再麻烦大家给点思路,谢谢! |
|