2022年4月18日 星期一

廷Week09

1. 下載範例

    1.1 到 https://jsyeh.org/3dcg10/ 下載 [source] [data] [win32]



    1.2 打開 Texture.exe檔案




    1.3 glTexCoord2f 的使用方法


2. OpenCV (2.1.0版本)

    2.1 到moodle下載



    2.2 PATH設定在 Add PATH  (以後才可以成功使用到 
C:\OpenCV2.1\bin 裡面的dll檔)


    2.3 一定要預設安裝在 C:\OpenCV2.1


  3. 實作
    3.1 重開 Code::Blocks  開啟一個 EmptyFile


    3.2 存成 week09_opencv.cpp


    3.3 打上程式碼


    3.4 開始設定   Setting -> Compiler 裡 3個地方

        3.4.1 Setting-Compiler -> Search directories -> Compiler -> Add -> C:\OpenCV2.1\include


        3.4.2  Setting-Compiler -> Search directories -> Linker -> Add -> C:\OpenCV2.1\lib


        3.4.3  Setting-Compiler -> Linker setting -> Add -> cv210 cxcore210 highgui210

    
    3.5 執行跑圖片



4. 專案
    4.1 開一個GLUT新專案 名稱week09_texture


    4.2 固定的10行程式碼

    
    4.3  加上貼圖檔的程式碼


   
    4.4  圖檔要放在 freeglut 的 bin 裡面

    
    4.5 貼上老師給的程式碼










   
    


沒有留言:

張貼留言