2022年3月1日 星期二

電腦圖學筆記 week02

 WEEK02

1.下載範例  https://jsyeh.org/3dcg10 

data.zip         window.zip       glut32.dll    











2.Window zip 解壓 下載\window\Shapes.exe
          data.zip 解壓 下載\windows\data\模型
       glut32.dll 複製 下載\windows\glut32.dll























3.跑Shepes.exe
    左可按右鍵選單:大頂點 很多顏色
        右可按右鍵選單:POINT POLYGON



















茶壺
1.開新的project






#include <GL/glut.h>

void display()
{
    glClear( GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);

    glColor3f(1,1,0);
    glutSolidTeapot(0.3);

    glutSwapBuffers();
}

int main (int argc, char** argv)
{
    glutInit( &argc, argv);
    glutInitDisplayMode(GLUT_DOUBLE | GLUT_DEPTH);
    glutCreateWindow("第02周的程式喔!");

    glutDisplayFunc(display);

    glutMainLoop();
}












沒有留言:

張貼留言

VERY BEAUTIFUL, VERY POWERFUL

一.     一樣先安裝且設定好freeglut,OpecCV, 開啟CodeBlocks建立新專案 week11_gundam,                 把 MyGundam.zip下載解壓縮後的data資料夾放到freeglut/bin裡面 把week09_openc...