Fix compilation with stock MinGW.

Use qt_windows.h, provide interfaces and UIDs missing
in stock MinGW.

Task-number: QTBUG-23829
Change-Id: I79ed902bb7636c751df7607f6059a7de237acb31
Reviewed-by: Jonathan Liu <net147@gmail.com>
Reviewed-by: Kai Koehne <kai.koehne@digia.com>
This commit is contained in:
Friedemann Kleint
2012-10-16 16:49:52 +02:00
committed by The Qt Project
parent a410276d0d
commit 40fe658dce
3 changed files with 27 additions and 8 deletions

View File

@@ -51,14 +51,37 @@
//
#include <windows.h>
#include <QtCore/qt_windows.h>
#include <mmsystem.h>
#include "qaudiodeviceinfo_win32_p.h"
#include <dshow.h>
#if defined(Q_CC_MINGW) && !defined(__MINGW64_VERSION_MAJOR)
struct IBaseFilter; // Needed for strmif.h from stock MinGW.
struct _DDPIXELFORMAT;
typedef struct _DDPIXELFORMAT* LPDDPIXELFORMAT;
#endif
#include <strmif.h>
#if !defined(Q_CC_MINGW) || defined(__MINGW64_VERSION_MAJOR)
# include <uuids.h>
#else
extern GUID CLSID_AudioInputDeviceCategory;
extern GUID CLSID_AudioRendererCategory;
extern GUID IID_ICreateDevEnum;
extern GUID CLSID_SystemDeviceEnum;
#ifndef __ICreateDevEnum_INTERFACE_DEFINED__
#define __ICreateDevEnum_INTERFACE_DEFINED__
DECLARE_INTERFACE_(ICreateDevEnum, IUnknown)
{
STDMETHOD(CreateClassEnumerator)(REFCLSID clsidDeviceClass,
IEnumMoniker **ppEnumMoniker,
DWORD dwFlags) PURE;
};
#endif // __ICreateDevEnum_INTERFACE_DEFINED__
#ifndef __IErrorLog_INTERFACE_DEFINED__
#define __IErrorLog_INTERFACE_DEFINED__

View File

@@ -53,9 +53,7 @@
#ifndef QAUDIOINPUTWIN_H
#define QAUDIOINPUTWIN_H
#define NOMINMAX
#include <windows.h>
#include <QtCore/qt_windows.h>
#include <mmsystem.h>
#include <QtCore/qfile.h>

View File

@@ -53,9 +53,7 @@
#ifndef QAUDIOOUTPUTWIN_H
#define QAUDIOOUTPUTWIN_H
#define NOMINMAX
#include <windows.h>
#include <QtCore/qt_windows.h>
#include <mmsystem.h>
#include <QtCore/qdebug.h>