我想要在程式中播放音效,如果使用動態編譯完全沒問題 ;
但使用靜態編譯僅僅在宣告上就會出現問題 :
./release\mainwindow.o:mainwindow.cpp::-1: error: undefined reference to `_imp___ZN6Phonon11VideoPlayerC1ENS_8CategoryEP7QWidget'
本人以下都有做到 :
1. .pro 加上 QT += phonon
2. #include <phonon> 引入
3. Phonon::VideoPlayer *specialSound 也沒出現問題
但在new物件時就會出現上述問題 specialSound = new Phonon::VideoPlayer(Phonon::VideoCategory,this) ;
請問一下各位是什麼問題??