第1部份
3D Exploration 安裝
匯入Gundan.obj
Save as成Sample APP
開啟OpenGl專案 把.cpp跟.bmp檔放在專案目錄
remove原本main.c程式
Add file .cpp
增加
#define GL_BGR_EXT 0x80E0
#define GL_BGRA_EXT 0x80E1
註解掉
(LPLOGPALETTE) lpPalette = (LPLOGPALETTE)HeapAlloc (hHeap, 0,
sizeof (LOGPALETTE) + (nColors * sizeof (PALETTEENTRY)));
註解掉
glRotatef (30.0f, 1.0f, 0.0f, 0.0f);
glRotatef ((GLfloat) nAngle, 0.0f, 1.0f, 0.0f);
glRotatef ((GLfloat) nAngle2, 1.0f, 0.0f, 0.0f);
glScalef (nSize+2.5f,nSize+2.5f,nSize+2.5f);
增加
glRotatef(nAngle,0,1,0);
glScalef(3,3,3);
執行結果
-----------------------------------------------------------------------------------------------------------------------------
第0部份
執行結果
-----------------------------------------------------------------------------------------------------------------------------
第0部份
執行結果
-----------------------------------------------------------------------------------------------------------------------------






沒有留言:
張貼留言