Changeset 831
- Timestamp:
- Mar 13, 2018, 12:24:24 PM (5 years ago)
- Location:
- trunk/DirectShowSpy
- Files:
-
- 12 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/DirectShowSpy/DirectShowSpy.sln
r763 r831 1 1 2 2 Microsoft Visual Studio Solution File, Format Version 12.00 3 # Visual Studio 201 53 # Visual Studio 2017 4 4 VisualStudioVersion = 12.0.40629.0 5 5 MinimumVisualStudioVersion = 10.0.40219.1 -
trunk/DirectShowSpy/DirectShowSpy.vcxproj
r763 r831 31 31 <RootNamespace>DirectShowSpy</RootNamespace> 32 32 <Keyword>AtlProj</Keyword> 33 <WindowsTargetPlatformVersion>10.0.1 5063.0</WindowsTargetPlatformVersion>33 <WindowsTargetPlatformVersion>10.0.16299.0</WindowsTargetPlatformVersion> 34 34 </PropertyGroup> 35 35 <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /> 36 36 <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Trace|Win32'" Label="Configuration"> 37 37 <ConfigurationType>DynamicLibrary</ConfigurationType> 38 <PlatformToolset>v14 0_xp</PlatformToolset>38 <PlatformToolset>v141</PlatformToolset> 39 39 <UseOfAtl>Static</UseOfAtl> 40 40 <CharacterSet>Unicode</CharacterSet> … … 43 43 <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration"> 44 44 <ConfigurationType>DynamicLibrary</ConfigurationType> 45 <PlatformToolset>v14 0_xp</PlatformToolset>45 <PlatformToolset>v141</PlatformToolset> 46 46 <UseOfAtl>Static</UseOfAtl> 47 47 <CharacterSet>Unicode</CharacterSet> … … 50 50 <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration"> 51 51 <ConfigurationType>DynamicLibrary</ConfigurationType> 52 <PlatformToolset>v14 0_xp</PlatformToolset>52 <PlatformToolset>v141</PlatformToolset> 53 53 <UseOfAtl>Dynamic</UseOfAtl> 54 54 <CharacterSet>Unicode</CharacterSet> … … 56 56 <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Trace|x64'" Label="Configuration"> 57 57 <ConfigurationType>DynamicLibrary</ConfigurationType> 58 <PlatformToolset>v14 0_xp</PlatformToolset>58 <PlatformToolset>v141</PlatformToolset> 59 59 <UseOfAtl>Static</UseOfAtl> 60 60 <CharacterSet>Unicode</CharacterSet> … … 63 63 <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration"> 64 64 <ConfigurationType>DynamicLibrary</ConfigurationType> 65 <PlatformToolset>v14 0_xp</PlatformToolset>65 <PlatformToolset>v141</PlatformToolset> 66 66 <UseOfAtl>Static</UseOfAtl> 67 67 <CharacterSet>Unicode</CharacterSet> … … 70 70 <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration"> 71 71 <ConfigurationType>DynamicLibrary</ConfigurationType> 72 <PlatformToolset>v14 0_xp</PlatformToolset>72 <PlatformToolset>v141</PlatformToolset> 73 73 <UseOfAtl>Dynamic</UseOfAtl> 74 74 <CharacterSet>Unicode</CharacterSet> … … 105 105 <LinkIncremental>true</LinkIncremental> 106 106 <IncludePath>..\..\Repository-Private\Utilities\DeflateTools\bzip2-1.0.6;$(IncludePath)</IncludePath> 107 <PostBuildEventUseInBuild>false</PostBuildEventUseInBuild> 107 108 </PropertyGroup> 108 109 <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> … … 112 113 <LinkIncremental>true</LinkIncremental> 113 114 <IncludePath>..\..\Repository-Private\Utilities\DeflateTools\bzip2-1.0.6;$(IncludePath)</IncludePath> 115 <PostBuildEventUseInBuild>false</PostBuildEventUseInBuild> 114 116 </PropertyGroup> 115 117 <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> … … 180 182 <AdditionalLibraryDirectories>..\..\Repository-Private\Utilities\DeflateTools\_Bin</AdditionalLibraryDirectories> 181 183 </Link> 184 <PostBuildEvent> 185 <Command>"$(AlaxInfo_Common)\..\Utilities\IncrementBuild\_Bin\IncrementBuild-$(PlatformName).exe" configuration "$(ProjectDir)Module.ini" binary "$(TargetPath)" string "ConfigurationName" "$(ConfigurationName)" 186 rem "$(WindowsSdkDir)bin\x64\signtool" sign /v /f "$(AlaxInfo_Common)\Certificate\PrivateSPC.pfx" /d "Alax.Info $(ProjectName) Module" /du http://alax.info /n "Roman Ryltsov" "$(TargetPath)"</Command> 187 </PostBuildEvent> 188 <PostBuildEvent> 189 <Message>Build Increment, Digital Signature</Message> 190 </PostBuildEvent> 182 191 </ItemDefinitionGroup> 183 192 <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> … … 219 228 <AdditionalLibraryDirectories>..\..\Repository-Private\Utilities\DeflateTools\_Bin</AdditionalLibraryDirectories> 220 229 </Link> 230 <PostBuildEvent> 231 <Command>"$(AlaxInfo_Common)\..\Utilities\IncrementBuild\_Bin\IncrementBuild-$(PlatformName).exe" configuration "$(ProjectDir)Module.ini" binary "$(TargetPath)" string "ConfigurationName" "$(ConfigurationName)" 232 rem "$(WindowsSdkDir)bin\x64\signtool" sign /v /f "$(AlaxInfo_Common)\Certificate\PrivateSPC.pfx" /d "Alax.Info $(ProjectName) Module" /du http://alax.info /n "Roman Ryltsov" "$(TargetPath)"</Command> 233 </PostBuildEvent> 234 <PostBuildEvent> 235 <Message>Build Increment, Digital Signature</Message> 236 </PostBuildEvent> 221 237 </ItemDefinitionGroup> 222 238 <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> … … 267 283 <AdditionalLibraryDirectories>..\..\Repository-Private\Utilities\DeflateTools\_Bin</AdditionalLibraryDirectories> 268 284 </Link> 285 <PostBuildEvent> 286 <Command>"$(AlaxInfo_Common)\..\Utilities\IncrementBuild\_Bin\IncrementBuild-$(PlatformName).exe" configuration "$(ProjectDir)Module.ini" binary "$(TargetPath)" string "ConfigurationName" "$(ConfigurationName)" 287 rem "$(WindowsSdkDir)bin\x64\signtool" sign /v /f "$(AlaxInfo_Common)\Certificate\PrivateSPC.pfx" /d "Alax.Info $(ProjectName) Module" /du http://alax.info /n "Roman Ryltsov" "$(TargetPath)"</Command> 288 </PostBuildEvent> 289 <PostBuildEvent> 290 <Message>Build Increment, Digital Signature</Message> 291 </PostBuildEvent> 269 292 </ItemDefinitionGroup> 270 293 <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'"> … … 314 337 <AdditionalLibraryDirectories>..\..\Repository-Private\Utilities\DeflateTools\_Bin</AdditionalLibraryDirectories> 315 338 </Link> 339 <PostBuildEvent> 340 <Command>"$(AlaxInfo_Common)\..\Utilities\IncrementBuild\_Bin\IncrementBuild-$(PlatformName).exe" configuration "$(ProjectDir)Module.ini" binary "$(TargetPath)" string "ConfigurationName" "$(ConfigurationName)" 341 rem "$(WindowsSdkDir)bin\x64\signtool" sign /v /f "$(AlaxInfo_Common)\Certificate\PrivateSPC.pfx" /d "Alax.Info $(ProjectName) Module" /du http://alax.info /n "Roman Ryltsov" "$(TargetPath)"</Command> 342 </PostBuildEvent> 343 <PostBuildEvent> 344 <Message>Build Increment, Digital Signature</Message> 345 </PostBuildEvent> 316 346 </ItemDefinitionGroup> 317 347 <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release Trace|Win32'"> … … 362 392 <AdditionalLibraryDirectories>..\..\Repository-Private\Utilities\DeflateTools\_Bin</AdditionalLibraryDirectories> 363 393 </Link> 394 <PostBuildEvent> 395 <Command>"$(AlaxInfo_Common)\..\Utilities\IncrementBuild\_Bin\IncrementBuild-$(PlatformName).exe" configuration "$(ProjectDir)Module.ini" binary "$(TargetPath)" string "ConfigurationName" "$(ConfigurationName)" 396 rem "$(WindowsSdkDir)bin\x64\signtool" sign /v /f "$(AlaxInfo_Common)\Certificate\PrivateSPC.pfx" /d "Alax.Info $(ProjectName) Module" /du http://alax.info /n "Roman Ryltsov" "$(TargetPath)"</Command> 397 </PostBuildEvent> 398 <PostBuildEvent> 399 <Message>Build Increment, Digital Signature</Message> 400 </PostBuildEvent> 364 401 </ItemDefinitionGroup> 365 402 <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release Trace|x64'"> … … 409 446 <AdditionalLibraryDirectories>..\..\Repository-Private\Utilities\DeflateTools\_Bin</AdditionalLibraryDirectories> 410 447 </Link> 448 <PostBuildEvent> 449 <Command>"$(AlaxInfo_Common)\..\Utilities\IncrementBuild\_Bin\IncrementBuild-$(PlatformName).exe" configuration "$(ProjectDir)Module.ini" binary "$(TargetPath)" string "ConfigurationName" "$(ConfigurationName)" 450 rem "$(WindowsSdkDir)bin\x64\signtool" sign /v /f "$(AlaxInfo_Common)\Certificate\PrivateSPC.pfx" /d "Alax.Info $(ProjectName) Module" /du http://alax.info /n "Roman Ryltsov" "$(TargetPath)"</Command> 451 </PostBuildEvent> 452 <PostBuildEvent> 453 <Message>Build Increment, Digital Signature</Message> 454 </PostBuildEvent> 411 455 </ItemDefinitionGroup> 412 456 <ItemGroup> … … 468 512 <None Include="..\..\Repository-Private\Utilities\EmailTools\_Bin\Win32\Release\EmailTools\EmailTools.tlb" /> 469 513 <None Include="Module.def" /> 514 <None Include="Module.ini" /> 470 515 <None Include="Module.rgs" /> 471 516 <None Include="GenericClass %28Both%29.rgs" /> -
trunk/DirectShowSpy/FilterGraphList.h
r545 r831 250 250 return ((CListPropertyPage*) nParameter)->SortGraphListViewItems(nItemParameter1, nItemParameter2); 251 251 } 252 static BOOL FindItem(CRoMapT<CStringW, CItem>& ItemMap, const CFilterGraphTable::CItem& TableItem) 253 { 254 for(auto&& MapItem: ItemMap.GetValues()) 255 { 256 if(MapItem.m_nProcessIdentifier != TableItem.m_nProcessIdentifier) 257 continue; 258 if(abs((LONG_PTR) MapItem.m_nInstance - (LONG_PTR) TableItem.m_nInstance) > 32) //if(MapItem.m_nInstance != TableItem.m_nInstance) 259 continue; 260 return TRUE; 261 } 262 return FALSE; 263 } 252 #if defined(AVAILABILITY_FILTERGRAPHTABLE) 253 static BOOL FindItem(CRoMapT<CStringW, CItem>& ItemMap, const CFilterGraphTable::CItem& TableItem) 254 { 255 for(auto&& MapItem: ItemMap.GetValues()) 256 { 257 if(MapItem.m_nProcessIdentifier != TableItem.m_nProcessIdentifier) 258 continue; 259 if(abs((LONG_PTR) MapItem.m_nInstance - (LONG_PTR) TableItem.m_nInstance) > 32) //if(MapItem.m_nInstance != TableItem.m_nInstance) 260 continue; 261 return TRUE; 262 } 263 return FALSE; 264 } 265 #endif // defined(AVAILABILITY_FILTERGRAPHTABLE) 264 266 static VOID EnumerateItems(IRunningObjectTable* pRunningObjectTable, CRoMapT<CStringW, CItem>& ItemMap, const LONG* pnProcessIdentifier = NULL) 265 267 { … … 309 311 } 310 312 #pragma region Filter Graph Table 311 _ATLTRY 312 { 313 CLocalObjectPtr<CFilterGraphTable> pFilterGraphTable; 314 CFilterGraphTable::CItemArray ItemArray; 315 if(pFilterGraphTable->GetItems(ItemArray)) 316 { 317 for(auto&& TableItem: ItemArray) 313 #if defined(AVAILABILITY_FILTERGRAPHTABLE) 314 _ATLTRY 315 { 316 CLocalObjectPtr<CFilterGraphTable> pFilterGraphTable; 317 CFilterGraphTable::CItemArray ItemArray; 318 if(pFilterGraphTable->GetItems(ItemArray)) 318 319 { 319 if(FindItem(ItemMap, TableItem)) 320 continue; 321 if(pnProcessIdentifier && TableItem.m_nProcessIdentifier != (DWORD) *pnProcessIdentifier) 322 continue; // Skip 323 const CStringW sDisplayName = AtlFormatStringW(L"!FilterGraph %p pid %08x; FGT", TableItem.m_nInstance, TableItem.m_nProcessIdentifier); 324 CItem Item; 325 Item.m_sDisplayName = sDisplayName; 326 Item.m_nInstance = TableItem.m_nInstance; 327 Item.m_nProcessIdentifier = TableItem.m_nProcessIdentifier; 328 Item.m_pFilterGraphUnknown = TableItem.m_pFilterGraph; 329 Item.m_pFilterGraph = TableItem.m_pFilterGraph; 330 SYSTEMTIME Time; 331 _W(FileTimeToSystemTime(&reinterpret_cast<const FILETIME&>(TableItem.m_nTime), &Time)); 332 Item.m_sTime = AtlFormatString(_T("%02d:%02d:%02d"), Time.wHour, Time.wMinute, Time.wSecond); 333 _W(ItemMap.SetAt(sDisplayName, Item) >= 0); 320 for(auto&& TableItem: ItemArray) 321 { 322 if(FindItem(ItemMap, TableItem)) 323 continue; 324 if(pnProcessIdentifier && TableItem.m_nProcessIdentifier != (DWORD) *pnProcessIdentifier) 325 continue; // Skip 326 const CStringW sDisplayName = AtlFormatStringW(L"!FilterGraph %p pid %08x; FGT", TableItem.m_nInstance, TableItem.m_nProcessIdentifier); 327 CItem Item; 328 Item.m_sDisplayName = sDisplayName; 329 Item.m_nInstance = TableItem.m_nInstance; 330 Item.m_nProcessIdentifier = TableItem.m_nProcessIdentifier; 331 Item.m_pFilterGraphUnknown = TableItem.m_pFilterGraph; 332 Item.m_pFilterGraph = TableItem.m_pFilterGraph; 333 SYSTEMTIME Time; 334 _W(FileTimeToSystemTime(&reinterpret_cast<const FILETIME&>(TableItem.m_nTime), &Time)); 335 Item.m_sTime = AtlFormatString(_T("%02d:%02d:%02d"), Time.wHour, Time.wMinute, Time.wSecond); 336 _W(ItemMap.SetAt(sDisplayName, Item) >= 0); 337 } 334 338 } 335 339 } 336 }337 _ATLCATCHALL()338 {339 _Z_EXCEPTION();340 }340 _ATLCATCHALL() 341 { 342 _Z_EXCEPTION(); 343 } 344 #endif // defined(AVAILABILITY_FILTERGRAPHTABLE) 341 345 #pragma endregion 342 346 } -
trunk/DirectShowSpy/FilterGraphSpy.h
r617 r831 191 191 public IDispatchImpl<ISpy>, 192 192 public ISpyEx, 193 public IFilterGraph 2,193 public IFilterGraph3, 194 194 public IDispatchImpl<IMediaControl, &__uuidof(IMediaControl), &__uuidof(Quartz::__QuartzTypeLib)>, 195 195 public IMediaEventSink, … … 227 227 COM_INTERFACE_ENTRY(ISpyEx) 228 228 COM_INTERFACE_ENTRY(IFilterGraph2) 229 COM_INTERFACE_ENTRY(IFilterGraph3) 229 230 COM_INTERFACE_ENTRY(IGraphBuilder) 230 231 COM_INTERFACE_ENTRY(IFilterGraph) … … 627 628 _FilterGraphHelper::CRotRunningFilterGraph m_RunningFilterGraph; 628 629 INT m_nRunningFilterGraphReference; 629 CLocalObjectPtr<CFilterGraphTableItem> m_pFilterGraphTableItem; 630 #if defined(AVAILABILITY_FILTERGRAPHTABLE) 631 CLocalObjectPtr<CFilterGraphTableItem> m_pFilterGraphTableItem; 632 #endif // defined(AVAILABILITY_FILTERGRAPHTABLE) 630 633 SYSTEMTIME m_Time; 631 634 CStringW m_sMonikerDisplayName; … … 675 678 } 676 679 #pragma region Filter Graph Table Item 677 static CConstIntegerRegistryValue g_nAutomaticFilterGraphTableItem(_T("Automatic Filter Graph Table Item")); // 0 Default (Disabled), 1 Disabled, 2 Enabled 678 if(g_nAutomaticFilterGraphTableItem == 2) // Enabled 679 _ATLTRY 680 { 681 _A(!m_pFilterGraphTableItem->IsFilterGraphAvailable()); 682 m_pFilterGraphTableItem->SetFilterGraph(this); 683 Release(); 684 } 685 _ATLCATCHALL() 686 { 687 _Z_EXCEPTION(); 688 } 680 #if defined(AVAILABILITY_FILTERGRAPHTABLE) 681 static CConstIntegerRegistryValue g_nAutomaticFilterGraphTableItem(_T("Automatic Filter Graph Table Item")); // 0 Default (Disabled), 1 Disabled, 2 Enabled 682 if(g_nAutomaticFilterGraphTableItem == 2) // Enabled 683 _ATLTRY 684 { 685 _A(!m_pFilterGraphTableItem->IsFilterGraphAvailable()); 686 m_pFilterGraphTableItem->SetFilterGraph(this); 687 Release(); 688 } 689 _ATLCATCHALL() 690 { 691 _Z_EXCEPTION(); 692 } 693 #endif // defined(AVAILABILITY_FILTERGRAPHTABLE) 689 694 #pragma endregion 690 695 if(!m_bIsAggregated) … … 706 711 return; 707 712 #pragma region Filter Graph Table Item 708 _ATLTRY 709 { 710 if(m_pFilterGraphTableItem->IsFilterGraphAvailable()) 711 { 712 AddRef(); 713 m_pFilterGraphTableItem->SetFilterGraph(NULL); 714 } 715 } 716 _ATLCATCHALL() 717 { 718 _Z_EXCEPTION(); 719 } 713 #if defined(AVAILABILITY_FILTERGRAPHTABLE) 714 _ATLTRY 715 { 716 if(m_pFilterGraphTableItem->IsFilterGraphAvailable()) 717 { 718 AddRef(); 719 m_pFilterGraphTableItem->SetFilterGraph(NULL); 720 } 721 } 722 _ATLCATCHALL() 723 { 724 _Z_EXCEPTION(); 725 } 726 #endif // defined(AVAILABILITY_FILTERGRAPHTABLE) 720 727 #pragma endregion 721 728 if(m_nRunningFilterGraphReference != 2) 722 729 AddRef(); 723 _Z4(atlTraceRefcount, 4, _T("this 0x%p, m_dwRef 0x% x\n"), this, m_dwRef);730 _Z4(atlTraceRefcount, 4, _T("this 0x%p, m_dwRef 0x%X\n"), this, m_dwRef); 724 731 m_RunningFilterGraph.SetFilterGraph(NULL); 725 732 { … … 727 734 m_sMonikerDisplayName.Empty(); 728 735 } 729 _Z4(atlTraceRefcount, 4, _T("this 0x%p, m_dwRef 0x% x\n"), this, m_dwRef);736 _Z4(atlTraceRefcount, 4, _T("this 0x%p, m_dwRef 0x%X\n"), this, m_dwRef); 730 737 } 731 738 HRESULT InternalQueryFilterGraph3Interface(REFIID InterfaceIdentifier, VOID** ppvObject) … … 807 814 #pragma region Instantiation 808 815 { 809 { const ULONG nAddRefCount = pControllingUnknown.p->AddRef(); const ULONG nReleaseCount = pControllingUnknown.p->Release(); _Z5(atlTraceRefcount, 5, _T("m_dwRef 0x% x, AddRef %d, Release %d\n"), m_dwRef, nAddRefCount, nReleaseCount); }816 { const ULONG nAddRefCount = pControllingUnknown.p->AddRef(); const ULONG nReleaseCount = pControllingUnknown.p->Release(); _Z5(atlTraceRefcount, 5, _T("m_dwRef 0x%X, AddRef %d, Release %d\n"), m_dwRef, nAddRefCount, nReleaseCount); } 810 817 const CComPtr<IUnknown> pUnknown = CoCreateOriginalInstance(hModule, pControllingUnknown); 811 818 // NOTE: DirectShow FilterGraph is incorrectly implementing COM aggregation adding outer reference to interfaces queried from private IUnknown … … 826 833 pMediaEventEx.p->Release(); 827 834 #pragma region ROT Registration 828 { const ULONG nAddRefCount = pControllingUnknown.p->AddRef(); const ULONG nReleaseCount = pControllingUnknown.p->Release(); _Z5(atlTraceRefcount, 5, _T("m_dwRef 0x% x, AddRef %d, Release %d\n"), m_dwRef, nAddRefCount, nReleaseCount); }835 { const ULONG nAddRefCount = pControllingUnknown.p->AddRef(); const ULONG nReleaseCount = pControllingUnknown.p->Release(); _Z5(atlTraceRefcount, 5, _T("m_dwRef 0x%X, AddRef %d, Release %d\n"), m_dwRef, nAddRefCount, nReleaseCount); } 829 836 SetRunningFilterGraph(); 830 { const ULONG nAddRefCount = pControllingUnknown.p->AddRef(); const ULONG nReleaseCount = pControllingUnknown.p->Release(); _Z5(atlTraceRefcount, 5, _T("m_dwRef 0x% x, AddRef %d, Release %d\n"), m_dwRef, nAddRefCount, nReleaseCount); }837 { const ULONG nAddRefCount = pControllingUnknown.p->AddRef(); const ULONG nReleaseCount = pControllingUnknown.p->Release(); _Z5(atlTraceRefcount, 5, _T("m_dwRef 0x%X, AddRef %d, Release %d\n"), m_dwRef, nAddRefCount, nReleaseCount); } 831 838 #pragma endregion 832 839 m_pInnerUnknown = pUnknown; … … 905 912 VOID FinalRelease() 906 913 { 907 _Z5(atlTraceRefcount, 5, _T("m_dwRef 0x% x\n"), m_dwRef);914 _Z5(atlTraceRefcount, 5, _T("m_dwRef 0x%X\n"), m_dwRef); 908 915 _A(!m_pTemporaryUnknown); 909 916 const CComPtr<IUnknown> pControllingUnknown = GetControllingUnknown(); … … 1011 1018 1012 1019 // ISpy 1013 STDMETHOD(get_MonikerDisplayName)(BSTR* psMonikerDisplayName) 1020 STDMETHOD(get_MonikerDisplayName)(BSTR* psMonikerDisplayName) override 1014 1021 { 1015 1022 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); … … 1025 1032 return S_OK; 1026 1033 } 1027 STDMETHOD(get_CreationTime)(DATE* pfTime) 1034 STDMETHOD(get_CreationTime)(DATE* pfTime) override 1028 1035 { 1029 1036 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); … … 1045 1052 return S_OK; 1046 1053 } 1047 STDMETHOD(get_FriendlyName)(BSTR* psFriendlyName) 1054 STDMETHOD(get_FriendlyName)(BSTR* psFriendlyName) override 1048 1055 { 1049 1056 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); … … 1060 1067 return S_OK; 1061 1068 } 1062 STDMETHOD(put_FriendlyName)(BSTR sFriendlyName) 1069 STDMETHOD(put_FriendlyName)(BSTR sFriendlyName) override 1063 1070 { 1064 1071 _Z4(atlTraceCOM, 4, _T("this 0x%p, sFriendlyName \"%s\"\n"), this, CString(sFriendlyName)); … … 1074 1081 return S_OK; 1075 1082 } 1076 STDMETHOD(DoPropertyFrameModal)(LONG nParentWindowHandle) 1083 STDMETHOD(DoPropertyFrameModal)(LONG nParentWindowHandle) override 1077 1084 { 1078 1085 _Z4(atlTraceCOM, 4, _T("this 0x%p, nParentWindowHandle 0x%08X\n"), this, nParentWindowHandle); … … 1088 1095 return S_OK; 1089 1096 } 1090 STDMETHOD(DoFilterGraphListModal)(LONG nParentWindowHandle) 1097 STDMETHOD(DoFilterGraphListModal)(LONG nParentWindowHandle) override 1091 1098 { 1092 1099 _Z4(atlTraceCOM, 4, _T("this 0x%p, nParentWindowHandle 0x%08X\n"), this, nParentWindowHandle); … … 1101 1108 return S_OK; 1102 1109 } 1103 STDMETHOD(OpenGraphStudioNext)(LONG nParentWindowHandle, VARIANT_BOOL* pbResult) 1110 STDMETHOD(OpenGraphStudioNext)(LONG nParentWindowHandle, VARIANT_BOOL* pbResult) override 1104 1111 { 1105 1112 _Z4(atlTraceCOM, 4, _T("this 0x%p, nParentWindowHandle 0x%08X\n"), this, nParentWindowHandle); … … 1114 1121 return S_OK; 1115 1122 } 1116 STDMETHOD(OpenGraphEdit)(LONG nParentWindowHandle, VARIANT_BOOL* pbResult) 1123 STDMETHOD(OpenGraphEdit)(LONG nParentWindowHandle, VARIANT_BOOL* pbResult) override 1117 1124 { 1118 1125 _Z4(atlTraceCOM, 4, _T("this 0x%p, nParentWindowHandle 0x%08X\n"), this, nParentWindowHandle); … … 1127 1134 return S_OK; 1128 1135 } 1129 STDMETHOD(ReadRunPropertyBag)(IUnknown* pBaseFilterUnknown, VARIANT_BOOL bAllowExtension, VARIANT* pvValue) 1136 STDMETHOD(ReadRunPropertyBag)(IUnknown* pBaseFilterUnknown, VARIANT_BOOL bAllowExtension, VARIANT* pvValue) override 1130 1137 { 1131 1138 _Z4(atlTraceCOM, 4, _T("this 0x%p, pBaseFilterUnknown 0x%p, bAllowExtension %d\n"), this, pBaseFilterUnknown, bAllowExtension); … … 1143 1150 return S_OK; 1144 1151 } 1145 STDMETHOD(CreateMediaSampleTrace)(IMediaSampleTrace** ppMediaSampleTrace) 1152 STDMETHOD(CreateMediaSampleTrace)(IMediaSampleTrace** ppMediaSampleTrace) override 1146 1153 { 1147 1154 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); … … 1164 1171 1165 1172 // IFilterGraph 1166 STDMETHOD(AddFilter)(IBaseFilter* pBaseFilter, LPCWSTR pszName) 1173 STDMETHOD(AddFilter)(IBaseFilter* pBaseFilter, LPCWSTR pszName) override 1167 1174 { 1168 1175 _Z4(atlTraceCOM, 4, _T("this 0x%p, pBaseFilter 0x%p %ls, pszName \"%s\"\n"), this, pBaseFilter, _FilterGraphHelper::GetFilterClassIdentifierString(pBaseFilter), CString(pszName)); … … 1184 1191 return nResult; 1185 1192 } 1186 STDMETHOD(RemoveFilter)(IBaseFilter* pBaseFilter) 1193 STDMETHOD(RemoveFilter)(IBaseFilter* pBaseFilter) override 1187 1194 { 1188 1195 _Z4(atlTraceCOM, 4, _T("this 0x%p, pBaseFilter 0x%p\n"), this, pBaseFilter); … … 1202 1209 return m_pInnerFilterGraph2->RemoveFilter(pBaseFilter); 1203 1210 } 1204 STDMETHOD(EnumFilters)(IEnumFilters** ppEnumFilters) 1205 { 1206 _Z4(atlTraceCOM, 4, _T(" ...\n"));1211 STDMETHOD(EnumFilters)(IEnumFilters** ppEnumFilters) override 1212 { 1213 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); 1207 1214 return m_pInnerFilterGraph2->EnumFilters(ppEnumFilters); 1208 1215 } 1209 STDMETHOD(FindFilterByName)(LPCWSTR pszName, IBaseFilter** ppFilter) 1210 { 1211 _Z4(atlTraceCOM, 4, _T(" pszName \"%s\"\n"), CString(pszName));1216 STDMETHOD(FindFilterByName)(LPCWSTR pszName, IBaseFilter** ppFilter) override 1217 { 1218 _Z4(atlTraceCOM, 4, _T("this 0x%p, pszName \"%s\"\n"), this, CString(pszName)); 1212 1219 return m_pInnerFilterGraph2->FindFilterByName(pszName, ppFilter); 1213 1220 } 1214 STDMETHOD(ConnectDirect)(IPin* pOutputPin, IPin* pInputPin, const AM_MEDIA_TYPE* pMediaType) 1215 { 1216 _Z4(atlTraceCOM, 4, _T(" ...\n"));1221 STDMETHOD(ConnectDirect)(IPin* pOutputPin, IPin* pInputPin, const AM_MEDIA_TYPE* pMediaType) override 1222 { 1223 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); 1217 1224 if(pOutputPin && pInputPin) 1218 1225 _ATLTRY … … 1266 1273 return nConnectDirectResult; 1267 1274 } 1268 STDMETHOD(Reconnect)(IPin* pPin) 1269 { 1270 _Z4(atlTraceCOM, 4, _T(" ...\n"));1275 STDMETHOD(Reconnect)(IPin* pPin) override 1276 { 1277 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); 1271 1278 HOOK_PROLOG(CFilterGraphConnectHookHost) 1272 1279 OnReconnect(pT, pPin, &bDefault); … … 1274 1281 return m_pInnerFilterGraph2->Reconnect(pPin); 1275 1282 } 1276 STDMETHOD(Disconnect)(IPin* pPin) 1277 { 1278 _Z4(atlTraceCOM, 4, _T(" ...\n"));1283 STDMETHOD(Disconnect)(IPin* pPin) override 1284 { 1285 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); 1279 1286 HOOK_PROLOG(CFilterGraphConnectHookHost) 1280 1287 OnDisconnect(pT, pPin, &bDefault); … … 1282 1289 return m_pInnerFilterGraph2->Disconnect(pPin); 1283 1290 } 1284 STDMETHOD(SetDefaultSyncSource)() 1285 { 1286 _Z4(atlTraceCOM, 4, _T(" ...\n"));1291 STDMETHOD(SetDefaultSyncSource)() override 1292 { 1293 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); 1287 1294 return m_pInnerFilterGraph2->SetDefaultSyncSource(); 1288 1295 } 1289 1296 1290 1297 // IGraphBuilder 1291 STDMETHOD(Connect)(IPin* pOutputPin, IPin* pInputPin) 1292 { 1293 _Z4(atlTraceCOM, 4, _T(" pOutputPin 0x%p, pInputPin 0x%p\n"), pOutputPin, pInputPin);1298 STDMETHOD(Connect)(IPin* pOutputPin, IPin* pInputPin) override 1299 { 1300 _Z4(atlTraceCOM, 4, _T("this 0x%p, pOutputPin 0x%p, pInputPin 0x%p\n"), this, pOutputPin, pInputPin); 1294 1301 if(pOutputPin && pInputPin) 1295 1302 _ATLTRY 1296 1303 { 1297 _Z4(atlTraceGeneral, 4, _T(" this 0x%p, pOutputPin 0x%p \"%ls\" (filter 0x%p), pInputPin 0x%p \"%ls\" (filter 0x%p)\n"), this,1304 _Z4(atlTraceGeneral, 4, _T("pOutputPin 0x%p \"%ls\" (filter 0x%p), pInputPin 0x%p \"%ls\" (filter 0x%p)\n"), 1298 1305 pOutputPin, _FilterGraphHelper::GetPinFullName(pOutputPin), _FilterGraphHelper::GetPinFilter(pOutputPin), 1299 1306 pInputPin, _FilterGraphHelper::GetPinFullName(pInputPin), _FilterGraphHelper::GetPinFilter(pInputPin), … … 1311 1318 return nConnectResult; 1312 1319 } 1313 STDMETHOD(Render)(IPin* pOutputPin) 1314 { 1315 _Z4(atlTraceCOM, 4, _T(" ...\n"));1320 STDMETHOD(Render)(IPin* pOutputPin) override 1321 { 1322 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); 1316 1323 return m_pInnerFilterGraph2->Render(pOutputPin); 1317 1324 } 1318 STDMETHOD(RenderFile)(LPCWSTR pszFileName, LPCWSTR pszPlayListFileName) 1319 { 1320 _Z4(atlTraceCOM, 4, _T(" pszFileName \"%s\", pszPlayListFileName \"%s\"\n"), CString(pszFileName), CString(pszPlayListFileName));1325 STDMETHOD(RenderFile)(LPCWSTR pszFileName, LPCWSTR pszPlayListFileName) override 1326 { 1327 _Z4(atlTraceCOM, 4, _T("this 0x%p, pszFileName \"%s\", pszPlayListFileName \"%s\"\n"), this, CString(pszFileName), CString(pszPlayListFileName)); 1321 1328 return m_pInnerFilterGraph2->RenderFile(pszFileName, pszPlayListFileName); 1322 1329 } 1323 STDMETHOD(AddSourceFilter)(LPCWSTR pszFileName, LPCWSTR pszFilterName, IBaseFilter** ppBaseFilter) 1324 { 1325 _Z4(atlTraceCOM, 4, _T(" pszFileName \"%s\", pszFilterName \"%s\"\n"), CString(pszFileName), CString(pszFilterName));1330 STDMETHOD(AddSourceFilter)(LPCWSTR pszFileName, LPCWSTR pszFilterName, IBaseFilter** ppBaseFilter) override 1331 { 1332 _Z4(atlTraceCOM, 4, _T("this 0x%p, pszFileName \"%s\", pszFilterName \"%s\"\n"), this, CString(pszFileName), CString(pszFilterName)); 1326 1333 ReleaseTemporaryUnknown(); 1327 1334 HOOK_PROLOG(CFilterGraphAddRemoveHookHost) … … 1330 1337 return m_pInnerFilterGraph2->AddSourceFilter(pszFileName, pszFilterName, ppBaseFilter); 1331 1338 } 1332 STDMETHOD(SetLogFile)(DWORD_PTR hFile) 1333 { 1334 _Z4(atlTraceCOM, 4, _T(" ...\n"));1339 STDMETHOD(SetLogFile)(DWORD_PTR hFile) override 1340 { 1341 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); 1335 1342 return m_pInnerFilterGraph2->SetLogFile(hFile); 1336 1343 } 1337 STDMETHOD(Abort)() 1338 { 1339 _Z4(atlTraceCOM, 4, _T(" ...\n"));1344 STDMETHOD(Abort)() override 1345 { 1346 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); 1340 1347 return m_pInnerFilterGraph2->Abort(); 1341 1348 } 1342 STDMETHOD(ShouldOperationContinue)() 1343 { 1344 _Z4(atlTraceCOM, 4, _T(" ...\n"));1349 STDMETHOD(ShouldOperationContinue)() override 1350 { 1351 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); 1345 1352 return m_pInnerFilterGraph2->ShouldOperationContinue(); 1346 1353 } 1347 1354 1348 1355 // IFilterGraph2 1349 STDMETHOD(AddSourceFilterForMoniker)(IMoniker* pMoniker, IBindCtx* pBindCtx, LPCWSTR pszFilterName, IBaseFilter** ppBaseFilter) 1350 { 1351 _Z4(atlTraceCOM, 4, _T(" pszFilterName \"%s\"\n"), CString(pszFilterName));1356 STDMETHOD(AddSourceFilterForMoniker)(IMoniker* pMoniker, IBindCtx* pBindCtx, LPCWSTR pszFilterName, IBaseFilter** ppBaseFilter) override 1357 { 1358 _Z4(atlTraceCOM, 4, _T("this 0x%p, pszFilterName \"%s\"\n"), this, CString(pszFilterName)); 1352 1359 ReleaseTemporaryUnknown(); 1353 1360 HOOK_PROLOG(CFilterGraphAddRemoveHookHost) … … 1356 1363 return m_pInnerFilterGraph2->AddSourceFilterForMoniker(pMoniker, pBindCtx, pszFilterName, ppBaseFilter); 1357 1364 } 1358 STDMETHOD(ReconnectEx)(IPin* pPin, const AM_MEDIA_TYPE* pMediaType) 1359 { 1360 _Z4(atlTraceCOM, 4, _T(" ...\n"));1365 STDMETHOD(ReconnectEx)(IPin* pPin, const AM_MEDIA_TYPE* pMediaType) override 1366 { 1367 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); 1361 1368 HOOK_PROLOG(CFilterGraphConnectHookHost) 1362 1369 OnReconnectEx(pT, pPin, (const BYTE*) pMediaType, &bDefault); … … 1364 1371 return m_pInnerFilterGraph2->ReconnectEx(pPin, pMediaType); 1365 1372 } 1366 STDMETHOD(RenderEx)(IPin* pOutputPin, DWORD nFlags, DWORD* pnContext) 1367 { 1368 _Z4(atlTraceCOM, 4, _T(" nFlags 0x%x\n"), nFlags);1373 STDMETHOD(RenderEx)(IPin* pOutputPin, DWORD nFlags, DWORD* pnContext) override 1374 { 1375 _Z4(atlTraceCOM, 4, _T("this 0x%p, nFlags 0x%X\n"), this, nFlags); 1369 1376 return m_pInnerFilterGraph2->RenderEx(pOutputPin, nFlags, pnContext); 1370 1377 } 1371 1378 1372 1379 // IFilterGraph3 1373 STDMETHOD(SetSyncSourceEx)(IReferenceClock* pFilterGraphReferenceClock, IReferenceClock* pFilterReferenceClock, IBaseFilter* pBaseFilter) 1374 { 1375 _Z4(atlTraceCOM, 4, _T(" ...\n"));1380 STDMETHOD(SetSyncSourceEx)(IReferenceClock* pFilterGraphReferenceClock, IReferenceClock* pFilterReferenceClock, IBaseFilter* pBaseFilter) override 1381 { 1382 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); 1376 1383 _A(m_pInnerFilterGraph3); 1377 1384 return m_pInnerFilterGraph3->SetSyncSourceEx(pFilterGraphReferenceClock, pFilterReferenceClock, pBaseFilter); … … 1379 1386 1380 1387 // IMediaControl 1381 STDMETHOD(Run)() 1382 { 1383 _Z4(atlTraceCOM, 4, _T(" ...\n"));1388 STDMETHOD(Run)() override 1389 { 1390 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); 1384 1391 _ATLTRY 1385 1392 { … … 1399 1406 return nRunResult; 1400 1407 } 1401 STDMETHOD(Pause)() 1402 { 1403 _Z4(atlTraceCOM, 4, _T(" ...\n"));1408 STDMETHOD(Pause)() override 1409 { 1410 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); 1404 1411 _ATLTRY 1405 1412 { … … 1417 1424 return m_pInnerMediaControl->Pause(); 1418 1425 } 1419 STDMETHOD(Stop)() 1420 { 1421 _Z4(atlTraceCOM, 4, _T(" ...\n"));1426 STDMETHOD(Stop)() override 1427 { 1428 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); 1422 1429 HOOK_PROLOG(CFilterGraphStateControlHookHost) 1423 1430 OnStop(pT, &bDefault); … … 1425 1432 return m_pInnerMediaControl->Stop(); 1426 1433 } 1427 STDMETHOD(GetState)(LONG nTimeout, OAFilterState* pState) 1428 { 1429 _Z5(atlTraceCOM, 5, _T(" nTimeout %d\n"), nTimeout);1434 STDMETHOD(GetState)(LONG nTimeout, OAFilterState* pState) override 1435 { 1436 _Z5(atlTraceCOM, 5, _T("this 0x%p, nTimeout %d\n"), this, nTimeout); 1430 1437 return m_pInnerMediaControl->GetState(nTimeout, pState); 1431 1438 } 1432 STDMETHOD(RenderFile)(BSTR sFileName) 1433 { 1434 _Z4(atlTraceCOM, 4, _T(" sFileName \"%s\"\n"), CString(sFileName));1439 STDMETHOD(RenderFile)(BSTR sFileName) override 1440 { 1441 _Z4(atlTraceCOM, 4, _T("this 0x%p, sFileName \"%s\"\n"), this, CString(sFileName)); 1435 1442 return m_pInnerMediaControl->RenderFile(sFileName); 1436 1443 } 1437 STDMETHOD(AddSourceFilter)(BSTR sFileName, IDispatch** ppDispatch) 1438 { 1439 _Z4(atlTraceCOM, 4, _T(" sFileName \"%s\"\n"), CString(sFileName));1444 STDMETHOD(AddSourceFilter)(BSTR sFileName, IDispatch** ppDispatch) override 1445 { 1446 _Z4(atlTraceCOM, 4, _T("this 0x%p, sFileName \"%s\"\n"), this, CString(sFileName)); 1440 1447 ReleaseTemporaryUnknown(); 1441 1448 _ATLTRY … … 1463 1470 return m_pInnerMediaControl->AddSourceFilter(sFileName, ppDispatch); 1464 1471 } 1465 STDMETHOD(get_FilterCollection)(IDispatch** ppDispatch) 1466 { 1467 _Z4(atlTraceCOM, 4, _T(" ...\n"));1472 STDMETHOD(get_FilterCollection)(IDispatch** ppDispatch) override 1473 { 1474 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); 1468 1475 ReleaseTemporaryUnknown(); 1469 1476 return m_pInnerMediaControl->get_FilterCollection(ppDispatch); 1470 1477 } 1471 STDMETHOD(get_RegFilterCollection)(IDispatch** ppDispatch) 1472 { 1473 _Z4(atlTraceCOM, 4, _T(" ...\n"));1478 STDMETHOD(get_RegFilterCollection)(IDispatch** ppDispatch) override 1479 { 1480 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); 1474 1481 ReleaseTemporaryUnknown(); 1475 1482 return m_pInnerMediaControl->get_RegFilterCollection(ppDispatch); 1476 1483 } 1477 STDMETHOD(StopWhenReady)() 1478 { 1479 _Z4(atlTraceCOM, 4, _T(" ...\n"));1484 STDMETHOD(StopWhenReady)() override 1485 { 1486 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); 1480 1487 return m_pInnerMediaControl->StopWhenReady(); 1481 1488 } 1482 1489 1483 1490 // IMediaEventSink 1484 STDMETHOD(Notify)(LONG nEventCode, LONG_PTR nParameter1, LONG_PTR nParameter2) 1485 { 1486 _Z4(atlTraceCOM, 4, _T("nEventCode %s, nParameter1 0x%p, nParameter2 0x%p\n"), _FilterGraphHelper::FormatEventCode(nEventCode), nParameter1, nParameter2); 1487 //#if defined(_M_IX86) 1488 // WARN: Guarding section around might be preventing from walking frame up the stack 1489 // WARN: No guarding section however might cause hosting application crash, within RtlCaptureContext API unfortunately 1490 if(nEventCode == EC_ERRORABORT) // || nEventCode == EC_VIDEO_SIZE_CHANGED) 1491 _ATLTRY 1491 STDMETHOD(Notify)(LONG nEventCode, LONG_PTR nParameter1, LONG_PTR nParameter2) override 1492 { 1493 _Z4(atlTraceCOM, 4, _T("this 0x%p, nEventCode %s, nParameter1 0x%p, nParameter2 0x%p\n"), this, _FilterGraphHelper::FormatEventCode(nEventCode), nParameter1, nParameter2); 1494 #pragma region EC_COMPLETE 1495 if(nEventCode == EC_COMPLETE) 1496 _ATLTRY 1497 { 1498 IBaseFilter* pBaseFilter = (IBaseFilter*) nParameter2; 1499 if(pBaseFilter) 1492 1500 { 1493 CONTEXT ThreadContext = { CONTEXT_FULL }; 1494 GetCurrentThreadContext(&ThreadContext); 1495 CDebugTraceCallStack::TraceCallStack(ThreadContext, 32); //(nEventCode == EC_ERRORABORT) ? 32 : 8); 1501 const CStringW sName = _FilterGraphHelper::GetFilterName(pBaseFilter); 1502 _Z3(atlTraceCOM, 3, _T("Received EC_COMPLETE from filter 0x%p \"%ls\"\n"), pBaseFilter, sName); 1496 1503 } 1497 _ATLCATCHALL() 1498 { 1499 _Z_EXCEPTION(); 1500 } 1501 if(nEventCode == EC_COMPLETE) 1502 _ATLTRY 1503 { 1504 IBaseFilter* pBaseFilter = (IBaseFilter*) nParameter2; 1505 if(pBaseFilter) 1506 { 1507 const CStringW sName = _FilterGraphHelper::GetFilterName(pBaseFilter); 1508 _Z3(atlTraceCOM, 3, _T("Received EC_COMPLETE from filter 0x%p \"%ls\"\n"), pBaseFilter, sName); 1509 } 1510 } 1511 _ATLCATCHALL() 1512 { 1513 _Z_EXCEPTION(); 1514 } 1515 //#endif // defined(_M_IX86) 1504 //TCHAR pszComment[64]; 1505 //_stprintf_s(pszComment, _T("DirectShow-Complete-0x%08X"), (HRESULT) nParameter1); 1506 //TryWriteMiniDump(pszComment); 1507 } 1508 _ATLCATCHALL() 1509 { 1510 _Z_EXCEPTION(); 1511 } 1512 #pragma endregion 1513 #pragma region EC_ERRORABORT, EC_ERRORABORTEX 1514 if(nEventCode == EC_ERRORABORT || nEventCode == EC_ERRORABORTEX) 1515 { 1516 if(nEventCode == EC_ERRORABORTEX && nParameter2) 1517 _Z4(atlTraceGeneral, 4, _T("nParameter2 \"%s\"\n"), CString((BSTR) nParameter2)); 1518 static CConstIntegerRegistryValue g_nErrorAbortMiniDumpMode(_T("ErrorAbort MiniDump Mode")); // 0 Default (=1), 1 Disabled, 2 Enabled 1519 if((DWORD) g_nErrorAbortMiniDumpMode == 2) // Enabled 1520 { 1521 TCHAR pszComment[64]; 1522 _stprintf_s(pszComment, _T("DirectShow-ErrorAbort-0x%08X"), (HRESULT) nParameter1); 1523 static LONG g_nCounter = 0; 1524 TryWriteMiniDump(pszComment, &g_nCounter); 1525 } 1526 } 1527 #pragma endregion 1516 1528 if(!m_pInnerMediaEventSink) 1517 1529 return S_FALSE; … … 1520 1532 1521 1533 // IMediaEvent 1522 STDMETHOD(GetEventHandle)(OAEVENT* pnEventHandle) 1523 { 1524 _Z4(atlTraceCOM, 4, _T(" ...\n"));1534 STDMETHOD(GetEventHandle)(OAEVENT* pnEventHandle) override 1535 { 1536 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); 1525 1537 return m_pInnerMediaEventEx->GetEventHandle(pnEventHandle); 1526 1538 } 1527 STDMETHOD(GetEvent)(LONG* pnEventCode, LONG_PTR* pnParameter1, LONG_PTR* pnParameter2, LONG nTimeout) 1528 { 1529 _Z4(atlTraceCOM, nTimeout ? 4 : 5, _T(" nTimeout %d\n"), nTimeout);1539 STDMETHOD(GetEvent)(LONG* pnEventCode, LONG_PTR* pnParameter1, LONG_PTR* pnParameter2, LONG nTimeout) override 1540 { 1541 _Z4(atlTraceCOM, nTimeout ? 4 : 5, _T("this 0x%p, nTimeout %d\n"), this, nTimeout); 1530 1542 const HRESULT nGetEventResult = m_pInnerMediaEventEx->GetEvent(pnEventCode, pnParameter1, pnParameter2, nTimeout); 1531 1543 if(pnEventCode && pnParameter1 && pnParameter2) … … 1533 1545 return nGetEventResult; 1534 1546 } 1535 STDMETHOD(WaitForCompletion)(LONG nTimeout, LONG* pnEventCode) 1536 { 1537 _Z4(atlTraceCOM, 4, _T(" nTimeout %d\n"), nTimeout);1547 STDMETHOD(WaitForCompletion)(LONG nTimeout, LONG* pnEventCode) override 1548 { 1549 _Z4(atlTraceCOM, 4, _T("this 0x%p, nTimeout %d\n"), this, nTimeout); 1538 1550 const HRESULT nWaitForCompletionResult = m_pInnerMediaEventEx->WaitForCompletion(nTimeout, pnEventCode); 1539 1551 if(pnEventCode) … … 1541 1553 return nWaitForCompletionResult; 1542 1554 } 1543 STDMETHOD(CancelDefaultHandling)(LONG nEventCode) 1544 { 1545 _Z4(atlTraceCOM, 4, _T(" nEventCode %s\n"), _FilterGraphHelper::FormatEventCode(nEventCode));1555 STDMETHOD(CancelDefaultHandling)(LONG nEventCode) override 1556 { 1557 _Z4(atlTraceCOM, 4, _T("this 0x%p, nEventCode %s\n"), this, _FilterGraphHelper::FormatEventCode(nEventCode)); 1546 1558 return m_pInnerMediaEventEx->CancelDefaultHandling(nEventCode); 1547 1559 } 1548 STDMETHOD(RestoreDefaultHandling)(LONG nEventCode) 1549 { 1550 _Z4(atlTraceCOM, 4, _T(" nEventCode %s\n"), _FilterGraphHelper::FormatEventCode(nEventCode));1560 STDMETHOD(RestoreDefaultHandling)(LONG nEventCode) override 1561 { 1562 _Z4(atlTraceCOM, 4, _T("this 0x%p, nEventCode %s\n"), this, _FilterGraphHelper::FormatEventCode(nEventCode)); 1551 1563 return m_pInnerMediaEventEx->RestoreDefaultHandling(nEventCode); 1552 1564 } 1553 STDMETHOD(FreeEventParams)(LONG nEventCode, LONG_PTR nParameter1, LONG_PTR nParameter2) 1554 { 1555 _Z4(atlTraceCOM, 4, _T(" nEventCode %s, nParameter1 0x%p, nParameter2 0x%p\n"), _FilterGraphHelper::FormatEventCode(nEventCode), nParameter1, nParameter2);1565 STDMETHOD(FreeEventParams)(LONG nEventCode, LONG_PTR nParameter1, LONG_PTR nParameter2) override 1566 { 1567 _Z4(atlTraceCOM, 4, _T("this 0x%p, nEventCode %s, nParameter1 0x%p, nParameter2 0x%p\n"), this, _FilterGraphHelper::FormatEventCode(nEventCode), nParameter1, nParameter2); 1556 1568 return m_pInnerMediaEventEx->FreeEventParams(nEventCode, nParameter1, nParameter2); 1557 1569 } 1558 1570 1559 1571 // IMediaEventEx 1560 STDMETHOD(SetNotifyWindow)(OAHWND nWindowHandle, LONG nMessage, LONG_PTR nParameter) 1561 { 1562 _Z4(atlTraceCOM, 4, _T(" nWindowHandle 0x%08X, nMessage 0x%04x, nParameter %p\n"), nWindowHandle, nMessage, nParameter);1572 STDMETHOD(SetNotifyWindow)(OAHWND nWindowHandle, LONG nMessage, LONG_PTR nParameter) override 1573 { 1574 _Z4(atlTraceCOM, 4, _T("this 0x%p, nWindowHandle 0x%08X, nMessage 0x%04x, nParameter %p\n"), this, nWindowHandle, nMessage, nParameter); 1563 1575 return m_pInnerMediaEventEx->SetNotifyWindow(nWindowHandle, nMessage, nParameter); 1564 1576 } 1565 STDMETHOD(SetNotifyFlags)(LONG nNotifyFlags) 1566 { 1567 _Z4(atlTraceCOM, 4, _T(" nNotifyFlags 0x%x\n"), nNotifyFlags);1577 STDMETHOD(SetNotifyFlags)(LONG nNotifyFlags) override 1578 { 1579 _Z4(atlTraceCOM, 4, _T("this 0x%p, nNotifyFlags 0x%X\n"), this, nNotifyFlags); 1568 1580 return m_pInnerMediaEventEx->SetNotifyFlags(nNotifyFlags); 1569 1581 } 1570 STDMETHOD(GetNotifyFlags)(LONG* pnNotifyFlags) 1571 { 1572 _Z4(atlTraceCOM, 4, _T(" ...\n"));1582 STDMETHOD(GetNotifyFlags)(LONG* pnNotifyFlags) override 1583 { 1584 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); 1573 1585 return m_pInnerMediaEventEx->GetNotifyFlags(pnNotifyFlags); 1574 1586 } 1575 1587 1576 1588 // IObjectWithSite 1577 STDMETHOD(SetSite)(IUnknown* pSite) 1578 { 1579 _Z4(atlTraceCOM, 4, _T(" pSite 0x%p\n"), pSite);1589 STDMETHOD(SetSite)(IUnknown* pSite) override 1590 { 1591 _Z4(atlTraceCOM, 4, _T("this 0x%p, pSite 0x%p\n"), this, pSite); 1580 1592 _ATLTRY 1581 1593 { … … 1589 1601 return S_OK; 1590 1602 } 1591 STDMETHOD(GetSite)(REFIID InterfaceIdentifier, VOID** ppvSite) 1592 { 1593 _Z4(atlTraceCOM, 4, _T(" InterfaceIdentifier %ls\n"), _PersistHelper::StringFromInterfaceIdentifier(InterfaceIdentifier));1603 STDMETHOD(GetSite)(REFIID InterfaceIdentifier, VOID** ppvSite) override 1604 { 1605 _Z4(atlTraceCOM, 4, _T("this 0x%p, InterfaceIdentifier %ls\n"), this, _PersistHelper::StringFromInterfaceIdentifier(InterfaceIdentifier)); 1594 1606 _ATLTRY 1595 1607 { -
trunk/DirectShowSpy/FilterGraphTable.h
r545 r831 21 21 //////////////////////////////////////////////////////////// 22 22 // CFilterGraphTableBase 23 24 // NOTE: Exclude from legacy Windows XP toolset builds 25 26 #if NTDDI_VERSION > 0x06010000 // NTDDI_WIN7 27 28 #define AVAILABILITY_FILTERGRAPHTABLE 23 29 24 30 class CFilterGraphTableBase … … 773 779 774 780 OBJECT_ENTRY_AUTO(__uuidof(FilterGraphTable), CFilterGraphTable) 781 782 #endif // NTDDI_VERSION -
trunk/DirectShowSpy/GraphBuilderCallbackPropertySheet.h
r432 r831 1337 1337 { 1338 1338 if(!_tcslen(m_sPath)) 1339 m_sPath = CDebugTraceBase::GetLocalMachineFilePath(); 1339 { 1340 const CPath sDirectory = CDebugTraceBase::GetLocalMachineDirectory(); 1341 CDebugTraceData Data; 1342 Data.Configure(sDirectory, _T(""), _T("")); 1343 Data.CreateLogFilePath(sDirectory); 1344 m_sPath = Data.m_pszFilePath; 1345 } 1340 1346 #if _DEVELOPMENT && FALSE 1341 1347 static LPCTSTR g_pszPath = _T("D:\\Projects\\A&H\\LuxRiot\\_Issues\\45 Sanyo XP Issues\\DirectShowSpy.log"); -
trunk/DirectShowSpy/Host01/Host01.vcxproj
r763 r831 1 1 <?xml version="1.0" encoding="utf-8"?> 2 <Project DefaultTargets="Build" ToolsVersion="1 4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">2 <Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> 3 3 <ItemGroup Label="ProjectConfigurations"> 4 4 <ProjectConfiguration Include="Debug|Win32"> … … 23 23 <Keyword>Win32Proj</Keyword> 24 24 <RootNamespace>Host01</RootNamespace> 25 <WindowsTargetPlatformVersion>10.0.16299.0</WindowsTargetPlatformVersion> 25 26 </PropertyGroup> 26 27 <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /> … … 28 29 <ConfigurationType>Application</ConfigurationType> 29 30 <UseDebugLibraries>true</UseDebugLibraries> 30 <PlatformToolset>v14 0</PlatformToolset>31 <PlatformToolset>v141</PlatformToolset> 31 32 <CharacterSet>Unicode</CharacterSet> 32 33 </PropertyGroup> … … 34 35 <ConfigurationType>Application</ConfigurationType> 35 36 <UseDebugLibraries>true</UseDebugLibraries> 36 <PlatformToolset>v14 0</PlatformToolset>37 <PlatformToolset>v141</PlatformToolset> 37 38 <CharacterSet>Unicode</CharacterSet> 38 39 </PropertyGroup> … … 40 41 <ConfigurationType>Application</ConfigurationType> 41 42 <UseDebugLibraries>false</UseDebugLibraries> 42 <PlatformToolset>v14 0</PlatformToolset>43 <PlatformToolset>v141</PlatformToolset> 43 44 <WholeProgramOptimization>true</WholeProgramOptimization> 44 45 <CharacterSet>Unicode</CharacterSet> … … 47 48 <ConfigurationType>Application</ConfigurationType> 48 49 <UseDebugLibraries>false</UseDebugLibraries> 49 <PlatformToolset>v14 0</PlatformToolset>50 <PlatformToolset>v141</PlatformToolset> 50 51 <WholeProgramOptimization>true</WholeProgramOptimization> 51 52 <CharacterSet>Unicode</CharacterSet> -
trunk/DirectShowSpy/Module.cpp
r376 r831 87 87 return nResult; 88 88 } 89 90 #if defined(AVAILABILITY_INTERNALWRITEMINIDUMP) 91 #if defined(_WIN64) 92 #pragma comment(linker, "/EXPORT:WriteMiniDump,PRIVATE") 93 #else 94 #pragma comment(linker, "/EXPORT:WriteMiniDump=_WriteMiniDump@16,PRIVATE") 95 extern "C" // __declspec(dllexport) 96 #endif 97 extern "C" STDAPI WriteMiniDump(HWND hParentWindow, HINSTANCE hInstance, LPSTR pszCommandLine, INT nShowCommand) 98 { 99 return InternalWriteMiniDump(hParentWindow, hInstance, pszCommandLine, nShowCommand); 100 } 101 #endif // defined(AVAILABILITY_INTERNALWRITEMINIDUMP) -
trunk/DirectShowSpy/dllmain.h
r376 r831 35 35 TraceModuleVersion(); 36 36 _Z4_THIS(); 37 _W(CExceptionFilter::Initialize());37 //_W(CExceptionFilter::Initialize()); 38 38 } 39 39 ~CDirectShowSpyModule() throw() -
trunk/DirectShowSpy/targetver.h
r763 r831 16 16 #pragma once 17 17 18 #include <winsdkver.h> 18 19 #include <sdkddkver.h> 19 #include <winsdkver.h>20 20
Note: See TracChangeset
for help on using the changeset viewer.