|
33 | 33 | #include <vector> |
34 | 34 | #endif // __cplusplus |
35 | 35 |
|
| 36 | +#define COM_NO_WINDOWS_H // needed to inform d3d headers that this isn't windows |
| 37 | + |
36 | 38 | //===----------------------------------------------------------------------===// |
37 | 39 | // |
38 | 40 | // Begin: Macro Definitions |
|
64 | 66 | #endif // __EMULATE_UUID |
65 | 67 |
|
66 | 68 | #define STDMETHODCALLTYPE |
67 | | -#define STDAPI extern "C" HRESULT STDAPICALLTYPE |
68 | | -#define STDAPI_(type) extern "C" type STDAPICALLTYPE |
69 | | -#define STDMETHODIMP HRESULT STDMETHODCALLTYPE |
70 | 69 | #define STDMETHODIMP_(type) type STDMETHODCALLTYPE |
| 70 | +#define STDMETHODIMP STDMETHODIMP_(HRESULT) |
| 71 | +#define STDMETHOD_(type,name) virtual STDMETHODIMP_(type) name |
| 72 | +#define STDMETHOD(name) STDMETHOD_(HRESULT, name) |
| 73 | +#define EXTERN_C extern "C" |
| 74 | + |
71 | 75 |
|
72 | 76 | #define UNREFERENCED_PARAMETER(P) (void)(P) |
73 | 77 |
|
|
325 | 329 | #define _Null_ |
326 | 330 | #define _Notnull_ |
327 | 331 | #define _Maybenull_ |
| 332 | +#define THIS_ |
| 333 | +#define THIS |
| 334 | +#define PURE = 0 |
328 | 335 |
|
329 | 336 | #define _Outptr_result_bytebuffer_(size) |
330 | 337 |
|
@@ -364,6 +371,7 @@ typedef unsigned int UINT; |
364 | 371 | typedef unsigned long ULONG; |
365 | 372 | typedef long long LONGLONG; |
366 | 373 | typedef long long LONG_PTR; |
| 374 | +typedef unsigned long long ULONG_PTR; |
367 | 375 | typedef unsigned long long ULONGLONG; |
368 | 376 |
|
369 | 377 | typedef uint16_t WORD; |
@@ -403,6 +411,7 @@ typedef signed int HRESULT; |
403 | 411 | //===--------------------- Handle Types -----------------------------------===// |
404 | 412 |
|
405 | 413 | typedef void *HANDLE; |
| 414 | +typedef void *RPC_IF_HANDLE; |
406 | 415 |
|
407 | 416 | #define DECLARE_HANDLE(name) \ |
408 | 417 | struct name##__ { \ |
@@ -610,6 +619,13 @@ template <typename T> inline void **IID_PPV_ARGS_Helper(T **pp) { |
610 | 619 |
|
611 | 620 | #endif // __EMULATE_UUID |
612 | 621 |
|
| 622 | +// Needed for d3d headers, but fail to create actual interfaces |
| 623 | +#define DEFINE_GUID(name, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) const GUID name = { l, w1, w2, { b1, b2, b3, b4, b5, b6, b7, b8 } } |
| 624 | +#define DECLSPEC_UUID(x) |
| 625 | +#define MIDL_INTERFACE(x) struct DECLSPEC_UUID(x) |
| 626 | +#define DECLARE_INTERFACE(iface) struct iface |
| 627 | +#define DECLARE_INTERFACE_(iface, parent) DECLARE_INTERFACE(iface) : parent |
| 628 | + |
613 | 629 | //===--------------------- COM Interfaces ---------------------------------===// |
614 | 630 |
|
615 | 631 | CROSS_PLATFORM_UUIDOF(IUnknown, "00000000-0000-0000-C000-000000000046") |
@@ -666,6 +682,11 @@ struct IStream : public ISequentialStream { |
666 | 682 | virtual HRESULT Clone(IStream **ppstm) = 0; |
667 | 683 | }; |
668 | 684 |
|
| 685 | +// These don't need stub implementations as they come from the DirectX Headers |
| 686 | +// They still need the __uuidof() though |
| 687 | +CROSS_PLATFORM_UUIDOF(ID3D12LibraryReflection, "8E349D19-54DB-4A56-9DC9-119D87BDB804") |
| 688 | +CROSS_PLATFORM_UUIDOF(ID3D12ShaderReflection, "5A58797D-A72C-478D-8BA2-EFC6B0EFE88E") |
| 689 | + |
669 | 690 | //===--------------------- COM Pointer Types ------------------------------===// |
670 | 691 |
|
671 | 692 | class CAllocator { |
|
0 commit comments