C4996 'getch': The POSIX name for this item is deprecated. Instead, use the ISO C and C++ conformant name: _getch.


#include <graphics.h>        //引用圖形庫
#include <conio.h>
void main()
{
    initgraph(640, 480);    //和TC有區別
    circle(200, 200, 100);    //畫圓, 圓心(200,200),半徑 100
    getch();                //按任意鍵繼續
    closegraph();            //關閉圖形界面
}

方法1:

  將 getch 改成 _getch  即可編譯通過

 

方法2:

屬性頁 -> C/C++ -> 常規 里   SDL檢查  改成否 即可編譯通過

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM