Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mpc-hc/mpc-hc.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorXhmikosR <xhmikosr@gmail.com>2017-08-03 10:42:05 +0300
committerKacper Michajłow <kasper93@gmail.com>2017-08-14 00:00:41 +0300
commit82adfbdb6af6c4c0fb7cccf4f9afba511ce862e2 (patch)
tree69ad00ea5abf228d242e71710287d718e6b3e08f
parent1fda105e3b9e5e6c8d2e5254701a8b3761f335ff (diff)
Update to astyle 3.0.1.
-rw-r--r--contrib/pre-commit.sh4
-rwxr-xr-xcontrib/run_astyle.bat14
-rw-r--r--include/IBitRateInfo.h7
-rw-r--r--include/IBufferInfo.h7
-rw-r--r--include/IChapterInfo.h9
-rw-r--r--include/IFilterVersion.h7
-rw-r--r--include/IKeyFrameInfo.h11
-rw-r--r--include/IMPCVideoDecFilter.h12
-rw-r--r--include/ITrackInfo.h9
-rw-r--r--include/moreuuids.h6
-rw-r--r--src/DSUtil/DSMPropertyBag.h29
-rw-r--r--src/SubPic/XySubPicProvider.h11
-rw-r--r--src/Subtitles/STS.cpp2
-rw-r--r--src/Subtitles/VobSubFile.cpp2
-rw-r--r--src/Subtitles/VobSubFileRipper.cpp2
-rw-r--r--src/Subtitles/VobSubFileRipper.h18
-rw-r--r--src/filters/InternalPropertyPage.h9
-rw-r--r--src/filters/muxer/BaseMuxer/BaseMuxerRelatedPin.h9
-rw-r--r--src/filters/muxer/BaseMuxer/BitStream.h7
-rw-r--r--src/filters/muxer/MatroskaMuxer/MatroskaMuxer.h7
-rw-r--r--src/filters/parser/BaseSplitter/AsyncReader.h14
-rw-r--r--src/filters/renderer/VideoRenderers/AllocatorCommon.h7
-rw-r--r--src/filters/renderer/VideoRenderers/IPinHook.cpp103
-rw-r--r--src/filters/renderer/VideoRenderers/IPinHook.h11
-rw-r--r--src/filters/renderer/VideoRenderers/IQTVideoSurface.h11
-rw-r--r--src/filters/renderer/VideoRenderers/PixelShaderCompiler.cpp2
-rw-r--r--src/filters/renderer/VideoRenderers/SyncAllocatorPresenter.h9
-rw-r--r--src/filters/renderer/VideoRenderers/SyncRenderer.cpp2
-rw-r--r--src/filters/switcher/AudioSwitcher/AudioSwitcher.h15
-rw-r--r--src/filters/switcher/AudioSwitcher/StreamSwitcher.h7
-rw-r--r--src/filters/transform/BufferFilter/BufferFilter.h7
-rw-r--r--src/filters/transform/VSFilter/DirectVobSubFilter.cpp2
-rw-r--r--src/filters/transform/VSFilter/IDirectVobSub.h73
-rw-r--r--src/mpc-hc/BaseGraph.h7
-rw-r--r--src/mpc-hc/ComPropertySheet.h5
-rw-r--r--src/mpc-hc/FGFilter.cpp9
-rw-r--r--src/mpc-hc/IGraphBuilder2.h33
-rw-r--r--src/mpc-hc/OpenFileDlg.cpp4
-rw-r--r--src/mpc-hc/PPageAdvanced.cpp4
-rw-r--r--src/mpc-hc/SubtitleDlDlg.cpp2
-rw-r--r--src/mpc-hc/mplayerc.cpp2
41 files changed, 276 insertions, 235 deletions
diff --git a/contrib/pre-commit.sh b/contrib/pre-commit.sh
index 3236810f6..6bdba7217 100644
--- a/contrib/pre-commit.sh
+++ b/contrib/pre-commit.sh
@@ -1,5 +1,5 @@
#!/bin/bash
-# (C) 2013-2015 see Authors.txt
+# (C) 2013-2015, 2017 see Authors.txt
#
# This file is part of MPC-HC.
#
@@ -39,7 +39,7 @@ versioncheck_version=6
versioncheck_path=contrib/pre-commit.sh
astyle_config=contrib/astyle.ini
astyle_extensions=(cpp h)
-astyle_version='Artistic Style Version 2.05.1'
+astyle_version='Artistic Style Version 3.0.1'
checkyear_extensions=(bat cpp h hlsl iss po py sh)
checkyear_pattern1='\(C\) (([0-9][0-9][0-9][0-9]-)?[0-9][0-9][0-9][0-9](, )?)+ see Authors.txt'
year=$(date +%Y)
diff --git a/contrib/run_astyle.bat b/contrib/run_astyle.bat
index 08e4b05d5..f36e24cd6 100755
--- a/contrib/run_astyle.bat
+++ b/contrib/run_astyle.bat
@@ -1,5 +1,5 @@
@ECHO OFF
-REM (C) 2012-2016 see Authors.txt
+REM (C) 2012-2017 see Authors.txt
REM
REM This file is part of MPC-HC.
REM
@@ -21,8 +21,8 @@ SETLOCAL
SET "FILE_DIR=%~dp0"
PUSHD "%FILE_DIR%"
-SET "AStyleVerReq=2.05.1"
-astyle --version 2>NUL || (ECHO. & ECHO ERROR: AStyle not found & GOTO End)
+SET "AStyleVerReq=3.0.1"
+astyle --ascii --version 2>NUL || (ECHO. & ECHO ERROR: AStyle not found & GOTO End)
CALL :SubCheckVer || GOTO End
@@ -30,10 +30,10 @@ CALL :SubCheckVer || GOTO End
TITLE Running astyle using %FILE_DIR%astyle.ini
IF "%~1" == "" (
- astyle -r --options=astyle.ini ..\*.cpp
- astyle -r --options=astyle.ini --keep-one-line-blocks ..\*.h
+ astyle --ascii -r --options=astyle.ini ..\*.cpp
+ astyle --ascii -r --options=astyle.ini --keep-one-line-blocks ..\*.h
) ELSE (
- FOR %%G IN (%*) DO astyle --options=astyle.ini %%G
+ FOR %%G IN (%*) DO astyle --ascii --options=astyle.ini %%G
)
IF %ERRORLEVEL% NEQ 0 ECHO. & ECHO ERROR: Something went wrong!
@@ -49,7 +49,7 @@ EXIT /B
:SubCheckVer
TITLE Checking astyle version
-FOR /F "tokens=4 delims= " %%A IN ('astyle --version 2^>^&1 NUL') DO (
+FOR /F "tokens=4 delims= " %%A IN ('astyle --ascii --version 2^>^&1 NUL') DO (
SET "AStyleVer=%%A"
)
diff --git a/include/IBitRateInfo.h b/include/IBitRateInfo.h
index b9375efb4..b25938389 100644
--- a/include/IBitRateInfo.h
+++ b/include/IBitRateInfo.h
@@ -1,6 +1,6 @@
/*
* (C) 2003-2006 Gabest
- * (C) 2006-2013 see Authors.txt
+ * (C) 2006-2013, 2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -22,8 +22,9 @@
#pragma once
interface __declspec(uuid("EB2CD9E6-BA08-4acb-AA0F-3D8D0DD521CA"))
-IBitRateInfo :
-public IUnknown {
+ IBitRateInfo :
+ public IUnknown
+{
STDMETHOD_(DWORD, GetCurrentBitRate)() PURE;
STDMETHOD_(DWORD, GetAverageBitRate)() PURE;
};
diff --git a/include/IBufferInfo.h b/include/IBufferInfo.h
index 9b5c10a1b..ca6133b12 100644
--- a/include/IBufferInfo.h
+++ b/include/IBufferInfo.h
@@ -1,6 +1,6 @@
/*
* (C) 2003-2006 Gabest
- * (C) 2006-2013 see Authors.txt
+ * (C) 2006-2013, 2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -22,8 +22,9 @@
#pragma once
interface __declspec(uuid("46070104-1318-4A82-8822-E99AB7CD15C1"))
-IBufferInfo :
-public IUnknown {
+ IBufferInfo :
+ public IUnknown
+{
STDMETHOD_(int, GetCount()) = 0;
STDMETHOD(GetStatus(int i, int& samples, int& size)) = 0;
STDMETHOD_(DWORD, GetPriority()) = 0;
diff --git a/include/IChapterInfo.h b/include/IChapterInfo.h
index 58404bfc2..dac4d58a9 100644
--- a/include/IChapterInfo.h
+++ b/include/IChapterInfo.h
@@ -1,6 +1,6 @@
/*
* (C) 2003-2006 Gabest
- * (C) 2006-2013 see Authors.txt
+ * (C) 2006-2013, 2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -44,8 +44,9 @@ struct ChapterElement {
#pragma pack(pop)
interface __declspec(uuid("8E128709-3DC8-4e49-B632-380FCF496B6D"))
-IChapterInfo :
-public IUnknown {
+ IChapterInfo :
+ public IUnknown
+{
#define CHAPTER_BAD_ID 0xFFFFFFFF
#define CHAPTER_ROOT_ID 0
@@ -57,7 +58,7 @@ public IUnknown {
STDMETHOD_(UINT, GetChapterCurrentId)() = 0;
- STDMETHOD_(BOOL, GetChapterInfo)(UINT aChapterID, struct ChapterElement * pStructureToFill) = 0;
+ STDMETHOD_(BOOL, GetChapterInfo)(UINT aChapterID, struct ChapterElement* pStructureToFill) = 0;
// \param PreferredLanguage Language code as in ISO-639-2 (3 chars)
// \param CountryCode Country code as in internet domains
diff --git a/include/IFilterVersion.h b/include/IFilterVersion.h
index 43818290b..0f7d44bf1 100644
--- a/include/IFilterVersion.h
+++ b/include/IFilterVersion.h
@@ -1,6 +1,6 @@
/*
* (C) 2003-2006 Gabest
- * (C) 2006-2012 see Authors.txt
+ * (C) 2006-2012, 2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -22,7 +22,8 @@
#pragma once
interface __declspec(uuid("A0DD28E1-61C0-4539-A7E6-14544AFF092E"))
-IFilterVersion :
-public IUnknown {
+ IFilterVersion :
+ public IUnknown
+{
STDMETHOD_(DWORD, GetFilterVersion)() = 0;
};
diff --git a/include/IKeyFrameInfo.h b/include/IKeyFrameInfo.h
index 96954df88..4bb611682 100644
--- a/include/IKeyFrameInfo.h
+++ b/include/IKeyFrameInfo.h
@@ -1,6 +1,6 @@
/*
* (C) 2003-2006 Gabest
- * (C) 2006-2012 see Authors.txt
+ * (C) 2006-2012, 2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -22,8 +22,9 @@
#pragma once
interface __declspec(uuid("01A5BBD3-FE71-487C-A2EC-F585918A8724"))
-IKeyFrameInfo :
-public IUnknown {
- STDMETHOD(GetKeyFrameCount)(UINT & nKFs) = 0; // returns S_FALSE when every frame is a keyframe
- STDMETHOD(GetKeyFrames)(const GUID * pFormat, REFERENCE_TIME * pKFs, UINT& nKFs /* in, out*/) = 0;
+ IKeyFrameInfo :
+ public IUnknown
+{
+ STDMETHOD(GetKeyFrameCount)(UINT& nKFs) = 0; // returns S_FALSE when every frame is a keyframe
+ STDMETHOD(GetKeyFrames)(const GUID* pFormat, REFERENCE_TIME* pKFs, UINT& nKFs /* in, out*/) = 0;
};
diff --git a/include/IMPCVideoDecFilter.h b/include/IMPCVideoDecFilter.h
index 1e9268ac7..a7c224933 100644
--- a/include/IMPCVideoDecFilter.h
+++ b/include/IMPCVideoDecFilter.h
@@ -1,5 +1,5 @@
/*
- * (C) 2006-2013 see Authors.txt
+ * (C) 2006-2013, 2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -53,8 +53,9 @@ enum MPCVD_INTERLACED_FLAG {
};
interface __declspec(uuid("CDC3B5B3-A8B0-4c70-A805-9FC80CDEF262"))
-IMPCVideoDecFilter :
-public IUnknown {
+ IMPCVideoDecFilter :
+ public IUnknown
+{
STDMETHOD(Apply()) PURE;
STDMETHOD(SetThreadNumber(int nValue)) PURE;
@@ -81,8 +82,9 @@ public IUnknown {
};
interface __declspec(uuid("F0ABC515-19ED-4D65-9D5F-59E36AE7F2AF"))
-IMPCVideoDecFilter2 :
-public IMPCVideoDecFilter {
+ IMPCVideoDecFilter2 :
+ public IMPCVideoDecFilter
+{
STDMETHOD_(int, GetFrameType()) PURE;
STDMETHOD(SetInterlacedFlag(MPCVD_INTERLACED_FLAG interlacedFlag)) PURE;
diff --git a/include/ITrackInfo.h b/include/ITrackInfo.h
index 137c3026a..2795a36e3 100644
--- a/include/ITrackInfo.h
+++ b/include/ITrackInfo.h
@@ -1,6 +1,6 @@
/*
* (C) 2003-2006 Gabest
- * (C) 2006-2013 see Authors.txt
+ * (C) 2006-2013, 2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -65,12 +65,13 @@ struct TrackExtendedInfoAudio {
#pragma pack(pop)
interface __declspec(uuid("03E98D51-DDE7-43aa-B70C-42EF84A3A23D"))
-ITrackInfo :
-public IUnknown {
+ ITrackInfo :
+ public IUnknown
+{
STDMETHOD_(UINT, GetTrackCount)() = 0;
// \param aTrackIdx the track index (from 0 to GetTrackCount()-1)
- STDMETHOD_(BOOL, GetTrackInfo)(UINT aTrackIdx, struct TrackElement * pStructureToFill) = 0;
+ STDMETHOD_(BOOL, GetTrackInfo)(UINT aTrackIdx, struct TrackElement* pStructureToFill) = 0;
// Get an extended information struct relative to the track type
STDMETHOD_(BOOL, GetTrackExtendedInfo)(UINT aTrackIdx, void* pStructureToFill) = 0;
diff --git a/include/moreuuids.h b/include/moreuuids.h
index 92e148765..2ddb65784 100644
--- a/include/moreuuids.h
+++ b/include/moreuuids.h
@@ -1,6 +1,6 @@
/*
* (C) 2003-2006 Gabest
- * (C) 2006-2016 see Authors.txt
+ * (C) 2006-2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -92,11 +92,11 @@ DEFINE_GUID(MEDIASUBTYPE_SAMR,
0x726D6173, 0x000, 0x0010, 0x80, 0x00, 0x00, 0xaa, 0x00, 0x38, 0x9b, 0x71);
// {30385056-0000-0010-8000-00AA00389B71}
-DEFINE_GUID(MEDIASUBTYPE_VP80 ,
+DEFINE_GUID(MEDIASUBTYPE_VP80,
0x30385056, 0x0000, 0x0010, 0x80, 0x00, 0x00, 0xaa, 0x00, 0x38, 0x9b, 0x71);
// {30395056-0000-0010-8000-00AA00389B71}
-DEFINE_GUID(MEDIASUBTYPE_VP90 ,
+DEFINE_GUID(MEDIASUBTYPE_VP90,
0x30395056, 0x0000, 0x0010, 0x80, 0x00, 0x00, 0xaa, 0x00, 0x38, 0x9b, 0x71);
DEFINE_GUID(MEDIASUBTYPE_IMA4,
diff --git a/src/DSUtil/DSMPropertyBag.h b/src/DSUtil/DSMPropertyBag.h
index dae83829e..2ec783eeb 100644
--- a/src/DSUtil/DSMPropertyBag.h
+++ b/src/DSUtil/DSMPropertyBag.h
@@ -27,11 +27,12 @@
// IDSMPropertyBag
interface __declspec(uuid("232FD5D2-4954-41E7-BF9B-09E1257B1A95"))
-IDSMPropertyBag :
-public IPropertyBag2 {
+ IDSMPropertyBag :
+ public IPropertyBag2
+{
STDMETHOD(SetProperty)(LPCWSTR key, LPCWSTR value) PURE;
- STDMETHOD(SetProperty)(LPCWSTR key, VARIANT * var) PURE;
- STDMETHOD(GetProperty)(LPCWSTR key, BSTR * value) PURE;
+ STDMETHOD(SetProperty)(LPCWSTR key, VARIANT* var) PURE;
+ STDMETHOD(GetProperty)(LPCWSTR key, BSTR* value) PURE;
STDMETHOD(DelAllProperties)() PURE;
STDMETHOD(DelProperty)(LPCWSTR key) PURE;
};
@@ -74,12 +75,13 @@ public:
// IDSMResourceBag
interface __declspec(uuid("EBAFBCBE-BDE0-489A-9789-05D5692E3A93"))
-IDSMResourceBag :
-public IUnknown {
+ IDSMResourceBag :
+ public IUnknown
+{
STDMETHOD_(DWORD, ResGetCount)() PURE;
- STDMETHOD(ResGet)(DWORD iIndex, BSTR * ppName, BSTR * ppDesc, BSTR * ppMime, BYTE** ppData, DWORD * pDataLen, DWORD_PTR * pTag) PURE;
- STDMETHOD(ResSet)(DWORD iIndex, LPCWSTR pName, LPCWSTR pDesc, LPCWSTR pMime, const BYTE * pData, DWORD len, DWORD_PTR tag) PURE;
- STDMETHOD(ResAppend)(LPCWSTR pName, LPCWSTR pDesc, LPCWSTR pMime, BYTE * pData, DWORD len, DWORD_PTR tag) PURE;
+ STDMETHOD(ResGet)(DWORD iIndex, BSTR* ppName, BSTR* ppDesc, BSTR* ppMime, BYTE** ppData, DWORD* pDataLen, DWORD_PTR* pTag) PURE;
+ STDMETHOD(ResSet)(DWORD iIndex, LPCWSTR pName, LPCWSTR pDesc, LPCWSTR pMime, const BYTE* pData, DWORD len, DWORD_PTR tag) PURE;
+ STDMETHOD(ResAppend)(LPCWSTR pName, LPCWSTR pDesc, LPCWSTR pMime, BYTE* pData, DWORD len, DWORD_PTR tag) PURE;
STDMETHOD(ResRemoveAt)(DWORD iIndex) PURE;
STDMETHOD(ResRemoveAll)(DWORD_PTR tag) PURE;
};
@@ -127,15 +129,16 @@ public:
// IDSMChapterBag
interface __declspec(uuid("2D0EBE73-BA82-4E90-859B-C7C48ED3650F"))
-IDSMChapterBag :
-public IUnknown {
+ IDSMChapterBag :
+ public IUnknown
+{
STDMETHOD_(DWORD, ChapGetCount)() PURE;
- STDMETHOD(ChapGet)(DWORD iIndex, REFERENCE_TIME * prt, BSTR * ppName) PURE;
+ STDMETHOD(ChapGet)(DWORD iIndex, REFERENCE_TIME* prt, BSTR* ppName) PURE;
STDMETHOD(ChapSet)(DWORD iIndex, REFERENCE_TIME rt, LPCWSTR pName) PURE;
STDMETHOD(ChapAppend)(REFERENCE_TIME rt, LPCWSTR pName) PURE;
STDMETHOD(ChapRemoveAt)(DWORD iIndex) PURE;
STDMETHOD(ChapRemoveAll)() PURE;
- STDMETHOD_(long, ChapLookup)(REFERENCE_TIME * prt, BSTR * ppName) PURE;
+ STDMETHOD_(long, ChapLookup)(REFERENCE_TIME* prt, BSTR* ppName) PURE;
STDMETHOD(ChapSort)() PURE;
};
diff --git a/src/SubPic/XySubPicProvider.h b/src/SubPic/XySubPicProvider.h
index 28d865fc0..35763b6d1 100644
--- a/src/SubPic/XySubPicProvider.h
+++ b/src/SubPic/XySubPicProvider.h
@@ -1,6 +1,6 @@
/*
* (C) 2003-2006 Gabest
- * (C) 2006-2013 see Authors.txt
+ * (C) 2006-2013, 2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -26,11 +26,12 @@
interface __declspec(uuid("63679E0A-93AB-4656-AF40-589E4E985991"))
-IXyCompatProvider :
-public IUnknown {
+ IXyCompatProvider :
+ public IUnknown
+{
STDMETHOD(RequestFrame)(REFERENCE_TIME start, REFERENCE_TIME stop, DWORD timeout) PURE;
- STDMETHOD(DeliverFrame)(REFERENCE_TIME start, REFERENCE_TIME stop, LPVOID context, ISubRenderFrame * subtitleFrame) PURE;
- STDMETHOD(GetID)(ULONGLONG * id) PURE;
+ STDMETHOD(DeliverFrame)(REFERENCE_TIME start, REFERENCE_TIME stop, LPVOID context, ISubRenderFrame* subtitleFrame) PURE;
+ STDMETHOD(GetID)(ULONGLONG* id) PURE;
};
class CXySubPicProvider
diff --git a/src/Subtitles/STS.cpp b/src/Subtitles/STS.cpp
index 902d8a28d..f872ec687 100644
--- a/src/Subtitles/STS.cpp
+++ b/src/Subtitles/STS.cpp
@@ -1290,7 +1290,7 @@ static bool LoadFont(const CString& font)
HANDLE hFont = INVALID_HANDLE_VALUE;
if (HMODULE hModule = LoadLibrary(_T("gdi32.dll"))) {
- typedef HANDLE(WINAPI * PAddFontMemResourceEx)(IN PVOID, IN DWORD, IN PVOID , IN DWORD*);
+ typedef HANDLE(WINAPI * PAddFontMemResourceEx)(IN PVOID, IN DWORD, IN PVOID, IN DWORD*);
if (PAddFontMemResourceEx f = (PAddFontMemResourceEx)GetProcAddress(hModule, "AddFontMemResourceEx")) {
DWORD cFonts;
hFont = f(pData, datalen, nullptr, &cFonts);
diff --git a/src/Subtitles/VobSubFile.cpp b/src/Subtitles/VobSubFile.cpp
index 1498489f1..c8045ae28 100644
--- a/src/Subtitles/VobSubFile.cpp
+++ b/src/Subtitles/VobSubFile.cpp
@@ -920,7 +920,7 @@ bool CVobSubFile::ReadIfo(CString fn)
m_orgpal[i].rgbRed = std::min<BYTE>(std::max<BYTE>(BYTE(1.0 * y + 1.4022 * (u - 128)), 0u), 255u);
m_orgpal[i].rgbGreen = std::min<BYTE>(std::max<BYTE>(BYTE(1.0 * y - 0.3456 * (u - 128) - 0.7145 * (v - 128)), 0u), 255u);
- m_orgpal[i].rgbBlue = std::min<BYTE>(std::max<BYTE>(BYTE(1.0 * y + 1.7710 * (v - 128)), 0u) , 255u);
+ m_orgpal[i].rgbBlue = std::min<BYTE>(std::max<BYTE>(BYTE(1.0 * y + 1.7710 * (v - 128)), 0u), 255u);
}
return true;
diff --git a/src/Subtitles/VobSubFileRipper.cpp b/src/Subtitles/VobSubFileRipper.cpp
index 398b90649..c58566823 100644
--- a/src/Subtitles/VobSubFileRipper.cpp
+++ b/src/Subtitles/VobSubFileRipper.cpp
@@ -238,7 +238,7 @@ bool CVobSubFileRipper::LoadIfo(CString fn)
pgc.pal[j].rgbRed = std::min<BYTE>(std::max<BYTE>(BYTE(1.0 * y + 1.4022 * (u - 128)), 0u), 255u);
pgc.pal[j].rgbGreen = std::min<BYTE>(std::max<BYTE>(BYTE(1.0 * y - 0.3456 * (u - 128) - 0.7145 * (v - 128)), 0u), 255u);
- pgc.pal[j].rgbBlue = std::min<BYTE>(std::max<BYTE>(BYTE(1.0 * y + 1.7710 * (v - 128)), 0u) , 255u);
+ pgc.pal[j].rgbBlue = std::min<BYTE>(std::max<BYTE>(BYTE(1.0 * y + 1.7710 * (v - 128)), 0u), 255u);
}
//
diff --git a/src/Subtitles/VobSubFileRipper.h b/src/Subtitles/VobSubFileRipper.h
index a8b3fc04e..20e3050d8 100644
--- a/src/Subtitles/VobSubFileRipper.h
+++ b/src/Subtitles/VobSubFileRipper.h
@@ -1,6 +1,6 @@
/*
* (C) 2003-2006 Gabest
- * (C) 2006-2014 see Authors.txt
+ * (C) 2006-2014, 2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -87,8 +87,9 @@ struct vcchunk {
//
interface __declspec(uuid("9E2EBB5C-AD7C-452f-A48B-38685716AC46"))
-IVSFRipperCallback :
-public IUnknown {
+ IVSFRipperCallback :
+ public IUnknown
+{
STDMETHOD(OnMessage)(LPCTSTR msg) PURE;
STDMETHOD(OnProgress)(double progress /*0.0 -> 1.0*/) PURE;
STDMETHOD(OnFinished)(bool bSucceeded) PURE;
@@ -120,14 +121,15 @@ public:
//
interface __declspec(uuid("69F935BB-B8D0-43f5-AA2E-BBD0851CC9A6"))
-IVSFRipper :
-public IUnknown {
- STDMETHOD(SetCallBack)(IVSFRipperCallback * pCallback) PURE;
+ IVSFRipper :
+ public IUnknown
+{
+ STDMETHOD(SetCallBack)(IVSFRipperCallback* pCallback) PURE;
STDMETHOD(LoadParamFile)(CString fn) PURE;
STDMETHOD(SetInput)(CString infn) PURE;
STDMETHOD(SetOutput)(CString outfn) PURE;
- STDMETHOD(GetRipperData)(VSFRipperData & rd) PURE;
- STDMETHOD(UpdateRipperData)(VSFRipperData & rd) PURE;
+ STDMETHOD(GetRipperData)(VSFRipperData& rd) PURE;
+ STDMETHOD(UpdateRipperData)(VSFRipperData& rd) PURE;
STDMETHOD(Index)() PURE;
STDMETHOD(IsIndexing)() PURE;
STDMETHOD(Abort)(bool bSavePartial) PURE;
diff --git a/src/filters/InternalPropertyPage.h b/src/filters/InternalPropertyPage.h
index 0c4b29de5..f314f8013 100644
--- a/src/filters/InternalPropertyPage.h
+++ b/src/filters/InternalPropertyPage.h
@@ -1,6 +1,6 @@
/*
* (C) 2003-2006 Gabest
- * (C) 2006-2012 see Authors.txt
+ * (C) 2006-2012, 2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -27,9 +27,10 @@
#define IPP_SCALE(size) ((size) * m_fontheight / IPP_FONTSIZE)
interface __declspec(uuid("03481710-D73E-4674-839F-03EDE2D60ED8"))
-ISpecifyPropertyPages2 :
-public ISpecifyPropertyPages {
- STDMETHOD(CreatePage)(const GUID & guid, IPropertyPage** ppPage) = 0;
+ ISpecifyPropertyPages2 :
+ public ISpecifyPropertyPages
+{
+ STDMETHOD(CreatePage)(const GUID& guid, IPropertyPage** ppPage) = 0;
};
class CInternalPropertyPageWnd : public CWnd
diff --git a/src/filters/muxer/BaseMuxer/BaseMuxerRelatedPin.h b/src/filters/muxer/BaseMuxer/BaseMuxerRelatedPin.h
index be749ce97..4a2b8d0f1 100644
--- a/src/filters/muxer/BaseMuxer/BaseMuxerRelatedPin.h
+++ b/src/filters/muxer/BaseMuxer/BaseMuxerRelatedPin.h
@@ -1,6 +1,6 @@
/*
* (C) 2003-2006 Gabest
- * (C) 2006-2013 see Authors.txt
+ * (C) 2006-2013, 2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -22,9 +22,10 @@
#pragma once
interface __declspec(uuid("EE6F2741-7DB4-4AAD-A3CB-545208EE4C0A"))
-IBaseMuxerRelatedPin :
-public IUnknown {
- STDMETHOD(SetRelatedPin)(CBasePin * pPin) PURE;
+ IBaseMuxerRelatedPin :
+ public IUnknown
+{
+ STDMETHOD(SetRelatedPin)(CBasePin* pPin) PURE;
STDMETHOD_(CBasePin*, GetRelatedPin)() PURE;
};
diff --git a/src/filters/muxer/BaseMuxer/BitStream.h b/src/filters/muxer/BaseMuxer/BitStream.h
index 693b2c731..a5b6d0340 100644
--- a/src/filters/muxer/BaseMuxer/BitStream.h
+++ b/src/filters/muxer/BaseMuxer/BitStream.h
@@ -1,6 +1,6 @@
/*
* (C) 2003-2006 Gabest
- * (C) 2006-2013 see Authors.txt
+ * (C) 2006-2013, 2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -22,8 +22,9 @@
#pragma once
interface __declspec(uuid("30AB78C7-5259-4594-AEFE-9C0FC2F08A5E"))
-IBitStream :
-public IUnknown {
+ IBitStream :
+ public IUnknown
+{
STDMETHOD_(UINT64, GetPos)() PURE;
STDMETHOD_(UINT64, Seek)(UINT64 pos) PURE; // it's a _stream_, please don't seek if you don't have to
STDMETHOD(ByteWrite)(const void* pData, int len) PURE;
diff --git a/src/filters/muxer/MatroskaMuxer/MatroskaMuxer.h b/src/filters/muxer/MatroskaMuxer/MatroskaMuxer.h
index 66ae5d0bf..1be34109f 100644
--- a/src/filters/muxer/MatroskaMuxer/MatroskaMuxer.h
+++ b/src/filters/muxer/MatroskaMuxer/MatroskaMuxer.h
@@ -1,6 +1,6 @@
/*
* (C) 2003-2006 Gabest
- * (C) 2006-2013 see Authors.txt
+ * (C) 2006-2013, 2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -86,8 +86,9 @@ public:
};
interface __declspec(uuid("38E2D43D-915D-493C-B373-888DB16EE3DC"))
-IMatroskaMuxer :
-public IUnknown {
+ IMatroskaMuxer :
+ public IUnknown
+{
STDMETHOD(CorrectTimeOffset)(bool fNegative, bool fPositive) PURE;
// TODO: chapters
};
diff --git a/src/filters/parser/BaseSplitter/AsyncReader.h b/src/filters/parser/BaseSplitter/AsyncReader.h
index b6e69237c..e1ee7d8c4 100644
--- a/src/filters/parser/BaseSplitter/AsyncReader.h
+++ b/src/filters/parser/BaseSplitter/AsyncReader.h
@@ -1,6 +1,6 @@
/*
* (C) 2003-2006 Gabest
- * (C) 2006-2013 see Authors.txt
+ * (C) 2006-2013, 2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -24,17 +24,19 @@
#include "MultiFiles.h"
interface __declspec(uuid("6DDB4EE7-45A0-4459-A508-BD77B32C91B2"))
-ISyncReader :
-public IUnknown {
+ ISyncReader :
+ public IUnknown
+{
STDMETHOD_(void, SetBreakEvent)(HANDLE hBreakEvent) PURE;
STDMETHOD_(bool, HasErrors)() PURE;
STDMETHOD_(void, ClearErrors)() PURE;
- STDMETHOD_(void, SetPTSOffset)(REFERENCE_TIME * rtPTSOffset) PURE;
+ STDMETHOD_(void, SetPTSOffset)(REFERENCE_TIME* rtPTSOffset) PURE;
};
interface __declspec(uuid("7D55F67A-826E-40B9-8A7D-3DF0CBBD272D"))
-IFileHandle :
-public IUnknown {
+ IFileHandle :
+ public IUnknown
+{
STDMETHOD_(HANDLE, GetFileHandle)() PURE;
STDMETHOD_(LPCTSTR, GetFileName)() PURE;
};
diff --git a/src/filters/renderer/VideoRenderers/AllocatorCommon.h b/src/filters/renderer/VideoRenderers/AllocatorCommon.h
index 360645f69..c668420c5 100644
--- a/src/filters/renderer/VideoRenderers/AllocatorCommon.h
+++ b/src/filters/renderer/VideoRenderers/AllocatorCommon.h
@@ -74,8 +74,9 @@ public:
// Set and query D3DFullscreen mode.
interface __declspec(uuid("8EA1E899-B77D-4777-9F0E-66421BEA50F8"))
-ID3DFullscreenControl :
-public IUnknown {
+ ID3DFullscreenControl :
+ public IUnknown
+{
STDMETHOD(SetD3DFullscreen)(bool fEnabled) PURE;
- STDMETHOD(GetD3DFullscreen)(bool * pfEnabled) PURE;
+ STDMETHOD(GetD3DFullscreen)(bool* pfEnabled) PURE;
};
diff --git a/src/filters/renderer/VideoRenderers/IPinHook.cpp b/src/filters/renderer/VideoRenderers/IPinHook.cpp
index 136366d52..209442e18 100644
--- a/src/filters/renderer/VideoRenderers/IPinHook.cpp
+++ b/src/filters/renderer/VideoRenderers/IPinHook.cpp
@@ -60,56 +60,56 @@ struct D3DFORMAT_TYPE {
};
const D3DFORMAT_TYPE D3DFormatType[] = {
- { D3DFMT_UNKNOWN , _T("D3DFMT_UNKNOWN ") },
- { D3DFMT_R8G8B8 , _T("D3DFMT_R8G8B8 ") },
- { D3DFMT_A8R8G8B8 , _T("D3DFMT_A8R8G8B8 ") },
- { D3DFMT_X8R8G8B8 , _T("D3DFMT_X8R8G8B8 ") },
- { D3DFMT_R5G6B5 , _T("D3DFMT_R5G6B5 ") },
- { D3DFMT_X1R5G5B5 , _T("D3DFMT_X1R5G5B5 ") },
- { D3DFMT_A1R5G5B5 , _T("D3DFMT_A1R5G5B5 ") },
- { D3DFMT_A4R4G4B4 , _T("D3DFMT_A4R4G4B4 ") },
- { D3DFMT_R3G3B2 , _T("D3DFMT_R3G3B2 ") },
- { D3DFMT_A8 , _T("D3DFMT_A8 ") },
- { D3DFMT_A8R3G3B2 , _T("D3DFMT_A8R3G3B2 ") },
- { D3DFMT_X4R4G4B4 , _T("D3DFMT_X4R4G4B4 ") },
- { D3DFMT_A2B10G10R10 , _T("D3DFMT_A2B10G10R10 ") },
- { D3DFMT_A8B8G8R8 , _T("D3DFMT_A8B8G8R8 ") },
- { D3DFMT_X8B8G8R8 , _T("D3DFMT_X8B8G8R8 ") },
- { D3DFMT_G16R16 , _T("D3DFMT_G16R16 ") },
- { D3DFMT_A2R10G10B10 , _T("D3DFMT_A2R10G10B10 ") },
- { D3DFMT_A16B16G16R16 , _T("D3DFMT_A16B16G16R16 ") },
- { D3DFMT_A8P8 , _T("D3DFMT_A8P8 ") },
- { D3DFMT_P8 , _T("D3DFMT_P8 ") },
- { D3DFMT_L8 , _T("D3DFMT_L8 ") },
- { D3DFMT_A8L8 , _T("D3DFMT_A8L8 ") },
- { D3DFMT_A4L4 , _T("D3DFMT_A4L4 ") },
- { D3DFMT_X8L8V8U8 , _T("D3DFMT_X8L8V8U8 ") },
- { D3DFMT_Q8W8V8U8 , _T("D3DFMT_Q8W8V8U8 ") },
- { D3DFMT_V16U16 , _T("D3DFMT_V16U16 ") },
- { D3DFMT_A2W10V10U10 , _T("D3DFMT_A2W10V10U10 ") },
- { D3DFMT_UYVY , _T("D3DFMT_UYVY ") },
- { D3DFMT_R8G8_B8G8 , _T("D3DFMT_R8G8_B8G8 ") },
- { D3DFMT_YUY2 , _T("D3DFMT_YUY2 ") },
- { D3DFMT_G8R8_G8B8 , _T("D3DFMT_G8R8_G8B8 ") },
- { D3DFMT_DXT1 , _T("D3DFMT_DXT1 ") },
- { D3DFMT_DXT2 , _T("D3DFMT_DXT2 ") },
- { D3DFMT_DXT3 , _T("D3DFMT_DXT3 ") },
- { D3DFMT_DXT4 , _T("D3DFMT_DXT4 ") },
- { D3DFMT_DXT5 , _T("D3DFMT_DXT5 ") },
- { D3DFMT_D16_LOCKABLE , _T("D3DFMT_D16_LOCKABLE ") },
- { D3DFMT_D32 , _T("D3DFMT_D32 ") },
- { D3DFMT_D15S1 , _T("D3DFMT_D15S1 ") },
- { D3DFMT_D24S8 , _T("D3DFMT_D24S8 ") },
- { D3DFMT_D24X8 , _T("D3DFMT_D24X8 ") },
- { D3DFMT_D24X4S4 , _T("D3DFMT_D24X4S4 ") },
- { D3DFMT_D16 , _T("D3DFMT_D16 ") },
- { D3DFMT_D32F_LOCKABLE , _T("D3DFMT_D32F_LOCKABLE") },
- { D3DFMT_D24FS8 , _T("D3DFMT_D24FS8 ") },
- { D3DFMT_L16 , _T("D3DFMT_L16 ") },
- { D3DFMT_VERTEXDATA , _T("D3DFMT_VERTEXDATA ") },
- { D3DFMT_INDEX16 , _T("D3DFMT_INDEX16 ") },
- { D3DFMT_INDEX32 , _T("D3DFMT_INDEX32 ") },
- { D3DFMT_Q16W16V16U16 , _T("D3DFMT_Q16W16V16U16 ") },
+ { D3DFMT_UNKNOWN, _T("D3DFMT_UNKNOWN ") },
+ { D3DFMT_R8G8B8, _T("D3DFMT_R8G8B8 ") },
+ { D3DFMT_A8R8G8B8, _T("D3DFMT_A8R8G8B8 ") },
+ { D3DFMT_X8R8G8B8, _T("D3DFMT_X8R8G8B8 ") },
+ { D3DFMT_R5G6B5, _T("D3DFMT_R5G6B5 ") },
+ { D3DFMT_X1R5G5B5, _T("D3DFMT_X1R5G5B5 ") },
+ { D3DFMT_A1R5G5B5, _T("D3DFMT_A1R5G5B5 ") },
+ { D3DFMT_A4R4G4B4, _T("D3DFMT_A4R4G4B4 ") },
+ { D3DFMT_R3G3B2, _T("D3DFMT_R3G3B2 ") },
+ { D3DFMT_A8, _T("D3DFMT_A8 ") },
+ { D3DFMT_A8R3G3B2, _T("D3DFMT_A8R3G3B2 ") },
+ { D3DFMT_X4R4G4B4, _T("D3DFMT_X4R4G4B4 ") },
+ { D3DFMT_A2B10G10R10, _T("D3DFMT_A2B10G10R10 ") },
+ { D3DFMT_A8B8G8R8, _T("D3DFMT_A8B8G8R8 ") },
+ { D3DFMT_X8B8G8R8, _T("D3DFMT_X8B8G8R8 ") },
+ { D3DFMT_G16R16, _T("D3DFMT_G16R16 ") },
+ { D3DFMT_A2R10G10B10, _T("D3DFMT_A2R10G10B10 ") },
+ { D3DFMT_A16B16G16R16, _T("D3DFMT_A16B16G16R16 ") },
+ { D3DFMT_A8P8, _T("D3DFMT_A8P8 ") },
+ { D3DFMT_P8, _T("D3DFMT_P8 ") },
+ { D3DFMT_L8, _T("D3DFMT_L8 ") },
+ { D3DFMT_A8L8, _T("D3DFMT_A8L8 ") },
+ { D3DFMT_A4L4, _T("D3DFMT_A4L4 ") },
+ { D3DFMT_X8L8V8U8, _T("D3DFMT_X8L8V8U8 ") },
+ { D3DFMT_Q8W8V8U8, _T("D3DFMT_Q8W8V8U8 ") },
+ { D3DFMT_V16U16, _T("D3DFMT_V16U16 ") },
+ { D3DFMT_A2W10V10U10, _T("D3DFMT_A2W10V10U10 ") },
+ { D3DFMT_UYVY, _T("D3DFMT_UYVY ") },
+ { D3DFMT_R8G8_B8G8, _T("D3DFMT_R8G8_B8G8 ") },
+ { D3DFMT_YUY2, _T("D3DFMT_YUY2 ") },
+ { D3DFMT_G8R8_G8B8, _T("D3DFMT_G8R8_G8B8 ") },
+ { D3DFMT_DXT1, _T("D3DFMT_DXT1 ") },
+ { D3DFMT_DXT2, _T("D3DFMT_DXT2 ") },
+ { D3DFMT_DXT3, _T("D3DFMT_DXT3 ") },
+ { D3DFMT_DXT4, _T("D3DFMT_DXT4 ") },
+ { D3DFMT_DXT5, _T("D3DFMT_DXT5 ") },
+ { D3DFMT_D16_LOCKABLE, _T("D3DFMT_D16_LOCKABLE ") },
+ { D3DFMT_D32, _T("D3DFMT_D32 ") },
+ { D3DFMT_D15S1, _T("D3DFMT_D15S1 ") },
+ { D3DFMT_D24S8, _T("D3DFMT_D24S8 ") },
+ { D3DFMT_D24X8, _T("D3DFMT_D24X8 ") },
+ { D3DFMT_D24X4S4, _T("D3DFMT_D24X4S4 ") },
+ { D3DFMT_D16, _T("D3DFMT_D16 ") },
+ { D3DFMT_D32F_LOCKABLE, _T("D3DFMT_D32F_LOCKABLE") },
+ { D3DFMT_D24FS8, _T("D3DFMT_D24FS8 ") },
+ { D3DFMT_L16, _T("D3DFMT_L16 ") },
+ { D3DFMT_VERTEXDATA, _T("D3DFMT_VERTEXDATA ") },
+ { D3DFMT_INDEX16, _T("D3DFMT_INDEX16 ") },
+ { D3DFMT_INDEX32, _T("D3DFMT_INDEX32 ") },
+ { D3DFMT_Q16W16V16U16, _T("D3DFMT_Q16W16V16U16 ") },
{ MAKEFOURCC('N', 'V', '1', '2'), _T("D3DFMT_NV12") },
{ MAKEFOURCC('N', 'V', '2', '4'), _T("D3DFMT_NV24") },
@@ -1372,7 +1372,8 @@ struct IDirectXVideoDecoderServiceCVtbl {
END_INTERFACE
};
-interface IDirectXVideoDecoderServiceC {
+interface IDirectXVideoDecoderServiceC
+{
CONST_VTBL struct IDirectXVideoDecoderServiceCVtbl* lpVtbl;
};
diff --git a/src/filters/renderer/VideoRenderers/IPinHook.h b/src/filters/renderer/VideoRenderers/IPinHook.h
index 7425224a9..85ba4b957 100644
--- a/src/filters/renderer/VideoRenderers/IPinHook.h
+++ b/src/filters/renderer/VideoRenderers/IPinHook.h
@@ -1,6 +1,6 @@
/*
* (C) 2003-2006 Gabest
- * (C) 2006-2015 see Authors.txt
+ * (C) 2006-2015, 2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -48,7 +48,8 @@ typedef struct IPinCVtbl {
END_INTERFACE
} IPinCVtbl;
-interface IPinC {
+interface IPinC
+{
CONST_VTBL struct IPinCVtbl* lpVtbl;
};
@@ -68,7 +69,8 @@ typedef struct IMemInputPinCVtbl {
END_INTERFACE
} IMemInputPinCVtbl;
-interface IMemInputPinC {
+interface IMemInputPinC
+{
CONST_VTBL struct IMemInputPinCVtbl* lpVtbl;
};
@@ -171,7 +173,8 @@ typedef struct IAMVideoAcceleratorCVtbl {
END_INTERFACE
} IAMVideoAcceleratorCVtbl;
-interface IAMVideoAcceleratorC {
+interface IAMVideoAcceleratorC
+{
CONST_VTBL struct IAMVideoAcceleratorCVtbl* lpVtbl;
};
diff --git a/src/filters/renderer/VideoRenderers/IQTVideoSurface.h b/src/filters/renderer/VideoRenderers/IQTVideoSurface.h
index fa83c57b7..6b23954b0 100644
--- a/src/filters/renderer/VideoRenderers/IQTVideoSurface.h
+++ b/src/filters/renderer/VideoRenderers/IQTVideoSurface.h
@@ -1,6 +1,6 @@
/*
* (C) 2003-2006 Gabest
- * (C) 2006-2012 see Authors.txt
+ * (C) 2006-2012, 2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -26,8 +26,9 @@
//
interface __declspec(uuid("A6AE36F7-A6F2-4157-AF54-6599857E4E20"))
-IQTVideoSurface :
-public IUnknown {
- STDMETHOD(BeginBlt)(const BITMAP & bm) PURE;
- STDMETHOD(DoBlt)(const BITMAP & bm) PURE;
+ IQTVideoSurface :
+ public IUnknown
+{
+ STDMETHOD(BeginBlt)(const BITMAP& bm) PURE;
+ STDMETHOD(DoBlt)(const BITMAP& bm) PURE;
};
diff --git a/src/filters/renderer/VideoRenderers/PixelShaderCompiler.cpp b/src/filters/renderer/VideoRenderers/PixelShaderCompiler.cpp
index ea0a4139e..f117331d0 100644
--- a/src/filters/renderer/VideoRenderers/PixelShaderCompiler.cpp
+++ b/src/filters/renderer/VideoRenderers/PixelShaderCompiler.cpp
@@ -211,7 +211,7 @@ HRESULT CPixelShaderCompiler::CompileShaderFromFile(
long size = ftell(fp);
rewind(fp);
if (size > 0) {
- auto data = new(std::nothrow) char[(size_t)size];
+ auto data = new (std::nothrow) char[(size_t)size];
if (data) {
if (fread(data, size, 1, fp) == 1) {
ret = InternalCompile(data, (size_t)size, CT2A(pSrcFile), pEntrypoint,
diff --git a/src/filters/renderer/VideoRenderers/SyncAllocatorPresenter.h b/src/filters/renderer/VideoRenderers/SyncAllocatorPresenter.h
index c468425f5..b07d5d098 100644
--- a/src/filters/renderer/VideoRenderers/SyncAllocatorPresenter.h
+++ b/src/filters/renderer/VideoRenderers/SyncAllocatorPresenter.h
@@ -1,5 +1,5 @@
/*
- * (C) 2010-2012 see Authors.txt
+ * (C) 2010-2012, 2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -24,9 +24,10 @@
DEFINE_GUID(CLSID_SyncAllocatorPresenter, 0xf9f62627, 0xe3ef, 0x4a2e, 0xb6, 0xc9, 0x5d, 0x4c, 0xd, 0xc3, 0x32, 0x6b);
interface __declspec(uuid("F891C2A9-1DFF-45e0-9129-30C0990C5A9F"))
-ISyncClockAdviser :
-public IUnknown {
- STDMETHOD(AdviseSyncClock)(ISyncClock * sC) PURE;
+ ISyncClockAdviser :
+ public IUnknown
+{
+ STDMETHOD(AdviseSyncClock)(ISyncClock* sC) PURE;
};
HRESULT CreateSyncRenderer(const CLSID& clsid, HWND hWnd, bool bFullscreen, ISubPicAllocatorPresenter** ppAP);
diff --git a/src/filters/renderer/VideoRenderers/SyncRenderer.cpp b/src/filters/renderer/VideoRenderers/SyncRenderer.cpp
index 43ce1ea64..8c884b348 100644
--- a/src/filters/renderer/VideoRenderers/SyncRenderer.cpp
+++ b/src/filters/renderer/VideoRenderers/SyncRenderer.cpp
@@ -3238,7 +3238,7 @@ bool CSyncAP::GetSampleFromMixer()
{
llClockBefore = GetRenderersData()->GetPerfCounter();
- hr = m_pMixer->ProcessOutput(0 , 1, &dataBuffer, &dwStatus);
+ hr = m_pMixer->ProcessOutput(0, 1, &dataBuffer, &dwStatus);
llClockAfter = GetRenderersData()->GetPerfCounter();
}
diff --git a/src/filters/switcher/AudioSwitcher/AudioSwitcher.h b/src/filters/switcher/AudioSwitcher/AudioSwitcher.h
index dec51c378..43007eef0 100644
--- a/src/filters/switcher/AudioSwitcher/AudioSwitcher.h
+++ b/src/filters/switcher/AudioSwitcher/AudioSwitcher.h
@@ -1,6 +1,6 @@
/*
* (C) 2003-2006 Gabest
- * (C) 2006-2013 see Authors.txt
+ * (C) 2006-2013, 2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -28,10 +28,11 @@
interface __declspec(uuid("CEDB2890-53AE-4231-91A3-B0AAFCD1DBDE"))
-IAudioSwitcherFilter :
-public IUnknown {
- STDMETHOD(GetInputSpeakerConfig)(DWORD * pdwChannelMask) PURE;
- STDMETHOD(GetSpeakerConfig)(bool * pfCustomChannelMapping, DWORD pSpeakerToChannelMap[AS_MAX_CHANNELS][AS_MAX_CHANNELS]) PURE;
+ IAudioSwitcherFilter :
+ public IUnknown
+{
+ STDMETHOD(GetInputSpeakerConfig)(DWORD* pdwChannelMask) PURE;
+ STDMETHOD(GetSpeakerConfig)(bool* pfCustomChannelMapping, DWORD pSpeakerToChannelMap[AS_MAX_CHANNELS][AS_MAX_CHANNELS]) PURE;
STDMETHOD(SetSpeakerConfig)(bool fCustomChannelMapping, DWORD pSpeakerToChannelMap[AS_MAX_CHANNELS][AS_MAX_CHANNELS]) PURE;
STDMETHOD_(int, GetNumberOfInputChannels)() PURE;
STDMETHOD_(bool, IsDownSamplingTo441Enabled)() PURE;
@@ -39,10 +40,10 @@ public IUnknown {
STDMETHOD_(REFERENCE_TIME, GetAudioTimeShift)() PURE;
STDMETHOD(SetAudioTimeShift)(REFERENCE_TIME rtAudioTimeShift) PURE;
// Deprecated
- STDMETHOD(GetNormalizeBoost)(bool & fNormalize, bool & fNormalizeRecover, float & boost_dB) PURE;
+ STDMETHOD(GetNormalizeBoost)(bool& fNormalize, bool& fNormalizeRecover, float& boost_dB) PURE;
// Deprecated
STDMETHOD(SetNormalizeBoost)(bool fNormalize, bool fNormalizeRecover, float boost_dB) PURE;
- STDMETHOD(GetNormalizeBoost2)(bool & fNormalize, UINT & nMaxNormFactor, bool & fNormalizeRecover, UINT & nBoost) PURE;
+ STDMETHOD(GetNormalizeBoost2)(bool& fNormalize, UINT& nMaxNormFactor, bool& fNormalizeRecover, UINT& nBoost) PURE;
STDMETHOD(SetNormalizeBoost2)(bool fNormalize, UINT nMaxNormFactor, bool fNormalizeRecover, UINT nBoost) PURE;
};
diff --git a/src/filters/switcher/AudioSwitcher/StreamSwitcher.h b/src/filters/switcher/AudioSwitcher/StreamSwitcher.h
index 648a3e3ca..353d0f5f4 100644
--- a/src/filters/switcher/AudioSwitcher/StreamSwitcher.h
+++ b/src/filters/switcher/AudioSwitcher/StreamSwitcher.h
@@ -1,6 +1,6 @@
/*
* (C) 2003-2006 Gabest
- * (C) 2006-2013 see Authors.txt
+ * (C) 2006-2013, 2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -100,8 +100,9 @@ public:
};
interface __declspec(uuid("DA395FA3-4A3E-4D85-805E-0BEFF53D4BCD"))
-IStreamSwitcherInputPin :
-public IUnknown {
+ IStreamSwitcherInputPin :
+ public IUnknown
+{
STDMETHOD_(bool, IsActive)() PURE;
};
diff --git a/src/filters/transform/BufferFilter/BufferFilter.h b/src/filters/transform/BufferFilter/BufferFilter.h
index 594bf3270..3df9fbf12 100644
--- a/src/filters/transform/BufferFilter/BufferFilter.h
+++ b/src/filters/transform/BufferFilter/BufferFilter.h
@@ -1,6 +1,6 @@
/*
* (C) 2003-2006 Gabest
- * (C) 2006-2013 see Authors.txt
+ * (C) 2006-2013, 2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -26,8 +26,9 @@
#define BufferFilterName L"MPC-HC Buffer Filter"
interface __declspec(uuid("63EF0035-3FFE-4c41-9230-4346E028BE20"))
-IBufferFilter :
-public IUnknown {
+ IBufferFilter :
+ public IUnknown
+{
STDMETHOD(SetBuffers)(int nBuffers) PURE;
STDMETHOD_(int, GetBuffers)() PURE;
STDMETHOD_(int, GetFreeBuffers)() PURE;
diff --git a/src/filters/transform/VSFilter/DirectVobSubFilter.cpp b/src/filters/transform/VSFilter/DirectVobSubFilter.cpp
index b381f750e..3d2d221bd 100644
--- a/src/filters/transform/VSFilter/DirectVobSubFilter.cpp
+++ b/src/filters/transform/VSFilter/DirectVobSubFilter.cpp
@@ -574,7 +574,7 @@ void CDirectVobSubFilter::InitSubPicQueue()
HRESULT hr = S_OK;
m_pSubPicQueue = m_subPicQueueSettings.nSize > 0
- ? (ISubPicQueue*)DEBUG_NEW CSubPicQueue(m_subPicQueueSettings , pSubPicAllocator, &hr)
+ ? (ISubPicQueue*)DEBUG_NEW CSubPicQueue(m_subPicQueueSettings, pSubPicAllocator, &hr)
: (ISubPicQueue*)DEBUG_NEW CSubPicQueueNoThread(m_subPicQueueSettings, pSubPicAllocator, &hr);
if (FAILED(hr)) {
diff --git a/src/filters/transform/VSFilter/IDirectVobSub.h b/src/filters/transform/VSFilter/IDirectVobSub.h
index d96c84421..9d4a6f653 100644
--- a/src/filters/transform/VSFilter/IDirectVobSub.h
+++ b/src/filters/transform/VSFilter/IDirectVobSub.h
@@ -1,6 +1,6 @@
/*
* (C) 2003-2006 Gabest
- * (C) 2006-2014 see Authors.txt
+ * (C) 2006-2014, 2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -28,11 +28,12 @@ extern "C" {
#endif
interface __declspec(uuid("EBE1FB08-3957-47ca-AF13-5827E5442E56"))
-IDirectVobSub :
-public IUnknown {
- STDMETHOD(get_FileName)(THIS_ WCHAR * fn) PURE; // fn should point to a buffer allocated to at least the length of MAX_PATH (=260)
+ IDirectVobSub :
+ public IUnknown
+{
+ STDMETHOD(get_FileName)(THIS_ WCHAR* fn) PURE; // fn should point to a buffer allocated to at least the length of MAX_PATH (=260)
- STDMETHOD(put_FileName)(THIS_ WCHAR * fn) PURE;
+ STDMETHOD(put_FileName)(THIS_ WCHAR* fn) PURE;
STDMETHOD(get_LanguageCount)(THIS_ int* nLangs) PURE;
@@ -42,38 +43,38 @@ public IUnknown {
STDMETHOD(put_SelectedLanguage)(THIS_ int iSelected) PURE;
- STDMETHOD(get_HideSubtitles)(THIS_ bool * fHideSubtitles) PURE;
+ STDMETHOD(get_HideSubtitles)(THIS_ bool* fHideSubtitles) PURE;
STDMETHOD(put_HideSubtitles)(THIS_ bool fHideSubtitles) PURE;
// deprecated
- STDMETHOD(get_PreBuffering)(THIS_ bool * fDoPreBuffering) PURE;
+ STDMETHOD(get_PreBuffering)(THIS_ bool* fDoPreBuffering) PURE;
// deprecated
STDMETHOD(put_PreBuffering)(THIS_ bool fDoPreBuffering) PURE;
- STDMETHOD(get_Placement)(THIS_ bool * fOverridePlacement, int* xperc, int* yperc) PURE;
+ STDMETHOD(get_Placement)(THIS_ bool* fOverridePlacement, int* xperc, int* yperc) PURE;
STDMETHOD(put_Placement)(THIS_ bool fOverridePlacement, int xperc, int yperc) PURE;
- STDMETHOD(get_VobSubSettings)(THIS_ bool * fBuffer, bool * fOnlyShowForcedSubs, bool * fPolygonize) PURE;
+ STDMETHOD(get_VobSubSettings)(THIS_ bool* fBuffer, bool* fOnlyShowForcedSubs, bool* fPolygonize) PURE;
STDMETHOD(put_VobSubSettings)(THIS_ bool fBuffer, bool fOnlyShowForcedSubs, bool fPolygonize) PURE;
// depending on lflen, lf must point to LOGFONTA or LOGFONTW
- STDMETHOD(get_TextSettings)(THIS_ void* lf, int lflen, COLORREF * color, bool * fShadow, bool * fOutline, bool * fAdvancedRenderer) PURE;
+ STDMETHOD(get_TextSettings)(THIS_ void* lf, int lflen, COLORREF* color, bool* fShadow, bool* fOutline, bool* fAdvancedRenderer) PURE;
STDMETHOD(put_TextSettings)(THIS_ void* lf, int lflen, COLORREF color, bool fShadow, bool fOutline, bool fAdvancedRenderer) PURE;
- STDMETHOD(get_Flip)(THIS_ bool * fPicture, bool * fSubtitles) PURE;
+ STDMETHOD(get_Flip)(THIS_ bool* fPicture, bool* fSubtitles) PURE;
STDMETHOD(put_Flip)(THIS_ bool fPicture, bool fSubtitles) PURE;
- STDMETHOD(get_OSD)(THIS_ bool * fOSD) PURE;
+ STDMETHOD(get_OSD)(THIS_ bool* fOSD) PURE;
STDMETHOD(put_OSD)(THIS_ bool fOSD) PURE;
- STDMETHOD(get_SaveFullPath)(THIS_ bool * fSaveFullPath) PURE;
+ STDMETHOD(get_SaveFullPath)(THIS_ bool* fSaveFullPath) PURE;
STDMETHOD(put_SaveFullPath)(THIS_ bool fSaveFullPath) PURE;
@@ -81,7 +82,7 @@ public IUnknown {
STDMETHOD(put_SubtitleTiming)(THIS_ int delay, int speedmul, int speeddiv) PURE;
- STDMETHOD(get_MediaFPS)(THIS_ bool * fEnabled, double * fps) PURE;
+ STDMETHOD(get_MediaFPS)(THIS_ bool* fEnabled, double* fps) PURE;
STDMETHOD(put_MediaFPS)(THIS_ bool fEnabled, double fps) PURE;
@@ -92,9 +93,9 @@ public IUnknown {
STDMETHOD(put_ColorFormat)(THIS_ int iPosition) PURE;
- STDMETHOD(get_ZoomRect)(THIS_ NORMALIZEDRECT * rect) PURE;
+ STDMETHOD(get_ZoomRect)(THIS_ NORMALIZEDRECT* rect) PURE;
- STDMETHOD(put_ZoomRect)(THIS_ NORMALIZEDRECT * rect) PURE;
+ STDMETHOD(put_ZoomRect)(THIS_ NORMALIZEDRECT* rect) PURE;
STDMETHOD(UpdateRegistry)(THIS_) PURE;
@@ -105,11 +106,11 @@ public IUnknown {
STDMETHOD(ShowConfigDialog)(THIS_ int iSelected, HWND hWndParent) PURE; // if available, this will popup a child dialog allowing the user to edit the style options
- STDMETHOD(IsSubtitleReloaderLocked)(THIS_ bool * fLocked) PURE;
+ STDMETHOD(IsSubtitleReloaderLocked)(THIS_ bool* fLocked) PURE;
STDMETHOD(LockSubtitleReloader)(THIS_ bool fLock) PURE;
- STDMETHOD(get_SubtitleReloader)(THIS_ bool * fDisabled) PURE;
+ STDMETHOD(get_SubtitleReloader)(THIS_ bool* fDisabled) PURE;
STDMETHOD(put_SubtitleReloader)(THIS_ bool fDisable) PURE;
@@ -122,7 +123,7 @@ public IUnknown {
STDMETHOD(put_ExtendPicture)(THIS_ int horizontal, int vertical, int resx2, int resx2minw, int resx2minh) PURE;
// level: 0 - when needed, 1 - always, 2 - disabled
- STDMETHOD(get_LoadSettings)(THIS_ int* level, bool * fExternalLoad, bool * fWebLoad, bool * fEmbeddedLoad) PURE;
+ STDMETHOD(get_LoadSettings)(THIS_ int* level, bool* fExternalLoad, bool* fWebLoad, bool* fEmbeddedLoad) PURE;
STDMETHOD(put_LoadSettings)(THIS_ int level, bool fExternalLoad, bool fWebLoad, bool fEmbeddedLoad) PURE;
@@ -130,46 +131,50 @@ public IUnknown {
STDMETHOD(put_SubPictToBuffer)(THIS_ unsigned int uSubPictToBuffer) PURE;
- STDMETHOD(get_AnimWhenBuffering)(THIS_ bool * fAnimWhenBuffering) PURE;
+ STDMETHOD(get_AnimWhenBuffering)(THIS_ bool* fAnimWhenBuffering) PURE;
STDMETHOD(put_AnimWhenBuffering)(THIS_ bool fAnimWhenBuffering) PURE;
};
interface __declspec(uuid("FE6EC6A0-21CA-4970-9EF0-B296F7F38AF0"))
-ISubClock :
-public IUnknown {
+ ISubClock :
+ public IUnknown
+{
STDMETHOD(SetTime)(REFERENCE_TIME rt) PURE;
STDMETHOD_(REFERENCE_TIME, GetTime)() PURE;
};
interface __declspec(uuid("0665B760-FBC1-46C3-A35F-E471527C96A4"))
-ISubClock2 :
-public ISubClock {
+ ISubClock2 :
+ public ISubClock
+{
STDMETHOD(SetAvgTimePerFrame)(REFERENCE_TIME rt) PURE;
- STDMETHOD(GetAvgTimePerFrame)(REFERENCE_TIME * prt) PURE; // return S_OK only if *prt was set and is valid
+ STDMETHOD(GetAvgTimePerFrame)(REFERENCE_TIME* prt) PURE; // return S_OK only if *prt was set and is valid
};
interface __declspec(uuid("AB52FC9C-2415-4dca-BC1C-8DCC2EAE8150"))
-IDirectVobSub2 :
-public IDirectVobSub {
- STDMETHOD(AdviseSubClock)(THIS_ ISubClock * pSubClock) PURE;
+ IDirectVobSub2 :
+ public IDirectVobSub
+{
+ STDMETHOD(AdviseSubClock)(THIS_ ISubClock* pSubClock) PURE;
STDMETHOD_(bool, get_Forced)(THIS_) PURE;
STDMETHOD(put_Forced)(THIS_ bool fForced) PURE;
- STDMETHOD(get_TextSettings)(THIS_ STSStyle * pDefStyle) PURE;
+ STDMETHOD(get_TextSettings)(THIS_ STSStyle* pDefStyle) PURE;
- STDMETHOD(put_TextSettings)(THIS_ STSStyle * pDefStyle) PURE;
+ STDMETHOD(put_TextSettings)(THIS_ STSStyle* pDefStyle) PURE;
- STDMETHOD(get_AspectRatioSettings)(THIS_ CSimpleTextSubtitle::EPARCompensationType * ePARCompensationType) PURE;
+ STDMETHOD(get_AspectRatioSettings)(THIS_ CSimpleTextSubtitle::EPARCompensationType* ePARCompensationType) PURE;
- STDMETHOD(put_AspectRatioSettings)(THIS_ CSimpleTextSubtitle::EPARCompensationType * ePARCompensationType) PURE;
+ STDMETHOD(put_AspectRatioSettings)(THIS_ CSimpleTextSubtitle::EPARCompensationType* ePARCompensationType) PURE;
};
interface __declspec(uuid("4484A031-713F-4893-8C24-4505C56E8915"))
-IDirectVobSub3 :
-public IDirectVobSub2 {
+ IDirectVobSub3 :
+ public IDirectVobSub2
+{
STDMETHOD_(bool, get_DisableSubtitleAnimation)(THIS_) PURE;
STDMETHOD(put_DisableSubtitleAnimation)(THIS_ bool bDisableSubtitleAnimation) PURE;
diff --git a/src/mpc-hc/BaseGraph.h b/src/mpc-hc/BaseGraph.h
index 2b040b70b..37bcd4425 100644
--- a/src/mpc-hc/BaseGraph.h
+++ b/src/mpc-hc/BaseGraph.h
@@ -1,6 +1,6 @@
/*
* (C) 2003-2006 Gabest
- * (C) 2006-2013 see Authors.txt
+ * (C) 2006-2013, 2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -43,8 +43,9 @@ enum engine_t {
};
interface __declspec(uuid("B110CDE5-6331-4118-8AAF-A870D6F7E2E4"))
-IGraphEngine :
-public IUnknown {
+ IGraphEngine :
+ public IUnknown
+{
STDMETHOD_(engine_t, GetEngine)() PURE;
};
diff --git a/src/mpc-hc/ComPropertySheet.h b/src/mpc-hc/ComPropertySheet.h
index 29be76cef..e4ea4ddd1 100644
--- a/src/mpc-hc/ComPropertySheet.h
+++ b/src/mpc-hc/ComPropertySheet.h
@@ -1,6 +1,6 @@
/*
* (C) 2003-2006 Gabest
- * (C) 2006-2013 see Authors.txt
+ * (C) 2006-2013, 2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -24,7 +24,8 @@
#include "ComPropertyPage.h"
-interface IComPropertyPageDirty {
+interface IComPropertyPageDirty
+{
virtual void OnSetDirty(bool fDirty) = 0;
};
diff --git a/src/mpc-hc/FGFilter.cpp b/src/mpc-hc/FGFilter.cpp
index 6ac3b7f70..3bcfe0577 100644
--- a/src/mpc-hc/FGFilter.cpp
+++ b/src/mpc-hc/FGFilter.cpp
@@ -270,10 +270,11 @@ HRESULT CFGFilterRegistry::Create(IBaseFilter** ppBF, CInterfaceList<IUnknown, &
};
interface __declspec(uuid("97f7c4d4-547b-4a5f-8332-536430ad2e4d"))
-IAMFilterData :
-public IUnknown {
- STDMETHOD(ParseFilterData)(BYTE * rgbFilterData, ULONG cb, BYTE** prgbRegFilter2) PURE;
- STDMETHOD(CreateFilterData)(REGFILTER2 * prf2, BYTE** prgbFilterData, ULONG * pcb) PURE;
+ IAMFilterData :
+ public IUnknown
+{
+ STDMETHOD(ParseFilterData)(BYTE* rgbFilterData, ULONG cb, BYTE** prgbRegFilter2) PURE;
+ STDMETHOD(CreateFilterData)(REGFILTER2* prf2, BYTE** prgbFilterData, ULONG* pcb) PURE;
};
void CFGFilterRegistry::ExtractFilterData(BYTE* p, UINT len)
diff --git a/src/mpc-hc/IGraphBuilder2.h b/src/mpc-hc/IGraphBuilder2.h
index f2aedfdd8..5e05c0e06 100644
--- a/src/mpc-hc/IGraphBuilder2.h
+++ b/src/mpc-hc/IGraphBuilder2.h
@@ -1,6 +1,6 @@
/*
* (C) 2003-2006 Gabest
- * (C) 2006-2014, 2016 see Authors.txt
+ * (C) 2006-2014, 2016-2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -24,14 +24,15 @@
class CMediaType;
interface __declspec(uuid("165BE9D6-0929-4363-9BA3-580D735AA0F6"))
-IGraphBuilder2 :
-public IFilterGraph2 {
- STDMETHOD(IsPinDirection)(IPin * pPin, PIN_DIRECTION dir) PURE;
- STDMETHOD(IsPinConnected)(IPin * pPin) PURE;
- STDMETHOD(ConnectFilter)(IBaseFilter * pBF, IPin * pPinIn) PURE;
- STDMETHOD(ConnectFilter)(IPin * pPinOut, IBaseFilter * pBF) PURE;
- STDMETHOD(ConnectFilterDirect)(IPin * pPinOut, IBaseFilter * pBF, const AM_MEDIA_TYPE * pmt) PURE;
- STDMETHOD(NukeDownstream)(IUnknown * pUnk) PURE;
+ IGraphBuilder2 :
+ public IFilterGraph2
+{
+ STDMETHOD(IsPinDirection)(IPin* pPin, PIN_DIRECTION dir) PURE;
+ STDMETHOD(IsPinConnected)(IPin* pPin) PURE;
+ STDMETHOD(ConnectFilter)(IBaseFilter* pBF, IPin* pPinIn) PURE;
+ STDMETHOD(ConnectFilter)(IPin* pPinOut, IBaseFilter* pBF) PURE;
+ STDMETHOD(ConnectFilterDirect)(IPin* pPinOut, IBaseFilter* pBF, const AM_MEDIA_TYPE* pmt) PURE;
+ STDMETHOD(NukeDownstream)(IUnknown* pUnk) PURE;
STDMETHOD(FindInterface)(REFIID iid, void** ppv, BOOL bRemove) PURE;
STDMETHOD(AddToROT)() PURE;
STDMETHOD(RemoveFromROT)() PURE;
@@ -39,20 +40,22 @@ public IFilterGraph2 {
// private use only
interface __declspec(uuid("43CDA93D-6A4E-4A07-BD3E-49D161073EE7"))
-IGraphBuilderDeadEnd :
-public IUnknown {
+ IGraphBuilderDeadEnd :
+ public IUnknown
+{
STDMETHOD_(size_t, GetCount)() PURE;
STDMETHOD(GetDeadEnd)(int iIndex, CAtlList<CStringW>& path, CAtlList<CMediaType>& mts) PURE;
};
// private use only
interface __declspec(uuid("546E72B3-66A1-4A58-A99B-56530B3E2FFF"))
-IBDATuner :
-public IUnknown {
+ IBDATuner :
+ public IUnknown
+{
STDMETHOD(SetChannel)(int nChannelPrefNumber) PURE;
STDMETHOD(SetAudio)(int nAudioIndex) PURE;
STDMETHOD(SetFrequency)(ULONG ulFrequency, ULONG ulBandwidth) PURE;
STDMETHOD(Scan)(ULONG ulFrequency, ULONG ulBandwidth, HWND hWnd) PURE;
- STDMETHOD(GetStats)(BOOLEAN & bPresent, BOOLEAN & bLocked, LONG & lDbStrength, LONG & lPercentQuality) PURE;
- STDMETHOD(UpdatePSI)(const class CDVBChannel * pChannel, struct EventDescriptor & NowNext) PURE;
+ STDMETHOD(GetStats)(BOOLEAN& bPresent, BOOLEAN& bLocked, LONG& lDbStrength, LONG& lPercentQuality) PURE;
+ STDMETHOD(UpdatePSI)(const class CDVBChannel* pChannel, struct EventDescriptor& NowNext) PURE;
};
diff --git a/src/mpc-hc/OpenFileDlg.cpp b/src/mpc-hc/OpenFileDlg.cpp
index c50821836..60f0af13b 100644
--- a/src/mpc-hc/OpenFileDlg.cpp
+++ b/src/mpc-hc/OpenFileDlg.cpp
@@ -1,6 +1,6 @@
/*
* (C) 2003-2006 Gabest
- * (C) 2006-2015 see Authors.txt
+ * (C) 2006-2015, 2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -81,7 +81,7 @@ BOOL COpenFileDlg::OnInitDialog()
{
CFileDialog::OnInitDialog();
- m_wndProc = (WNDPROC)SetWindowLongPtr(GetParent()->m_hWnd, GWLP_WNDPROC , (LONG_PTR)WindowProcNew);
+ m_wndProc = (WNDPROC)SetWindowLongPtr(GetParent()->m_hWnd, GWLP_WNDPROC, (LONG_PTR)WindowProcNew);
return TRUE; // return TRUE unless you set the focus to a control
// EXCEPTION: OCX Property Pages should return FALSE
diff --git a/src/mpc-hc/PPageAdvanced.cpp b/src/mpc-hc/PPageAdvanced.cpp
index b76d913a1..6039a9678 100644
--- a/src/mpc-hc/PPageAdvanced.cpp
+++ b/src/mpc-hc/PPageAdvanced.cpp
@@ -1,5 +1,5 @@
/*
-* (C) 2014-2016 see Authors.txt
+* (C) 2014-2017 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -307,7 +307,7 @@ void CPPageAdvanced::OnLvnItemchangedList(NMHDR* pNMHDR, LRESULT* pResult)
LPNMLISTVIEW pNMLV = reinterpret_cast<LPNMLISTVIEW>(pNMHDR);
if ((pNMLV->uChanged & LVIF_STATE) && (pNMLV->uNewState & LVNI_SELECTED)) {
- auto setDialogItemsVisibility = [this](std::initializer_list<int> && ids, int nCmdShow) {
+ auto setDialogItemsVisibility = [this](std::initializer_list<int>&& ids, int nCmdShow) {
for (const auto& nID : ids) {
GetDlgItem(nID)->ShowWindow(nCmdShow);
}
diff --git a/src/mpc-hc/SubtitleDlDlg.cpp b/src/mpc-hc/SubtitleDlDlg.cpp
index e8507c8b2..f4470b6e5 100644
--- a/src/mpc-hc/SubtitleDlDlg.cpp
+++ b/src/mpc-hc/SubtitleDlDlg.cpp
@@ -281,7 +281,7 @@ void CSubtitleDlDlg::OnOK()
if (m_list.GetCheck(i) == TRUE) {
SubtitlesInfo& subtitlesInfo = *(SubtitlesInfo*)(m_list.GetItemData(i));
- LVITEMINDEX lvii = { i , -1 };
+ LVITEMINDEX lvii = { i, -1 };
m_list.SetItemIndexState(&lvii, INDEXTOSTATEIMAGEMASK(0), LVIS_STATEIMAGEMASK);
subtitlesInfo.Download(bActivate);
bActivate = false;
diff --git a/src/mpc-hc/mplayerc.cpp b/src/mpc-hc/mplayerc.cpp
index fcff20c82..72388115e 100644
--- a/src/mpc-hc/mplayerc.cpp
+++ b/src/mpc-hc/mplayerc.cpp
@@ -1021,7 +1021,7 @@ BOOL CMPlayerCApp::GetProfileBinary(LPCTSTR lpszSection, LPCTSTR lpszEntry, LPBY
}
}
*pBytes = length / 2;
- *ppData = new(std::nothrow) BYTE[*pBytes];
+ *ppData = new (std::nothrow) BYTE[*pBytes];
if (!(*ppData)) {
ASSERT(FALSE);
return FALSE;