void LY_LCD_ShowMan2(u16 x,u16 y,u8 num,u8 mode)
{
u16 temp,t1,t;
u16 y0=y;
u16 colortemp=POINT_COLOR;
//设置窗口
if(!mode) //非叠加方式
{
for(t=0;t<32*4;t++)
{
temp=asc2_3232[num][t]; //调用1206字体
for(t1=0;t1<8;t1++)
{
if(temp&0x80)POINT_COLOR=colortemp;
else POINT_COLOR=BACK_COLOR;
LCD_DrawPoint(y,x);
temp<<=1;
y++;
if(x>=lcddev.width){POINT_COLOR=colortemp;return;}//超区域了
if((y-y0)==32)
{
y=y0;
x++;
if(x>=lcddev.width){POINT_COLOR=colortemp;return;}//超区域了
break;
}
}
}
}else//叠加方式
{
for(t=0;t<32*4;t++)
{
temp=asc2_3232[num][t];
for(t1=0;t1<8;t1++)
{
if(temp&0x80)LCD_DrawPoint(x,y);
temp<<=1;
y++;
if(x>=lcddev.height){POINT_COLOR=colortemp;return;}//超区域了
if((y-y0)==32)
{
y=y0;
x++;
if(x>=lcddev.width){POINT_COLOR=colortemp;return;}//超区域了
break;
}
}
}
}
POINT_COLOR=colortemp;
}
这是显示程序
LY_LCD_ShowMan2(50,25,5,0);
LY_LCD_ShowMan2(100,50,6,0);
LY_LCD_ShowMan2(150,75,7,0);
LY_LCD_ShowMan2(200,100,8,0);
LY_LCD_ShowMan2(250,125,9,0);
LY_LCD_ShowMan2(300,150,10,0);
前四个都可以正常显示,后两个就没了,而且别的颜色填充也在差不多X=250后的区域不能用了,求解啊
|