graphics问题
想问下char savepattern[8];是什么意思?好像程序中没有用到。。隐含什么意义?代码:
#include <graphics.h>
main()
{
int graphdriver=VGA,graphmode=VGAHI;
struct fillsettingstype save;
char savepattern[8];
int d[]={420,20,330,45,330,145,420,120,510,145,510,55,420,20};
initgraph(&graphdriver,&graphmode,"");
getfillsettings(&save);
setfillstyle(3,BLUE);
bar3d(100,50,150,120,30,1);
setfillstyle(HATCH_FILL,RED);
bar3d(200,50,250,120,30,0);
setfillstyle(1,GREEN);
sector(200,300,0,250,100,40);
setfillstyle(1,LIGHTRED);
fillellipse(420,300,100,40);
fillellipse(420,300,100,40);
setfillstyle(1,5);
fillpoly(7,d);
getch();
setfillstyle(save.pattern,save.color);
closegraph();
}