2018年5月18日 星期五

week12 葉子瑄

1.播放mp3檔
2加入timer讓音樂過五秒鐘之後再播放
#include <windows.h>
#include<mmsystem.h>
void timer(int t)
{
    glutTimerFunc(1000,timer,t+1);///等多久,呼叫誰,參數
    PlaySound("Do.wav",NULL,SND_ASYNC);
}

glutTimerFunc(5000,timer,0);有個計時器函數 timer
3.加入printf()輸出時間




沒有留言:

張貼留言