How to play sound in Qt5 (Qt4 migration)?
问题 In Qt4 I used to use QT += multimedia phonon //... #include <Phonon> //... Phonon::MediaObject *mediaObject = Phonon::createPlayer(Phonon::NoCategory, Phonon::MediaSource(QUrl("./assets/audio/window_appear.wav"))); // "\"" + Qdir().absolutePath() + "/audio/click.wav" + "\"" mediaObject->play(); and it all worked fine. But now Phonon is not supported in Qt 5. So I wonder - how can I play media files such as sound in Qt5? Using WebKit? (It is entirely possible but looks kind of bad from many