outtextxy(0,10,"This clock is written by lijun"); /*?show the auther */ coss=(int)((r-10)*cos(t.ti_sec*3.14f/30-3.14f/2)+x);
sins=(int)((r-10)*sin(t.ti_sec*3.14f/30-3.14f/2)+y);
cosm=(int)((r-19)*cos(t.ti_min*3.14f/30-3.14f/2)+x);
sinm=(int)((r-19)*sin(t.ti_min*3.14f/30-3.14f/2)+y);
cosh=(int)((r-28)*cos((t.ti_hour+(float)(t.ti_min)/60)*3.14f/6-3.14f/2)+x); sinh=(int)((r-28)*sin((t.ti_hour+(float)(t.ti_min)/60)*3.14f/6-3.14f/2)+y); /* calculate the position of the three points */
setcolor(14);
line(x,y,coss,sins);
setcolor(13);
line(x,y,cosm,sinm);
setcolor(10);
line(x,y,cosh,sinh);
setcolor(15);
/* draw the points */
sleep(1);
百度搜索“77cn”或“免费范文网”即可找到本站免费阅读全部范文。收藏本站方便下次阅读,免费范文网,提供经典小说教育文库计算机等考二级C语言学习要领(5)在线全文阅读。
相关推荐: