- Timestamp:
- Jul 7, 2013, 10:58:51 AM (10 years ago)
- Location:
- trunk/DirectShowSpy
- Files:
-
- 2 added
- 12 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/DirectShowSpy
- Property svn:global-ignores
-
old new 1 1 ipch 2 _Archive
-
- Property svn:global-ignores
-
trunk/DirectShowSpy/DirectShowSpy.idl
r193 r199 41 41 interface ISystemDeviceEnumeratorSpy : IDispatch 42 42 { 43 }; 44 [ 45 object, 46 uuid(3D1AF248-DEF1-4E26-A071-FEDF15FED6A8), 47 dual, 48 oleautomation, 49 nonextensible, 50 helpstring("IFilterGraphHelper Interface"), 51 pointer_default(unique) 52 ] 53 interface IFilterGraphHelper : IDispatch 54 { 55 [id(DISPID_VALUE), propget] HRESULT FilterGraph([out, retval] IUnknown** ppFilterGraphUnknown); 56 [id(DISPID_VALUE), propput] HRESULT FilterGraph([in] IUnknown* pFilterGraphUnknown); 57 [id(1), propget] HRESULT Text([out, retval] BSTR* psText); 43 58 }; 44 59 [ … … 124 139 [default] interface ISystemDeviceEnumeratorSpy; 125 140 }; 141 [ 142 uuid(5A9A684C-A891-4032-8D31-FF6EAB5A0C1E), 143 helpstring("FilterGraphHelper Class") 144 ] 145 coclass FilterGraphHelper 146 { 147 [default] interface IFilterGraphHelper; 148 }; 126 149 }; -
trunk/DirectShowSpy/DirectShowSpy.rc
r198 r199 60 60 61 61 VS_VERSION_INFO VERSIONINFO 62 FILEVERSION 1, 0, 0, 9 5462 FILEVERSION 1, 0, 0, 974 63 63 PRODUCTVERSION 1,0,0,1 64 64 FILEFLAGSMASK 0x3fL … … 79 79 VALUE "CompanyName", "Roman Ryltsov" 80 80 VALUE "FileDescription", "Alax.Info DirectShow Spy Module" 81 VALUE "FileVersion", "1, 0, 0, 9 54\0"81 VALUE "FileVersion", "1, 0, 0, 974\0" 82 82 VALUE "InternalName", "DirectShowSpy.dll" 83 83 VALUE "LegalCopyright", "Copyright © Alax.Info, Roman Ryltsov, 2008-2013" … … 105 105 IDR_FILTERMAPPERSPY REGISTRY "GenericClass.rgs" 106 106 IDR_SYSTEMDEVICEENUMERATORSPY REGISTRY "GenericClass.rgs" 107 IDR_FILTERGRAPHHELPER REGISTRY "GenericClass.rgs" 107 108 108 109 ///////////////////////////////////////////////////////////////////////////// … … 301 302 IDR_SYSTEMDEVICEENUMERATORSPY 302 303 "\n\nAlax.Info DirectShow System Device Enumerator Spy\n" 304 IDR_FILTERGRAPHHELPER "AlaxInfo.DirectShowSpy.FilterGraphHelper\nAlaxInfo.DirectShowSpy.FilterGraphHelper.1\nAlax.Info DirectShow Filter Graph Helper\n" 303 305 END 304 306 -
trunk/DirectShowSpy/DirectShowSpy.vcxproj
r193 r199 409 409 </ClCompile> 410 410 <ClCompile Include="FilterGraphSpy.cpp" /> 411 <ClCompile Include="Helper.cpp" /> 411 412 <ClCompile Include="stdafx.cpp"> 412 413 <PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Create</PrecompiledHeader> … … 453 454 <ClInclude Include="Configuration.h" /> 454 455 <ClInclude Include="dllmain.h" /> 456 <ClInclude Include="FilterGraphHelper.h" /> 455 457 <ClInclude Include="FilterGraphList.h" /> 456 458 <ClInclude Include="FilterGraphSpy.h" /> -
trunk/DirectShowSpy/DirectShowSpy.vcxproj.filters
r193 r199 37 37 <ClCompile Include="DirectShowSpy_i.c"> 38 38 <Filter>Generated Files</Filter> 39 </ClCompile> 40 <ClCompile Include="Helper.cpp"> 41 <Filter>Source Files</Filter> 39 42 </ClCompile> 40 43 </ItemGroup> … … 101 104 <Filter>Header Files</Filter> 102 105 </ClInclude> 106 <ClInclude Include="FilterGraphHelper.h"> 107 <Filter>Header Files</Filter> 108 </ClInclude> 103 109 </ItemGroup> 104 110 <ItemGroup> -
trunk/DirectShowSpy/DirectShowSpy_i.c
r198 r199 7 7 8 8 /* File created by MIDL compiler version 7.00.0555 */ 9 /* at Sun Jul 07 12:40:58 20139 /* at Sun Jul 07 20:56:18 2013 10 10 */ 11 11 /* Compiler settings for DirectShowSpy.idl: … … 77 77 78 78 79 MIDL_DEFINE_GUID(IID, IID_IFilterGraphHelper,0x3D1AF248,0xDEF1,0x4E26,0xA0,0x71,0xFE,0xDF,0x15,0xFE,0xD6,0xA8); 80 81 79 82 MIDL_DEFINE_GUID(IID, LIBID_AlaxInfoDirectShowSpy,0xB9EC374B,0x834B,0x4DA9,0xBF,0xB5,0xC1,0x87,0x2C,0xE7,0x36,0xFF); 80 83 … … 100 103 MIDL_DEFINE_GUID(CLSID, CLSID_SystemDeviceEnumeratorSpy,0xAD42E3BD,0x7B9B,0x4783,0x9D,0xA2,0x61,0xA9,0xAC,0xD0,0xD4,0xD2); 101 104 105 106 MIDL_DEFINE_GUID(CLSID, CLSID_FilterGraphHelper,0x5A9A684C,0xA891,0x4032,0x8D,0x31,0xFF,0x6E,0xAB,0x5A,0x0C,0x1E); 107 102 108 #undef MIDL_DEFINE_GUID 103 109 -
trunk/DirectShowSpy/DirectShowSpy_i.h
r198 r199 5 5 6 6 /* File created by MIDL compiler version 7.00.0555 */ 7 /* at Sun Jul 07 12:40:58 20137 /* at Sun Jul 07 20:56:18 2013 8 8 */ 9 9 /* Compiler settings for DirectShowSpy.idl: … … 64 64 65 65 66 #ifndef __IFilterGraphHelper_FWD_DEFINED__ 67 #define __IFilterGraphHelper_FWD_DEFINED__ 68 typedef interface IFilterGraphHelper IFilterGraphHelper; 69 #endif /* __IFilterGraphHelper_FWD_DEFINED__ */ 70 71 66 72 #ifndef __IFilterGraphAddRemoveHook_FWD_DEFINED__ 67 73 #define __IFilterGraphAddRemoveHook_FWD_DEFINED__ … … 128 134 129 135 #endif /* __SystemDeviceEnumeratorSpy_FWD_DEFINED__ */ 136 137 138 #ifndef __FilterGraphHelper_FWD_DEFINED__ 139 #define __FilterGraphHelper_FWD_DEFINED__ 140 141 #ifdef __cplusplus 142 typedef class FilterGraphHelper FilterGraphHelper; 143 #else 144 typedef struct FilterGraphHelper FilterGraphHelper; 145 #endif /* __cplusplus */ 146 147 #endif /* __FilterGraphHelper_FWD_DEFINED__ */ 130 148 131 149 … … 472 490 473 491 492 #ifndef __IFilterGraphHelper_INTERFACE_DEFINED__ 493 #define __IFilterGraphHelper_INTERFACE_DEFINED__ 494 495 /* interface IFilterGraphHelper */ 496 /* [unique][helpstring][nonextensible][oleautomation][dual][uuid][object] */ 497 498 499 EXTERN_C const IID IID_IFilterGraphHelper; 500 501 #if defined(__cplusplus) && !defined(CINTERFACE) 502 503 MIDL_INTERFACE("3D1AF248-DEF1-4E26-A071-FEDF15FED6A8") 504 IFilterGraphHelper : public IDispatch 505 { 506 public: 507 virtual /* [propget][id] */ HRESULT STDMETHODCALLTYPE get_FilterGraph( 508 /* [retval][out] */ IUnknown **ppFilterGraphUnknown) = 0; 509 510 virtual /* [propput][id] */ HRESULT STDMETHODCALLTYPE put_FilterGraph( 511 /* [in] */ IUnknown *pFilterGraphUnknown) = 0; 512 513 virtual /* [propget][id] */ HRESULT STDMETHODCALLTYPE get_Text( 514 /* [retval][out] */ BSTR *psText) = 0; 515 516 }; 517 518 #else /* C style interface */ 519 520 typedef struct IFilterGraphHelperVtbl 521 { 522 BEGIN_INTERFACE 523 524 HRESULT ( STDMETHODCALLTYPE *QueryInterface )( 525 IFilterGraphHelper * This, 526 /* [in] */ REFIID riid, 527 /* [annotation][iid_is][out] */ 528 __RPC__deref_out void **ppvObject); 529 530 ULONG ( STDMETHODCALLTYPE *AddRef )( 531 IFilterGraphHelper * This); 532 533 ULONG ( STDMETHODCALLTYPE *Release )( 534 IFilterGraphHelper * This); 535 536 HRESULT ( STDMETHODCALLTYPE *GetTypeInfoCount )( 537 IFilterGraphHelper * This, 538 /* [out] */ UINT *pctinfo); 539 540 HRESULT ( STDMETHODCALLTYPE *GetTypeInfo )( 541 IFilterGraphHelper * This, 542 /* [in] */ UINT iTInfo, 543 /* [in] */ LCID lcid, 544 /* [out] */ ITypeInfo **ppTInfo); 545 546 HRESULT ( STDMETHODCALLTYPE *GetIDsOfNames )( 547 IFilterGraphHelper * This, 548 /* [in] */ REFIID riid, 549 /* [size_is][in] */ LPOLESTR *rgszNames, 550 /* [range][in] */ UINT cNames, 551 /* [in] */ LCID lcid, 552 /* [size_is][out] */ DISPID *rgDispId); 553 554 /* [local] */ HRESULT ( STDMETHODCALLTYPE *Invoke )( 555 IFilterGraphHelper * This, 556 /* [in] */ DISPID dispIdMember, 557 /* [in] */ REFIID riid, 558 /* [in] */ LCID lcid, 559 /* [in] */ WORD wFlags, 560 /* [out][in] */ DISPPARAMS *pDispParams, 561 /* [out] */ VARIANT *pVarResult, 562 /* [out] */ EXCEPINFO *pExcepInfo, 563 /* [out] */ UINT *puArgErr); 564 565 /* [propget][id] */ HRESULT ( STDMETHODCALLTYPE *get_FilterGraph )( 566 IFilterGraphHelper * This, 567 /* [retval][out] */ IUnknown **ppFilterGraphUnknown); 568 569 /* [propput][id] */ HRESULT ( STDMETHODCALLTYPE *put_FilterGraph )( 570 IFilterGraphHelper * This, 571 /* [in] */ IUnknown *pFilterGraphUnknown); 572 573 /* [propget][id] */ HRESULT ( STDMETHODCALLTYPE *get_Text )( 574 IFilterGraphHelper * This, 575 /* [retval][out] */ BSTR *psText); 576 577 END_INTERFACE 578 } IFilterGraphHelperVtbl; 579 580 interface IFilterGraphHelper 581 { 582 CONST_VTBL struct IFilterGraphHelperVtbl *lpVtbl; 583 }; 584 585 586 587 #ifdef COBJMACROS 588 589 590 #define IFilterGraphHelper_QueryInterface(This,riid,ppvObject) \ 591 ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) 592 593 #define IFilterGraphHelper_AddRef(This) \ 594 ( (This)->lpVtbl -> AddRef(This) ) 595 596 #define IFilterGraphHelper_Release(This) \ 597 ( (This)->lpVtbl -> Release(This) ) 598 599 600 #define IFilterGraphHelper_GetTypeInfoCount(This,pctinfo) \ 601 ( (This)->lpVtbl -> GetTypeInfoCount(This,pctinfo) ) 602 603 #define IFilterGraphHelper_GetTypeInfo(This,iTInfo,lcid,ppTInfo) \ 604 ( (This)->lpVtbl -> GetTypeInfo(This,iTInfo,lcid,ppTInfo) ) 605 606 #define IFilterGraphHelper_GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId) \ 607 ( (This)->lpVtbl -> GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId) ) 608 609 #define IFilterGraphHelper_Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr) \ 610 ( (This)->lpVtbl -> Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr) ) 611 612 613 #define IFilterGraphHelper_get_FilterGraph(This,ppFilterGraphUnknown) \ 614 ( (This)->lpVtbl -> get_FilterGraph(This,ppFilterGraphUnknown) ) 615 616 #define IFilterGraphHelper_put_FilterGraph(This,pFilterGraphUnknown) \ 617 ( (This)->lpVtbl -> put_FilterGraph(This,pFilterGraphUnknown) ) 618 619 #define IFilterGraphHelper_get_Text(This,psText) \ 620 ( (This)->lpVtbl -> get_Text(This,psText) ) 621 622 #endif /* COBJMACROS */ 623 624 625 #endif /* C style interface */ 626 627 628 629 630 #endif /* __IFilterGraphHelper_INTERFACE_DEFINED__ */ 631 632 474 633 475 634 #ifndef __AlaxInfoDirectShowSpy_LIBRARY_DEFINED__ … … 902 1061 SystemDeviceEnumeratorSpy; 903 1062 #endif 1063 1064 EXTERN_C const CLSID CLSID_FilterGraphHelper; 1065 1066 #ifdef __cplusplus 1067 1068 class DECLSPEC_UUID("5A9A684C-A891-4032-8D31-FF6EAB5A0C1E") 1069 FilterGraphHelper; 1070 #endif 904 1071 #endif /* __AlaxInfoDirectShowSpy_LIBRARY_DEFINED__ */ 905 1072 906 1073 /* Additional Prototypes for ALL interfaces */ 1074 1075 unsigned long __RPC_USER BSTR_UserSize( unsigned long *, unsigned long , BSTR * ); 1076 unsigned char * __RPC_USER BSTR_UserMarshal( unsigned long *, unsigned char *, BSTR * ); 1077 unsigned char * __RPC_USER BSTR_UserUnmarshal(unsigned long *, unsigned char *, BSTR * ); 1078 void __RPC_USER BSTR_UserFree( unsigned long *, BSTR * ); 907 1079 908 1080 /* end of Additional Prototypes */ -
trunk/DirectShowSpy/DirectShowSpy_p.c
r198 r199 5 5 6 6 /* File created by MIDL compiler version 7.00.0555 */ 7 /* at Sun Jul 07 12:40:58 20137 /* at Sun Jul 07 20:56:18 2013 8 8 */ 9 9 /* Compiler settings for DirectShowSpy.idl: … … 50 50 #include "DirectShowSpy_i.h" 51 51 52 #define TYPE_FORMAT_STRING_SIZE 353 #define PROC_FORMAT_STRING_SIZE 1 52 #define TYPE_FORMAT_STRING_SIZE 65 53 #define PROC_FORMAT_STRING_SIZE 109 54 54 #define EXPR_FORMAT_STRING_SIZE 1 55 55 #define TRANSMIT_AS_TABLE_SIZE 0 56 #define WIRE_MARSHAL_TABLE_SIZE 056 #define WIRE_MARSHAL_TABLE_SIZE 1 57 57 58 58 typedef struct _DirectShowSpy_MIDL_TYPE_FORMAT_STRING … … 105 105 106 106 107 extern const MIDL_STUB_DESC Object_StubDesc; 108 109 110 extern const MIDL_SERVER_INFO IFilterGraphHelper_ServerInfo; 111 extern const MIDL_STUBLESS_PROXY_INFO IFilterGraphHelper_ProxyInfo; 112 113 114 extern const USER_MARSHAL_ROUTINE_QUADRUPLE UserMarshalRoutines[ WIRE_MARSHAL_TABLE_SIZE ]; 107 115 108 116 #if !defined(__RPC_WIN32__) … … 123 131 { 124 132 133 /* Procedure get_FilterGraph */ 134 135 0x33, /* FC_AUTO_HANDLE */ 136 0x6c, /* Old Flags: object, Oi2 */ 137 /* 2 */ NdrFcLong( 0x0 ), /* 0 */ 138 /* 6 */ NdrFcShort( 0x7 ), /* 7 */ 139 /* 8 */ NdrFcShort( 0xc ), /* x86 Stack size/offset = 12 */ 140 /* 10 */ NdrFcShort( 0x0 ), /* 0 */ 141 /* 12 */ NdrFcShort( 0x8 ), /* 8 */ 142 /* 14 */ 0x45, /* Oi2 Flags: srv must size, has return, has ext, */ 143 0x2, /* 2 */ 144 /* 16 */ 0x8, /* 8 */ 145 0x1, /* Ext Flags: new corr desc, */ 146 /* 18 */ NdrFcShort( 0x0 ), /* 0 */ 147 /* 20 */ NdrFcShort( 0x0 ), /* 0 */ 148 /* 22 */ NdrFcShort( 0x0 ), /* 0 */ 149 150 /* Parameter ppFilterGraphUnknown */ 151 152 /* 24 */ NdrFcShort( 0x13 ), /* Flags: must size, must free, out, */ 153 /* 26 */ NdrFcShort( 0x4 ), /* x86 Stack size/offset = 4 */ 154 /* 28 */ NdrFcShort( 0x2 ), /* Type Offset=2 */ 155 156 /* Return value */ 157 158 /* 30 */ NdrFcShort( 0x70 ), /* Flags: out, return, base type, */ 159 /* 32 */ NdrFcShort( 0x8 ), /* x86 Stack size/offset = 8 */ 160 /* 34 */ 0x8, /* FC_LONG */ 161 0x0, /* 0 */ 162 163 /* Procedure put_FilterGraph */ 164 165 /* 36 */ 0x33, /* FC_AUTO_HANDLE */ 166 0x6c, /* Old Flags: object, Oi2 */ 167 /* 38 */ NdrFcLong( 0x0 ), /* 0 */ 168 /* 42 */ NdrFcShort( 0x8 ), /* 8 */ 169 /* 44 */ NdrFcShort( 0xc ), /* x86 Stack size/offset = 12 */ 170 /* 46 */ NdrFcShort( 0x0 ), /* 0 */ 171 /* 48 */ NdrFcShort( 0x8 ), /* 8 */ 172 /* 50 */ 0x46, /* Oi2 Flags: clt must size, has return, has ext, */ 173 0x2, /* 2 */ 174 /* 52 */ 0x8, /* 8 */ 175 0x1, /* Ext Flags: new corr desc, */ 176 /* 54 */ NdrFcShort( 0x0 ), /* 0 */ 177 /* 56 */ NdrFcShort( 0x0 ), /* 0 */ 178 /* 58 */ NdrFcShort( 0x0 ), /* 0 */ 179 180 /* Parameter pFilterGraphUnknown */ 181 182 /* 60 */ NdrFcShort( 0xb ), /* Flags: must size, must free, in, */ 183 /* 62 */ NdrFcShort( 0x4 ), /* x86 Stack size/offset = 4 */ 184 /* 64 */ NdrFcShort( 0x6 ), /* Type Offset=6 */ 185 186 /* Return value */ 187 188 /* 66 */ NdrFcShort( 0x70 ), /* Flags: out, return, base type, */ 189 /* 68 */ NdrFcShort( 0x8 ), /* x86 Stack size/offset = 8 */ 190 /* 70 */ 0x8, /* FC_LONG */ 191 0x0, /* 0 */ 192 193 /* Procedure get_Text */ 194 195 /* 72 */ 0x33, /* FC_AUTO_HANDLE */ 196 0x6c, /* Old Flags: object, Oi2 */ 197 /* 74 */ NdrFcLong( 0x0 ), /* 0 */ 198 /* 78 */ NdrFcShort( 0x9 ), /* 9 */ 199 /* 80 */ NdrFcShort( 0xc ), /* x86 Stack size/offset = 12 */ 200 /* 82 */ NdrFcShort( 0x0 ), /* 0 */ 201 /* 84 */ NdrFcShort( 0x8 ), /* 8 */ 202 /* 86 */ 0x45, /* Oi2 Flags: srv must size, has return, has ext, */ 203 0x2, /* 2 */ 204 /* 88 */ 0x8, /* 8 */ 205 0x3, /* Ext Flags: new corr desc, clt corr check, */ 206 /* 90 */ NdrFcShort( 0x1 ), /* 1 */ 207 /* 92 */ NdrFcShort( 0x0 ), /* 0 */ 208 /* 94 */ NdrFcShort( 0x0 ), /* 0 */ 209 210 /* Parameter psText */ 211 212 /* 96 */ NdrFcShort( 0x2113 ), /* Flags: must size, must free, out, simple ref, srv alloc size=8 */ 213 /* 98 */ NdrFcShort( 0x4 ), /* x86 Stack size/offset = 4 */ 214 /* 100 */ NdrFcShort( 0x36 ), /* Type Offset=54 */ 215 216 /* Return value */ 217 218 /* 102 */ NdrFcShort( 0x70 ), /* Flags: out, return, base type, */ 219 /* 104 */ NdrFcShort( 0x8 ), /* x86 Stack size/offset = 8 */ 220 /* 106 */ 0x8, /* FC_LONG */ 221 0x0, /* 0 */ 222 125 223 0x0 126 224 } … … 132 230 { 133 231 NdrFcShort( 0x0 ), /* 0 */ 232 /* 2 */ 233 0x11, 0x10, /* FC_RP [pointer_deref] */ 234 /* 4 */ NdrFcShort( 0x2 ), /* Offset= 2 (6) */ 235 /* 6 */ 236 0x2f, /* FC_IP */ 237 0x5a, /* FC_CONSTANT_IID */ 238 /* 8 */ NdrFcLong( 0x0 ), /* 0 */ 239 /* 12 */ NdrFcShort( 0x0 ), /* 0 */ 240 /* 14 */ NdrFcShort( 0x0 ), /* 0 */ 241 /* 16 */ 0xc0, /* 192 */ 242 0x0, /* 0 */ 243 /* 18 */ 0x0, /* 0 */ 244 0x0, /* 0 */ 245 /* 20 */ 0x0, /* 0 */ 246 0x0, /* 0 */ 247 /* 22 */ 0x0, /* 0 */ 248 0x46, /* 70 */ 249 /* 24 */ 250 0x11, 0x4, /* FC_RP [alloced_on_stack] */ 251 /* 26 */ NdrFcShort( 0x1c ), /* Offset= 28 (54) */ 252 /* 28 */ 253 0x13, 0x0, /* FC_OP */ 254 /* 30 */ NdrFcShort( 0xe ), /* Offset= 14 (44) */ 255 /* 32 */ 256 0x1b, /* FC_CARRAY */ 257 0x1, /* 1 */ 258 /* 34 */ NdrFcShort( 0x2 ), /* 2 */ 259 /* 36 */ 0x9, /* Corr desc: FC_ULONG */ 260 0x0, /* */ 261 /* 38 */ NdrFcShort( 0xfffc ), /* -4 */ 262 /* 40 */ NdrFcShort( 0x1 ), /* Corr flags: early, */ 263 /* 42 */ 0x6, /* FC_SHORT */ 264 0x5b, /* FC_END */ 265 /* 44 */ 266 0x17, /* FC_CSTRUCT */ 267 0x3, /* 3 */ 268 /* 46 */ NdrFcShort( 0x8 ), /* 8 */ 269 /* 48 */ NdrFcShort( 0xfff0 ), /* Offset= -16 (32) */ 270 /* 50 */ 0x8, /* FC_LONG */ 271 0x8, /* FC_LONG */ 272 /* 52 */ 0x5c, /* FC_PAD */ 273 0x5b, /* FC_END */ 274 /* 54 */ 0xb4, /* FC_USER_MARSHAL */ 275 0x83, /* 131 */ 276 /* 56 */ NdrFcShort( 0x0 ), /* 0 */ 277 /* 58 */ NdrFcShort( 0x4 ), /* 4 */ 278 /* 60 */ NdrFcShort( 0x0 ), /* 0 */ 279 /* 62 */ NdrFcShort( 0xffde ), /* Offset= -34 (28) */ 134 280 135 281 0x0 136 282 } 137 283 }; 284 285 static const USER_MARSHAL_ROUTINE_QUADRUPLE UserMarshalRoutines[ WIRE_MARSHAL_TABLE_SIZE ] = 286 { 287 288 { 289 BSTR_UserSize 290 ,BSTR_UserMarshal 291 ,BSTR_UserUnmarshal 292 ,BSTR_UserFree 293 } 294 295 }; 296 138 297 139 298 … … 343 502 }; 344 503 504 505 /* Object interface: IFilterGraphHelper, ver. 0.0, 506 GUID={0x3D1AF248,0xDEF1,0x4E26,{0xA0,0x71,0xFE,0xDF,0x15,0xFE,0xD6,0xA8}} */ 507 508 #pragma code_seg(".orpc") 509 static const unsigned short IFilterGraphHelper_FormatStringOffsetTable[] = 510 { 511 (unsigned short) -1, 512 (unsigned short) -1, 513 (unsigned short) -1, 514 (unsigned short) -1, 515 0, 516 36, 517 72 518 }; 519 520 static const MIDL_STUBLESS_PROXY_INFO IFilterGraphHelper_ProxyInfo = 521 { 522 &Object_StubDesc, 523 DirectShowSpy__MIDL_ProcFormatString.Format, 524 &IFilterGraphHelper_FormatStringOffsetTable[-3], 525 0, 526 0, 527 0 528 }; 529 530 531 static const MIDL_SERVER_INFO IFilterGraphHelper_ServerInfo = 532 { 533 &Object_StubDesc, 534 0, 535 DirectShowSpy__MIDL_ProcFormatString.Format, 536 &IFilterGraphHelper_FormatStringOffsetTable[-3], 537 0, 538 0, 539 0, 540 0}; 541 CINTERFACE_PROXY_VTABLE(10) _IFilterGraphHelperProxyVtbl = 542 { 543 &IFilterGraphHelper_ProxyInfo, 544 &IID_IFilterGraphHelper, 545 IUnknown_QueryInterface_Proxy, 546 IUnknown_AddRef_Proxy, 547 IUnknown_Release_Proxy , 548 0 /* IDispatch::GetTypeInfoCount */ , 549 0 /* IDispatch::GetTypeInfo */ , 550 0 /* IDispatch::GetIDsOfNames */ , 551 0 /* IDispatch_Invoke_Proxy */ , 552 (void *) (INT_PTR) -1 /* IFilterGraphHelper::get_FilterGraph */ , 553 (void *) (INT_PTR) -1 /* IFilterGraphHelper::put_FilterGraph */ , 554 (void *) (INT_PTR) -1 /* IFilterGraphHelper::get_Text */ 555 }; 556 557 558 static const PRPC_STUB_FUNCTION IFilterGraphHelper_table[] = 559 { 560 STUB_FORWARDING_FUNCTION, 561 STUB_FORWARDING_FUNCTION, 562 STUB_FORWARDING_FUNCTION, 563 STUB_FORWARDING_FUNCTION, 564 NdrStubCall2, 565 NdrStubCall2, 566 NdrStubCall2 567 }; 568 569 CInterfaceStubVtbl _IFilterGraphHelperStubVtbl = 570 { 571 &IID_IFilterGraphHelper, 572 &IFilterGraphHelper_ServerInfo, 573 10, 574 &IFilterGraphHelper_table[-3], 575 CStdStubBuffer_DELEGATING_METHODS 576 }; 577 345 578 static const MIDL_STUB_DESC Object_StubDesc = 346 579 { … … 359 592 0x700022b, /* MIDL Version 7.0.555 */ 360 593 0, 361 0,594 UserMarshalRoutines, 362 595 0, /* notify & notify_flag routine table */ 363 596 0x1, /* MIDL flag */ … … 370 603 { 371 604 ( CInterfaceProxyVtbl *) &_ISpyProxyVtbl, 605 ( CInterfaceProxyVtbl *) &_IFilterGraphHelperProxyVtbl, 372 606 ( CInterfaceProxyVtbl *) &_ISystemDeviceEnumeratorSpyProxyVtbl, 373 607 ( CInterfaceProxyVtbl *) &_IFilterMapperSpyProxyVtbl, … … 378 612 { 379 613 ( CInterfaceStubVtbl *) &_ISpyStubVtbl, 614 ( CInterfaceStubVtbl *) &_IFilterGraphHelperStubVtbl, 380 615 ( CInterfaceStubVtbl *) &_ISystemDeviceEnumeratorSpyStubVtbl, 381 616 ( CInterfaceStubVtbl *) &_IFilterMapperSpyStubVtbl, … … 386 621 { 387 622 "ISpy", 623 "IFilterGraphHelper", 388 624 "ISystemDeviceEnumeratorSpy", 389 625 "IFilterMapperSpy", … … 396 632 &IID_IDispatch, 397 633 &IID_IDispatch, 634 &IID_IDispatch, 398 635 0 399 636 }; … … 406 643 IID_BS_LOOKUP_SETUP 407 644 408 IID_BS_LOOKUP_INITIAL_TEST( _DirectShowSpy, 3, 2 )645 IID_BS_LOOKUP_INITIAL_TEST( _DirectShowSpy, 4, 2 ) 409 646 IID_BS_LOOKUP_NEXT_TEST( _DirectShowSpy, 1 ) 410 IID_BS_LOOKUP_RETURN_RESULT( _DirectShowSpy, 3, *pIndex )647 IID_BS_LOOKUP_RETURN_RESULT( _DirectShowSpy, 4, *pIndex ) 411 648 412 649 } … … 419 656 (const IID ** ) & _DirectShowSpy_BaseIIDList, 420 657 & _DirectShowSpy_IID_Lookup, 421 3,658 4, 422 659 2, 423 660 0, /* table of [async_uuid] interfaces */ -
trunk/DirectShowSpy/FilterGraphList.h
r196 r199 10 10 #include "rofiles.h" 11 11 #include "FilterGraphSpy.h" 12 #include "FilterGraphHelper.h" 12 13 #include "AboutDialog.h" 13 14 … … 288 289 m_GraphListView.SortItems(&CListPropertyPage::SortGraphListViewItems, (LPARAM) this); 289 290 } 290 static CString FormatIdentifier(LPCSTR pszValue)291 {292 CString sText;293 if(pszValue && *pszValue)294 {295 sText = _T("``");296 sText.Insert(1, CString(pszValue));297 }298 return sText;299 }300 static CString FormatIdentifier(LPCWSTR pszValue)301 {302 CString sText;303 if(pszValue && *pszValue)304 {305 sText = _T("``");306 sText.Insert(1, CString(pszValue));307 }308 return sText;309 }310 static CString FormatIdentifier(LONG nValue)311 {312 CString sText;313 sText = _T("``");314 sText.Insert(1, _StringHelper::FormatNumber(nValue));315 return sText;316 }317 static CString FormatIdentifier(ULONG nValue)318 {319 return FormatIdentifier((LONG) nValue);320 }321 static CString FormatIdentifier(BOOL nValue)322 {323 return FormatIdentifier((LONG) nValue);324 }325 static CString FormatIdentifier(LONGLONG nValue)326 {327 CString sText;328 sText = _T("``");329 sText.Insert(1, _StringHelper::FormatNumber(nValue));330 return sText;331 }332 static CString FormatIdentifier(LONG nValue, LPCTSTR pszFormat)333 {334 CString sText;335 sText = _T("``");336 sText.Insert(1, AtlFormatString(pszFormat, nValue));337 return sText;338 }339 #define I FormatIdentifier340 static CString FormatPins(_FilterGraphHelper::CPinArray& PinArray)341 {342 CRoArrayT<CString> Array;343 for(SIZE_T nIndex = 0; nIndex < PinArray.GetCount(); nIndex++)344 {345 const CComPtr<IPin>& pPin = PinArray[nIndex];346 CString sText = I(_FilterGraphHelper::GetPinName(pPin));347 const CComPtr<IPin> pPeerPin = _FilterGraphHelper::GetPeerPin(pPin);348 if(pPeerPin)349 sText += AtlFormatString(_T(" (%s)"), I(_FilterGraphHelper::GetPinFullName(pPeerPin)));350 Array.Add(sText);351 }352 return _StringHelper::Join(Array, _T(", "));353 }354 CString GetText(CItem& Item) const355 {356 _A(Item.m_pFilterGraph);357 CString sText;358 sText += AtlFormatString(_T("# ") _T("Filter Graph") _T("\r\n") _T("\r\n"));359 #pragma region Graph Parameters360 sText += AtlFormatString(_T("* ") _T("Process: %s (%s) %s") _T("\r\n"), I(Item.m_nProcessIdentifier), I(Item.m_nProcessIdentifier, _T("0x%X")), I(FindFileName(Item.m_sProcessImagePath)));361 //if(!Item.m_sTime.IsEmpty())362 // sText += AtlFormatString(_T("* ") _T("CreationTime: %s") _T("\r\n"), I(Item.m_sTime));363 if(!Item.m_sState.IsEmpty())364 sText += AtlFormatString(_T("* ") _T("State: %s") _T("\r\n"), I(Item.m_sState));365 if(Item.m_fDuration > 0)366 {367 sText += AtlFormatString(_T("* ") _T("Duration: %s seconds") _T("\r\n"), I(_StringHelper::FormatNumber(Item.m_fDuration, 3)));368 sText += AtlFormatString(_T("* ") _T("Position: %s seconds") _T("\r\n"), I(_StringHelper::FormatNumber(Item.m_fPosition, 3)));369 }370 sText += AtlFormatString(_T("* ") _T("Display Name: %s") _T("\r\n"), I(Item.m_sDisplayName));371 const CString sDirectory = (LPCTSTR) GetPathDirectory(Item.m_sProcessImagePath);372 if(!sDirectory.IsEmpty())373 sText += AtlFormatString(_T("* ") _T("Process Directory: %s") _T("\r\n"), I(sDirectory));374 sText += _T("\r\n");375 #pragma endregion376 #pragma region Filter377 _FilterGraphHelper::CFilterArray FilterArray;378 _FilterGraphHelper::GetGraphFilters(Item.m_pFilterGraph, FilterArray);379 if(!FilterArray.IsEmpty())380 {381 sText += AtlFormatString(_T("## ") _T("Filters") _T("\r\n") _T("\r\n"));382 for(SIZE_T nIndex = 0; nIndex < FilterArray.GetCount(); nIndex++)383 _ATLTRY384 {385 const CComPtr<IBaseFilter>& pBaseFilter = FilterArray[nIndex];386 sText += AtlFormatString(_T("%d. ") _T("%ls") _T("\r\n"), nIndex + 1, _FilterGraphHelper::GetFilterName(pBaseFilter));387 const CStringW sClassIdentifierString = _FilterGraphHelper::GetFilterClassIdentifierString(pBaseFilter);388 if(!sClassIdentifierString.IsEmpty())389 sText += AtlFormatString(_T(" * ") _T("Class: %s %s") _T("\r\n"), I(sClassIdentifierString), I(_FilterGraphHelper::GetFilterClassDescription(pBaseFilter)));390 _FilterGraphHelper::CPinArray InputPinArray;391 if(_FilterGraphHelper::GetFilterPins(pBaseFilter, PINDIR_INPUT, InputPinArray))392 sText += AtlFormatString(_T(" * ") _T("Input Pins: %s") _T("\r\n"), FormatPins(InputPinArray));393 _FilterGraphHelper::CPinArray OutputPinArray;394 if(_FilterGraphHelper::GetFilterPins(pBaseFilter, PINDIR_OUTPUT, OutputPinArray))395 sText += AtlFormatString(_T(" * ") _T("Output Pins: %s") _T("\r\n"), FormatPins(OutputPinArray));396 #pragma region IFileSourceFilter397 const CComQIPtr<IFileSourceFilter> pFileSourceFilter = pBaseFilter;398 if(pFileSourceFilter)399 {400 CComHeapPtr<OLECHAR> pszFileName;401 CMediaType pMediaType;402 pMediaType.Allocate(MEDIATYPE_NULL, MEDIASUBTYPE_NULL);403 const HRESULT nGetCurFileResult = pFileSourceFilter->GetCurFile(&pszFileName, pMediaType);404 _Z45_DSHRESULT(nGetCurFileResult);405 if(SUCCEEDED(nGetCurFileResult))406 sText += AtlFormatString(_T(" * ") _T("File Source: %s") _T("\r\n"), I(pszFileName));407 }408 #pragma endregion409 #pragma region IFileSinkFilter410 const CComQIPtr<IFileSinkFilter> pFileSinkFilter = pBaseFilter;411 if(pFileSinkFilter)412 {413 CComHeapPtr<OLECHAR> pszFileName;414 CMediaType pMediaType;415 pMediaType.Allocate(MEDIATYPE_NULL, MEDIASUBTYPE_NULL);416 const HRESULT nGetCurFileResult = pFileSinkFilter->GetCurFile(&pszFileName, pMediaType);417 _Z45_DSHRESULT(nGetCurFileResult);418 if(SUCCEEDED(nGetCurFileResult))419 sText += AtlFormatString(_T(" * ") _T("File Sink: %s") _T("\r\n"), I(pszFileName));420 }421 #pragma endregion422 }423 _ATLCATCHALL()424 {425 _Z_EXCEPTION();426 }427 sText += _T("\r\n");428 #pragma region Connection429 sText += AtlFormatString(_T("## ") _T("Connections") _T("\r\n") _T("\r\n"));430 INT nConnectionIndex = 0;431 for(SIZE_T nFilterIndex = 0; nFilterIndex < FilterArray.GetCount(); nFilterIndex++)432 {433 const CComPtr<IBaseFilter>& pBaseFilter = FilterArray[nFilterIndex];434 _FilterGraphHelper::CPinArray PinArray;435 _FilterGraphHelper::GetFilterPins(pBaseFilter, PINDIR_OUTPUT, PinArray);436 for(SIZE_T nPinIndex = 0; nPinIndex < PinArray.GetCount(); nPinIndex++)437 {438 const CComPtr<IPin>& pOutputPin = PinArray[nPinIndex];439 const CComPtr<IPin> pInputPin = _FilterGraphHelper::GetPeerPin(pOutputPin);440 if(!pInputPin)441 continue;442 CString sConnectionText = AtlFormatString(_T("%s - %s"), I(_FilterGraphHelper::GetPinFullName(pOutputPin)), I(_FilterGraphHelper::GetPinFullName(pInputPin)));443 _ATLTRY444 {445 const CMediaType pMediaType = _FilterGraphHelper::GetPinMediaType(pOutputPin);446 if(pMediaType)447 {448 CStringW sMajorType = _FilterGraphHelper::FormatMajorType(pMediaType->majortype);449 CStringW sSubtype;450 if(pMediaType->subtype != MEDIASUBTYPE_NULL)451 sSubtype = _FilterGraphHelper::FormatSubtype(pMediaType->subtype);452 sConnectionText += AtlFormatString(_T(" (%s %s)"), I(sMajorType), I(sSubtype));453 }454 }455 _ATLCATCHALL()456 {457 _Z_EXCEPTION();458 }459 sText += AtlFormatString(_T("%d. ") _T("%s") _T("\r\n"), ++nConnectionIndex, sConnectionText);460 }461 }462 sText += _T("\r\n");463 #pragma endregion464 #pragma region Media Type465 sText += AtlFormatString(_T("## ") _T("Media Types") _T("\r\n") _T("\r\n"));466 INT nGlobalPinIndex = 0;467 CRoListT<CComPtr<IPin>> PinList;468 for(SIZE_T nFilterIndex = 0; nFilterIndex < FilterArray.GetCount(); nFilterIndex++)469 {470 const CComPtr<IBaseFilter>& pBaseFilter = FilterArray[nFilterIndex];471 _FilterGraphHelper::CPinArray PinArray;472 _FilterGraphHelper::GetFilterPins(pBaseFilter, PinArray);473 for(SIZE_T nPinIndex = 0; nPinIndex < PinArray.GetCount(); nPinIndex++)474 {475 const CComPtr<IPin>& pPin = PinArray[nPinIndex];476 if(PinList.FindFirst(pPin))477 continue;478 PinList.AddTail(pPin);479 CString sPinText = AtlFormatString(_T("%s"), I(_FilterGraphHelper::GetPinFullName(pPin)));480 const CComPtr<IPin> pPeerPin = _FilterGraphHelper::GetPeerPin(pPin);481 if(pPeerPin)482 {483 PinList.AddTail(pPeerPin);484 sPinText += AtlFormatString(_T(", %s"), I(_FilterGraphHelper::GetPinFullName(pPeerPin)));485 }486 sText += AtlFormatString(_T("%d. ") _T("%s") _T("\r\n"), ++nGlobalPinIndex, sPinText);487 _ATLTRY488 {489 CMediaType pMediaType;490 if(pPeerPin)491 pMediaType = _FilterGraphHelper::GetPinMediaType(pPin);492 else493 pMediaType = _FilterGraphHelper::EnumerateFirstPinMediaType(pPin);494 if(!pMediaType)495 continue;496 #pragma region AM_MEDIA_TYPE497 #define J(x) I(pMediaType->x)498 #define K1(x) sText += AtlFormatString(_T(" * `") _T(#x) _T("`: %s") _T("\r\n"), J(x))499 sText += AtlFormatString(_T(" * ") _T("Data: %s") _T("\r\n"), I(AtlFormatData((const BYTE*) (const AM_MEDIA_TYPE*) pMediaType, sizeof *pMediaType).TrimRight()));500 sText += AtlFormatString(_T(" * ") _T("`majortype`: %s") _T("\r\n"), I(_FilterGraphHelper::FormatMajorType(pMediaType->majortype)));501 if(pMediaType->subtype != MEDIASUBTYPE_NULL)502 sText += AtlFormatString(_T(" * ") _T("`subtype`: %s") _T("\r\n"), I(_FilterGraphHelper::FormatSubtype(pMediaType->subtype)));503 K1(bFixedSizeSamples);504 K1(bTemporalCompression);505 K1(lSampleSize);506 if(pMediaType->formattype != GUID_NULL)507 sText += AtlFormatString(_T(" * ") _T("`formattype`: %s") _T("\r\n"), I(_FilterGraphHelper::FormatFormatType(pMediaType->formattype)));508 if(pMediaType->pUnk)509 sText += AtlFormatString(_T(" * ") _T("`pUnk`: %s") _T("\r\n"), I(AtlFormatString(_T("0x%p"), pMediaType->pUnk)));510 if(pMediaType->cbFormat)511 {512 K1(cbFormat);513 if(pMediaType->pbFormat)514 sText += AtlFormatString(_T(" * ") _T("Format Data, `pbFormat`: %s") _T("\r\n"), I(AtlFormatData(pMediaType->pbFormat, pMediaType->cbFormat).TrimRight()));515 }516 #undef J517 #undef K1518 #pragma endregion519 const BYTE* pnExtraData = NULL;520 SIZE_T nExtraDataSize = 0;521 #pragma region FORMAT_VideoInfo522 if(pMediaType->formattype == FORMAT_VideoInfo)523 {524 sText += AtlFormatString(_T(" * ") _T("As `VIDEOINFOHEADER`:") _T("\r\n"));525 const VIDEOINFOHEADER* pVideoInfoHeader = (const VIDEOINFOHEADER*) pMediaType->pbFormat;526 #define J(x) I(pVideoInfoHeader->x)527 #define K1(x) sText += AtlFormatString(_T(" * `") _T(#x) _T("`: %s") _T("\r\n"), J(x))528 sText += AtlFormatString(_T(" * ") _T("`rcSource`: (%s, %s) - (%s, %s)") _T("\r\n"), J(rcSource.left), J(rcSource.top), J(rcSource.right), J(rcSource.bottom));529 sText += AtlFormatString(_T(" * ") _T("`rcTarget`: (%s, %s) - (%s, %s)") _T("\r\n"), J(rcTarget.left), J(rcTarget.top), J(rcTarget.right), J(rcTarget.bottom));530 K1(dwBitRate);531 K1(dwBitErrorRate);532 sText += AtlFormatString(_T(" * ") _T("`AvgTimePerFrame`: %s units") _T("\r\n"), I(_FilterGraphHelper::FormatReferenceTime(pVideoInfoHeader->AvgTimePerFrame)));533 K1(bmiHeader.biSize);534 K1(bmiHeader.biWidth);535 K1(bmiHeader.biHeight);536 K1(bmiHeader.biPlanes);537 K1(bmiHeader.biBitCount);538 sText += AtlFormatString(_T(" * ") _T("`bmiHeader.biCompression`: %s") _T("\r\n"), I(_FilterGraphHelper::GetFourccCodeString(pVideoInfoHeader->bmiHeader.biCompression)));539 K1(bmiHeader.biSizeImage);540 K1(bmiHeader.biXPelsPerMeter);541 K1(bmiHeader.biYPelsPerMeter);542 K1(bmiHeader.biClrUsed);543 K1(bmiHeader.biClrImportant);544 #undef J545 #undef K1546 nExtraDataSize = pMediaType->cbFormat - sizeof *pVideoInfoHeader;547 } else548 #pragma endregion549 #pragma region FORMAT_VideoInfo2550 if(pMediaType->formattype == FORMAT_VideoInfo2)551 {552 sText += AtlFormatString(_T(" * ") _T("As `VIDEOINFOHEADER2`:") _T("\r\n"));553 const VIDEOINFOHEADER2* pVideoInfoHeader2 = (const VIDEOINFOHEADER2*) pMediaType->pbFormat;554 #define J(x) I(pVideoInfoHeader2->x)555 #define K1(x) sText += AtlFormatString(_T(" * `") _T(#x) _T("`: %s") _T("\r\n"), J(x))556 #define K2(x, y) sText += AtlFormatString(_T(" * `") _T(#x) _T("`: %s") _T("\r\n"), I(pVideoInfoHeader2->x, y))557 sText += AtlFormatString(_T(" * ") _T("rcSource: (%s, %s) - (%s, %s)") _T("\r\n"), J(rcSource.left), J(rcSource.top), J(rcSource.right), J(rcSource.bottom));558 sText += AtlFormatString(_T(" * ") _T("rcTarget: (%s, %s) - (%s, %s)") _T("\r\n"), J(rcTarget.left), J(rcTarget.top), J(rcTarget.right), J(rcTarget.bottom));559 K1(dwBitRate);560 K1(dwBitErrorRate);561 sText += AtlFormatString(_T(" * ") _T("`AvgTimePerFrame`: %s units") _T("\r\n"), I(_FilterGraphHelper::FormatReferenceTime(pVideoInfoHeader2->AvgTimePerFrame)));562 K2(dwInterlaceFlags, _T("0x%X"));563 K2(dwCopyProtectFlags, _T("0x%X"));564 K1(dwPictAspectRatioX);565 K1(dwPictAspectRatioY);566 K2(dwControlFlags, _T("0x%X"));567 K1(bmiHeader.biSize);568 K1(bmiHeader.biWidth);569 K1(bmiHeader.biHeight);570 K1(bmiHeader.biPlanes);571 K1(bmiHeader.biBitCount);572 sText += AtlFormatString(_T(" * ") _T("`bmiHeader.biCompression`: %s") _T("\r\n"), I(_FilterGraphHelper::GetFourccCodeString(pVideoInfoHeader2->bmiHeader.biCompression)));573 K1(bmiHeader.biSizeImage);574 K1(bmiHeader.biXPelsPerMeter);575 K1(bmiHeader.biYPelsPerMeter);576 K1(bmiHeader.biClrUsed);577 K1(bmiHeader.biClrImportant);578 #undef J579 #undef K1580 #undef K2581 nExtraDataSize = pMediaType->cbFormat - sizeof *pVideoInfoHeader2;582 if(nExtraDataSize)583 {584 sText += AtlFormatString(_T(" * ") _T("Extra Data: (%d bytes)") _T("\r\n"), nExtraDataSize);585 nExtraDataSize = 0;586 }587 } else588 #pragma endregion589 #pragma region FORMAT_MPEG2Video590 if(pMediaType->formattype == FORMAT_MPEG2Video)591 {592 sText += AtlFormatString(_T(" * ") _T("As `MPEG2VIDEOINFO`:") _T("\r\n"));593 const MPEG2VIDEOINFO* pMpeg2VideoInfo = (const MPEG2VIDEOINFO*) pMediaType->pbFormat;594 #define J(x) I(pMpeg2VideoInfo->x)595 #define K1(x) sText += AtlFormatString(_T(" * `") _T(#x) _T("`: %s") _T("\r\n"), J(x))596 #define K2(x, y) sText += AtlFormatString(_T(" * `") _T(#x) _T("`: %s") _T("\r\n"), I(pMpeg2VideoInfo->x, y))597 sText += AtlFormatString(_T(" * ") _T("`hdr.rcSource`: (%s, %s) - (%s, %s)") _T("\r\n"), J(hdr.rcSource.left), J(hdr.rcSource.top), J(hdr.rcSource.right), J(hdr.rcSource.bottom));598 sText += AtlFormatString(_T(" * ") _T("`hdr.rcTarget`: (%s, %s) - (%s, %s)") _T("\r\n"), J(hdr.rcTarget.left), J(hdr.rcTarget.top), J(hdr.rcTarget.right), J(hdr.rcTarget.bottom));599 K1(hdr.dwBitRate);600 K1(hdr.dwBitErrorRate);601 sText += AtlFormatString(_T(" * ") _T("`hdr.AvgTimePerFrame`: %s") _T("\r\n"), I(_FilterGraphHelper::FormatReferenceTime(pMpeg2VideoInfo->hdr.AvgTimePerFrame)));602 K2(hdr.dwInterlaceFlags, _T("0x%X"));603 K2(hdr.dwCopyProtectFlags, _T("0x%X"));604 K1(hdr.dwPictAspectRatioX);605 K1(hdr.dwPictAspectRatioY);606 K2(hdr.dwControlFlags, _T("0x%X"));607 K1(hdr.bmiHeader.biSize);608 K1(hdr.bmiHeader.biWidth);609 K1(hdr.bmiHeader.biHeight);610 K1(hdr.bmiHeader.biPlanes);611 K1(hdr.bmiHeader.biBitCount);612 sText += AtlFormatString(_T(" * ") _T("`hdr.bmiHeader.biCompression`: %s") _T("\r\n"), I(_FilterGraphHelper::GetFourccCodeString(pMpeg2VideoInfo->hdr.bmiHeader.biCompression)));613 K1(hdr.bmiHeader.biSizeImage);614 K1(hdr.bmiHeader.biXPelsPerMeter);615 K1(hdr.bmiHeader.biYPelsPerMeter);616 K1(hdr.bmiHeader.biClrUsed);617 K1(hdr.bmiHeader.biClrImportant);618 K2(dwStartTimeCode, _T("0x%08X"));619 K1(cbSequenceHeader);620 K1(dwProfile);621 K1(dwLevel);622 K2(dwFlags, _T("0x%08X"));623 #undef J624 #undef K1625 #undef K2626 #undef J627 nExtraDataSize = pMediaType->cbFormat - (sizeof *pMpeg2VideoInfo - sizeof pMpeg2VideoInfo->dwSequenceHeader);628 } else629 #pragma endregion630 #pragma region FORMAT_WaveFormatEx631 if(pMediaType->formattype == FORMAT_WaveFormatEx)632 {633 const WAVEFORMATEX* pWaveFormatEx = (const WAVEFORMATEX*) pMediaType->pbFormat;634 if(pWaveFormatEx->wFormatTag == WAVE_FORMAT_EXTENSIBLE)635 {636 const WAVEFORMATEXTENSIBLE* pWaveFormatExtensible = (const WAVEFORMATEXTENSIBLE*) pMediaType->pbFormat;637 #define J(x) I(pWaveFormatExtensible->x)638 #define K1(x) sText += AtlFormatString(_T(" * `") _T(#x) _T("`: %s") _T("\r\n"), J(x))639 #define K2(x, y) sText += AtlFormatString(_T(" * `") _T(#x) _T("`: %s") _T("\r\n"), I(pWaveFormatExtensible->x, y))640 sText += AtlFormatString(_T(" * ") _T("As `WAVEFORMATEXTENSIBLE`:") _T("\r\n"));641 K2(Format.wFormatTag, _T("0x%02X"));642 K1(Format.nChannels);643 K1(Format.nSamplesPerSec);644 K1(Format.nAvgBytesPerSec);645 K1(Format.nBlockAlign);646 K1(Format.wBitsPerSample);647 K1(Format.cbSize);648 K1(Samples.wValidBitsPerSample);649 K2(dwChannelMask, _T("0x%02X"));650 sText += AtlFormatString(_T(" * ") _T("`SubFormat`: %s") _T("\r\n"), I(_PersistHelper::StringFromIdentifier(pWaveFormatExtensible->SubFormat)));651 #undef J652 #undef K1653 #undef K2654 nExtraDataSize = pWaveFormatEx->cbSize - (sizeof *pWaveFormatExtensible - sizeof *pWaveFormatEx);655 } else656 {657 #define J(x) I(pWaveFormatEx->x)658 #define K1(x) sText += AtlFormatString(_T(" * `") _T(#x) _T("`: %s") _T("\r\n"), J(x))659 #define K2(x, y) sText += AtlFormatString(_T(" * `") _T(#x) _T("`: %s") _T("\r\n"), I(pWaveFormatEx->x, y))660 K2(wFormatTag, _T("0x%02X"));661 K1(nChannels);662 K1(nSamplesPerSec);663 K1(nAvgBytesPerSec);664 K1(nBlockAlign);665 K1(wBitsPerSample);666 K1(cbSize);667 #undef J668 #undef K1669 #undef K2670 nExtraDataSize = pWaveFormatEx->cbSize;671 }672 }673 #pragma endregion674 #pragma region Extra Data675 if(nExtraDataSize)676 {677 if(!pnExtraData)678 pnExtraData = pMediaType->pbFormat + pMediaType->cbFormat - nExtraDataSize;679 sText += AtlFormatString(_T(" * ") _T("Extra Data: %s") _T("\r\n"), I(AtlFormatData(pnExtraData, nExtraDataSize).TrimRight()));680 }681 #pragma endregion682 }683 _ATLCATCHALL()684 {685 _Z_EXCEPTION();686 }687 }688 }689 sText += _T("\r\n");690 #pragma endregion691 }692 #pragma endregion693 return sText;694 }695 #undef I696 291 CString GetText() 697 292 { … … 706 301 Item.Check(); 707 302 m_GraphListView.RedrawItems(nItem, nItem); 708 GraphArray.Add(GetText(Item)); 303 CFilterGraphHelper::CProcessData ProcessData; 304 ProcessData.m_sDisplayName = Item.m_sDisplayName; 305 ProcessData.m_nIdentifier = Item.m_nProcessIdentifier; 306 ProcessData.m_sImagePath = Item.m_sProcessImagePath; 307 GraphArray.Add(CFilterGraphHelper::GetText(Item.m_pFilterGraph, &ProcessData)); 709 308 } 710 309 } -
trunk/DirectShowSpy/resource.h
r193 r199 14 14 #define IDR_FILTERMAPPERSPY 202 15 15 #define IDR_SYSTEMDEVICEENUMERATORSPY 203 16 #define ID C_BUTTON1 21716 #define IDR_FILTERGRAPHHELPER 300 17 17 #define IDS_REGISTRATION_PROPERTYSHEETCAPTION 900 18 18 #define IDD_REGISTRATION_REGISTRATION_PROPERTYPAGE 910
Note: See TracChangeset
for help on using the changeset viewer.