1.貼圖座標
下載上課用軟體OpenCV
安裝上小心要設定(Add Path)
path 會設好
2.第一個 OpenCV的程式
設定很複雜
Setting-Compiler Setting 的三個地方
Search->Compiler Add C:\OpenCV2.1\include
Search -> Linker Add C:\OpenCV2.1\lib
Linker setting add :cv210 cxcore210 highgui210
2.1寫程式
先做茶壺的程式碼
利用opencv加入圖片讀取
注意圖片要加到Desktop\freeglut-MinGW-3.0.0-1.mp\freeglut\bin裡面,因為是在這裏面執行的
第15行cvShowImage("img", img);雙引號中是視窗名字
加入新的 texturem用老師的程式碼
記得在()裡加"檔名"=>myTexture("earth.jpg");
沒有留言:
張貼留言