2018年6月4日 星期一

Week 15 ADDONE notes

主題: 學期內容回顧

glutSolidSphere(1,slices,stacks);
SolidSphere實心圓
(1,slices,stacks) : (半徑,切,切)

glutSolidCone(1,1,slices,stacks); 錐體
glutSolidTorus(0.2,0.8,slices,stacks);甜甜圈形

glutWireSphere(1,slices,stacks);空心圓

貼圖



音樂播放
void mouse (int button,int state, int x,int y);
{
     if(state==GLUT_DOWN) PlaySound("Shot.wav",NULL, SND_ASYNC);
}
//按滑鼠就會播聲音

音樂檔要放入 freeglut的bin裡面
moodle下載 CMP3_MCI.h 放在自己建立的coldblock檔裡就可以播MP3

myMP3.Load("123.mp3");
myMP3.play();

沒有留言:

張貼留言