View Full Version : How to make QtMultimedia work on Windows using MSVC

2nd May 2013, 17:57

I have been using QtMultimedia perfectly fine when I downloaded the minGW version of Qt5 on windows, but I had to switch and use the MSVC version and now I cannot make QtMultimedia to work.

I have added QT += multimedia to my .pro file and at least auto-completion works when I type #include <someMULTIMEDIA class>

Is there something that I am missing ? Is it “normal” that it doesn’t work now that I am using MSVC as a compiler.

Any help greatly appreciated.

2nd May 2013, 19:49
I have added QT += multimedia to my .pro file and at least auto-completion works
So what exactly "doesn't work" then?

2nd May 2013, 21:05
Well, it doesn't compile actually, I get the error:
C:\Qt\dev\Projects\TestDev\mainwindow.cpp:3: error: C1083: Cannot open include file: ‘QAudioInput’: No such file or directory

This was not happening when I was using the minGW version of Qt..

2nd May 2013, 21:43
"It" meaning your project? Do you have a QAudioInput file installed? Where does it reside relative to your Qt installation directory?

3rd May 2013, 14:49
Yes, the project won't compile.

I have my directory like this:


In there I have all the header files that I need, QAudioInput, QAudioFormat, etc..

And in :

I have the installed libraries of the whole framework.

3rd May 2013, 19:45
Apparently you haven't told MSVC where to find the QtMultimedia directory.

After modifying your .pro file, did you re-create the MSVC .vcproj file from it? (Using the Qt add-in for MSVC?) This should add the QtMultimedia directory to the set of locations to look for header files.

Otherwise, you can simply #include each required header as

#include <QtMultimedia/QAudioInput>