W3Cschool
恭喜您成為首批注冊(cè)用戶(hù)
獲得88經(jīng)驗(yàn)值獎(jiǎng)勵(lì)
原型:extern int getpixel(int x, int y);
用法:#include <system.h>
功能:返回屏幕上指定點(diǎn)的狀態(tài)
說(shuō)明:(x,y)為屏幕上點(diǎn)的坐標(biāo),如果點(diǎn)為清除狀態(tài)返回零,否則返回非零值。
舉例:
// pixel.c
#include <system.h>
main()
{
int i,j;
clrscr();
printf("V");
gotoxy(10,10); // Hide cursor
for(i=0;i<8;i++)
for(j=0;j<16;j++)
{
if(getpixel(i,j))
putpixel(10+i,10+j,1);
else
putpixel(10+i,10+j,0);
}
getchar();
return 0;
}
Copyright©2021 w3cschool編程獅|閩ICP備15016281號(hào)-3|閩公網(wǎng)安備35020302033924號(hào)
違法和不良信息舉報(bào)電話(huà):173-0602-2364|舉報(bào)郵箱:jubao@eeedong.com
掃描二維碼
下載編程獅App
編程獅公眾號(hào)
聯(lián)系方式:
更多建議: