So...how do you add sound?
Say, for example, I wanted a sound to go off when I pressed one of the buttons.
Sorry if this is a "stupid question," but I'm new to QT.
Thanks.
So...how do you add sound?
Say, for example, I wanted a sound to go off when I pressed one of the buttons.
Sorry if this is a "stupid question," but I'm new to QT.
Thanks.
hi ,
you can try QSound http://doc.qt.nokia.com/4.7/qsound.html#details
hope it helps
bala
Thanks! Does QSound work for no matter which platform the program is running on?
Thanks.
There's a list of platforms and supported sound formats in the link above
Depends on the system. QSound doesn't work on Linux if you don't have NAS installed. It's not supported on cell phones.
I think your best shot is just to use Phonon.
Let me explain what I need this to do.
This is for a school project, so I need it to be EASILY run on Mac, Windows and Linux systems.
Will Phonon do the trick? Also, is it free to download? How easily does it work with Qt?
Phonon is shipped with Qt out of the box. You just have to add the flag to ./configure. It uses QuickTime on Mac, Linux GStreamer (VLC or Xine if you use the KDE version (but that requires KDE)), and on Windows DirectShow.
It might require a little more work than QSound. But it's not that hard to use.
What do you mean by "add the flag to ./configure?"
I'm REALLY sorry if these are seemingly stupid questions, but this is the first time I've EVER used Qt so if anyone could give me a step-by-step guide that'd be awesome.
hi,
refer this link for phonon http://doc.qt.nokia.com/4.7/phonon-overview.html
When running the Qt configure script, you will be notified whether Phonon support is available on your system. As mentioned previously, to use develop and run Phonon applications, you also need to link to a backend, which provides the multimedia functionality.Mac OS X
On Mac OS X, Qt uses QuickTime for its backend. The minimum supported version is 7.0.Linux
The Qt backend on Linux uses GStreamer (minimum version is 0.10), which must be installed on the system. At a minimum, you need the GStreamer libraryhope it helpsWindows
On Windows, building Phonon requires DirectX and DirectShow version 9 or higher. You'll need additional SDKs you can download from Microsoft.
bala
Bookmarks