testing out new project config

This commit is contained in:
Steve Kirbach 2024-02-14 11:30:27 -08:00
parent 732545d261
commit 53e1d3ee2d
36 changed files with 66305 additions and 8 deletions

View File

@ -1,11 +1,24 @@
// swift-tools-version: 5.10
import PackageDescription
import Foundation
let currentDirectory = Context.packageDirectory
print(currentDirectory)
let includeSettings: [SwiftSetting] = [
.unsafeFlags(["-I\(currentDirectory)/vendor/include"])
]
let linkerSettings: [LinkerSetting] = [
.unsafeFlags(["-L\(currentDirectory)/vendor/lib"])
]
let package = Package(
name: "swift-windowsappsdk",
products: [
.library(name: "WinAppSDK", type: .dynamic, targets: ["WinAppSDK"]),
.library(name: "CWinAppSDK", targets: ["CWinAppSDK"]),
.library(name: "WinAppSDKExt", targets: ["WinAppSDKExt"])
],
dependencies: [
.package(url: "https://github.com/thebrowsercompany/swift-cwinrt", branch: "main"),
@ -19,9 +32,22 @@ let package = Package(
.product(name: "CWinRT", package: "swift-cwinrt"),
.product(name: "UWP", package: "swift-uwp"),
.product(name: "WindowsFoundation", package: "swift-windowsfoundation"),
"CWinAppSDK"
],
resources: [
.copy("NativeBinaries")
.copy("../../vendor/bin/Microsoft.WindowsAppRuntime.Bootstrap.dll"),
]
),
.target(
name: "CWinAppSDK",
swiftSettings: includeSettings,
linkerSettings: linkerSettings
),
.target(
name: "WinAppSDKExt",
dependencies: [
"WinAppSDK",
"CWinAppSDK"
]
),
]

View File

@ -0,0 +1,23 @@
#include <wtypesbase.h>
#include <minwindef.h>
#include <winnt.h>
#include "delayimp.h"
FARPROC WINAPI delayHook(unsigned dliNotify, PDelayLoadInfo pdli)
{
switch (dliNotify) {
case dliFailLoadLib :
if (strcmp(pdli->szDll, "Microsoft.WindowsAppRuntime.Boostrap.dll") == 0) {
return (FARPROC)LoadLibraryW(L"swift-windowsappsdk_WinAppSDK.resources\\Microsoft.WindowsAppRuntime.Bootstrap.dll");
}
break;
default :
return NULL;
}
return NULL;
}
const PfnDliHook __pfnDliNotifyHook2 = delayHook;
const PfnDliHook __pfnDliFailureHook2 = delayHook;

View File

@ -0,0 +1,13 @@
#include <wtypesbase.h>
#include <minwindef.h>
#include <winnt.h>
#include <combaseapi.h>
#include <roapi.h>
#include <winstring.h>
#include "stdlib.h"
#include <MddBootstrap.h>
#include <WindowsAppSDK-VersionInfo.h>
// re-define the string to make it visible in Swift. (#define only supports numbers & strings)
static PCWSTR WINDOWSAPPSDK_RELEASE_VERSION_TAG_SWIFT = WINDOWSAPPSDK_RELEASE_VERSION_TAG_W;

View File

@ -0,0 +1,5 @@
module CWinAppSDK {
header "Headers/CWinAppSDK-Bridging-Header.h"
link "Microsoft.WindowsAppRuntime.Bootstrap"
export *
}

View File

@ -0,0 +1,52 @@
import CWinAppSDK
import CWinRT
import WindowsFoundation
import WinSDK
public enum WindowsAppSDKError: Error {
case failedToInitialize
}
public enum ThreadingModel {
case single
case multi
}
public class WindowsAppRuntimeInitializer {
private func processHasIdentity() -> Bool {
var length: UInt32 = 0
return GetCurrentPackageFullName(&length, nil) != APPMODEL_ERROR_NO_PACKAGE
}
public init(threadingModel: ThreadingModel = .single) throws {
let roInitParam = switch threadingModel {
case .single: RO_INIT_SINGLETHREADED
case .multi: RO_INIT_MULTITHREADED
}
try CHECKED(RoInitialize(roInitParam))
guard !processHasIdentity() else {
return
}
let result = MddBootstrapInitialize2(
UInt32(WINDOWSAPPSDK_RELEASE_MAJORMINOR),
WINDOWSAPPSDK_RELEASE_VERSION_TAG_SWIFT,
.init(),
MddBootstrapInitializeOptions(
MddBootstrapInitializeOptions_OnNoMatch_ShowUI.rawValue
)
)
guard result = S_OK else {
throw WindowsAppSDKError.failedToInitialize
}
}
deinit {
RoUninitialize()
if !processHasIdentity() {
MddBootstrapShutdown()
}
}
}

View File

@ -91,23 +91,24 @@ function Invoke-SwiftWinRT() {
Copy-Item -Path $OutputLocation\Sources\$ProjectName -Filter *.swift -Destination $ProjectDir -Recurse -Force
}
function Copy-NativeBinaries {
function Copy-PackageAssets {
param(
[string]$PackagesDir
)
$Arch = "x64"
$Projections = Get-Content -Path $PSScriptRoot\projections.json | ConvertFrom-Json
$Package = $Projections.Package
$PackageVersion = Get-NugetPackageVersion -Package $Package
$ProjectDir = Join-Path $PSScriptRoot "vendor"
# copy dlls from runtimes\win-<arch>\native to vendor\bin
$PackageDir = Join-Path $PackagesDir "$Package.$PackageVersion"
$PackagesRuntimeDir = Join-Path $PackageDir "runtimes\win-x64\native"
$PackagesRuntimeDir = Join-Path $PackageDir "runtimes\win-$Arch\native"
$PackagesBinaries = Get-ChildItem -Path $PackagesRuntimeDir -Filter *.dll -Recurse
$ProjectName = $Projections.Project
$ProjectDir = Join-Path $PSScriptRoot "Sources\${ProjectName}"
$ProjectBinaryDir = Join-Path $ProjectDir "NativeBinaries"
$ProjectBinaryDir = Join-Path $ProjectDir "bin"
if (-not (Test-Path $ProjectBinaryDir)) {
New-Item -Path $ProjectBinaryDir -ItemType Directory -Force | Out-Null
}
@ -115,12 +116,35 @@ function Copy-NativeBinaries {
$PackagesBinaries | ForEach-Object {
Copy-Item -Path $_.FullName -Destination $ProjectBinaryDir -Force
}
# copy headers from include to vendor\include
$ProjectHeadersDir = Join-Path $ProjectDir "include"
if (-not (Test-Path $ProjectHeadersDir)) {
New-Item -Path $ProjectHeadersDir -ItemType Directory -Force | Out-Null
}
$PackagesHeaderDir = Join-Path $PackageDir "include"
$PackagesHeaders = Get-ChildItem -Path $PackagesHeaderDir -Filter *.h -Recurse
$PackagesHeaders | ForEach-Object {
Copy-Item -Path $_.FullName -Destination $ProjectHeadersDir -Force
}
# Copy libs from lib\win-<arch> to vendor\lib
$ProjectLibsDir = Join-Path $ProjectDir "lib"
$PackagesLibsDir = Join-Path $PackageDir "lib\win10-x64"
$PackagesLibs = Get-ChildItem -Path $PackagesLibsDir -Filter *.lib -Recurse
if (-not (Test-Path $ProjectLibsDir)) {
New-Item -Path $ProjectLibsDir -ItemType Directory -Force | Out-Null
}
$PackagesLibs | ForEach-Object {
Copy-Item -Path $_.FullName -Destination $ProjectLibsDir -Force
}
}
$PackagesDir = Join-Path $PSScriptRoot ".packages"
Restore-Nuget -PackagesDir $PackagesDir
Invoke-SwiftWinRT -PackagesDir $PackagesDir
Copy-NativeBinaries -PackagesDir $PackagesDir
Copy-PackageAssets -PackagesDir $PackagesDir
if ($LASTEXITCODE -eq 0) {
Write-Host "SwiftWinRT bindings generated successfully!" -ForegroundColor Green
}

View File

@ -1,5 +1,6 @@
{
"package": "Microsoft.WindowsAppSDK",
"version": "1.5.240205001-preview1",
"project": "WinAppSDK",
"dependencies": [
"Microsoft.Windows.SDK.Contracts"

133
vendor/include/MRM.h vendored Normal file
View File

@ -0,0 +1,133 @@
// Copyright (c) Microsoft Corporation and Contributors.
// Licensed under the MIT License.
#pragma once
#ifdef __cplusplus
extern "C"
{
#endif
DECLARE_HANDLE(MrmManagerHandle);
DECLARE_HANDLE(MrmContextHandle);
DECLARE_HANDLE(MrmMapHandle);
enum MrmType
{
MrmType_Unknown,
MrmType_String,
MrmType_Path,
MrmType_Embedded
};
struct MrmResourceData
{
UINT32 size;
void* data;
};
STDAPI MrmCreateResourceManager(_In_ PCWSTR priFileName, _Out_ MrmManagerHandle* resourceManager);
STDAPI_(void) MrmDestroyResourceManager(_In_opt_ MrmManagerHandle resourceManager);
STDAPI MrmCreateResourceContext(_In_ MrmManagerHandle resourceManager, _Out_ MrmContextHandle* resourceContext);
STDAPI_(void) MrmFreeQualifierNamesOrValues(UINT32 size, _In_reads_(size) PWSTR* names);
STDAPI MrmGetAllQualifierNames(_In_ MrmContextHandle resourceContext, _Out_ UINT32* size, _Outptr_result_buffer_(*size) PWSTR** names);
STDAPI MrmGetQualifier(_In_ MrmContextHandle resourceContext, _In_ PCWSTR qualifierName, _Outptr_ PWSTR* qualifierValue);
STDAPI MrmSetQualifier(_In_ MrmContextHandle resourceContext, _In_ PCWSTR qualifierName, _In_ PCWSTR qualifierValue);
STDAPI_(void) MrmDestroyResourceContext(_In_opt_ MrmContextHandle resourceContext);
// Resource maps are owned by the resource manager and so do not need to be destroyed.
STDAPI MrmGetChildResourceMap(
_In_ MrmManagerHandle resourceManager,
_In_opt_ MrmMapHandle resourceMap,
_In_ PCWSTR childResourceMapName,
_Out_ MrmMapHandle* childResourceMap);
STDAPI MrmGetResourceCount(_In_ MrmManagerHandle resourceManager, _In_opt_ MrmMapHandle resourceMap, _Out_ UINT32* count);
STDAPI MrmLoadStringResource(
_In_ MrmManagerHandle resourceManager,
_In_opt_ MrmContextHandle resourceContext,
_In_opt_ MrmMapHandle resourceMap,
_In_ PCWSTR resourceId,
_Outptr_ PWSTR* resourceString);
STDAPI MrmLoadStringResourceFromResourceUri(
_In_ MrmManagerHandle resourceManager,
_In_opt_ MrmContextHandle resourceContext,
_In_ PCWSTR resourceUri,
_Outptr_ PWSTR* resourceString);
STDAPI MrmLoadEmbeddedResource(
_In_ MrmManagerHandle resourceManager,
_In_opt_ MrmContextHandle resourceContext,
_In_opt_ MrmMapHandle resourceMap,
_In_ PCWSTR resourceId,
_Out_ MrmResourceData* data);
STDAPI MrmLoadEmbeddedResourceFromResourceUri(
_In_ MrmManagerHandle resourceManager,
_In_opt_ MrmContextHandle resourceContext,
_In_ PCWSTR resourceUri,
_Out_ MrmResourceData* data);
STDAPI MrmLoadStringOrEmbeddedResource(
_In_ MrmManagerHandle resourceManager,
_In_opt_ MrmContextHandle resourceContext,
_In_opt_ MrmMapHandle resourceMap,
_In_ PCWSTR resourceId,
_Out_ MrmType* resourceType,
_Outptr_result_maybenull_ PWSTR* resourceString,
_Out_ MrmResourceData* data);
STDAPI MrmLoadStringOrEmbeddedResourceWithQualifierValues(
_In_ MrmManagerHandle resourceManager,
_In_opt_ MrmContextHandle resourceContext,
_In_opt_ MrmMapHandle resourceMap,
_In_ PCWSTR resourceId,
_Out_ MrmType* resourceType,
_Outptr_result_maybenull_ PWSTR* resourceString,
_Out_ MrmResourceData* data,
_Out_ UINT32* qualifierCount,
_Outptr_result_buffer_(*qualifierCount) PWSTR** qualifierNames,
_Outptr_result_buffer_(*qualifierCount) PWSTR** qualifierValues);
STDAPI MrmLoadStringOrEmbeddedFromResourceUri(
_In_ MrmManagerHandle resourceManager,
_In_opt_ MrmContextHandle resourceContext,
_In_ PCWSTR resourceUri,
_Out_ MrmType* resourceType,
_Outptr_result_maybenull_ PWSTR* resourceString,
_Out_ MrmResourceData* data);
STDAPI MrmLoadStringOrEmbeddedResourceByIndex(
_In_ MrmManagerHandle resourceManager,
_In_opt_ MrmContextHandle resourceContext,
_In_opt_ MrmMapHandle resourceMap,
UINT32 index,
_Out_ MrmType* resourceType,
_Outptr_ PWSTR* resourceName,
_Outptr_result_maybenull_ PWSTR* resourceString,
_Out_ MrmResourceData* data);
STDAPI MrmLoadStringOrEmbeddedResourceByIndexWithQualifierValues(
_In_ MrmManagerHandle resourceManager,
_In_opt_ MrmContextHandle resourceContext,
_In_opt_ MrmMapHandle resourceMap,
UINT32 index,
_Out_ MrmType* resourceType,
_Outptr_ PWSTR* resourceName,
_Outptr_result_maybenull_ PWSTR* resourceString,
_Out_ MrmResourceData* data,
_Out_ UINT32* qualifierCount,
_Outptr_result_buffer_(*qualifierCount) PWSTR** qualifierNames,
_Outptr_result_buffer_(*qualifierCount) PWSTR** qualifierValues);
STDAPI_(void*) MrmAllocateBuffer(size_t size);
STDAPI_(void) MrmFreeResource(_In_opt_ void* resource);
STDAPI MrmGetFilePathFromName(_In_opt_ PCWSTR filename, _Outptr_ PWSTR* filePath);
#ifdef __cplusplus
}
#endif

338
vendor/include/MddBootstrap.h vendored Normal file
View File

@ -0,0 +1,338 @@
// Copyright (c) Microsoft Corporation and Contributors.
// Licensed under the MIT License.
#if !defined(MDDBOOTSTRAP_H)
#define MDDBOOTSTRAP_H
#include <appmodel.h>
#if defined(__cplusplus)
#define MDDBOOTSTRAP_NOEXCEPT noexcept
#else
#define MDDBOOTSTRAP_NOEXCEPT
#endif // defined(__cplusplus)
/// Options for Bootstrap initialization
typedef enum MddBootstrapInitializeOptions
{
/// Default behavior
MddBootstrapInitializeOptions_None = 0,
/// If not successful call DebugBreak()
MddBootstrapInitializeOptions_OnError_DebugBreak = 0x0001,
/// If not successful call DebugBreak() if a debugger is attached to the process
MddBootstrapInitializeOptions_OnError_DebugBreak_IfDebuggerAttached = 0x0002,
/// If not successful perform a fail-fast
MddBootstrapInitializeOptions_OnError_FailFast = 0x0004,
/// If a compatible Windows App Runtime framework package is not found show UI
MddBootstrapInitializeOptions_OnNoMatch_ShowUI = 0x0008,
/// Do nothing (do not error) if the process has package identity
MddBootstrapInitializeOptions_OnPackageIdentity_NOOP = 0x0010,
} MddBootstrapInitializeOptions;
#if defined(__cplusplus)
DEFINE_ENUM_FLAG_OPERATORS(MddBootstrapInitializeOptions)
#endif // defined(__cplusplus)
/// Initialize the calling process to use Windows App Runtime framework package.
///
/// Find a Windows App Runtime framework package meeting the criteria and make it available
/// for use by the current process. If multiple packages meet the criteria the best
/// candidate is selected.
///
/// If called multiple times the parameters must be compatible with the framework package
/// resolved by the first initialization call (i.e. the framework package currently in use).
/// If the request is not compatible with the framework package currently in use
/// the API fails and an error is returned.
///
/// @param majorMinorVersion the major and minor version to use, e..g 0x00010002 for Major.Minor=1.2
/// @param versionTag the version pre-release identifier, or NULL if none.
/// @param minVersion the minimum version to use
STDAPI MddBootstrapInitialize(
UINT32 majorMinorVersion,
PCWSTR versionTag,
PACKAGE_VERSION minVersion) MDDBOOTSTRAP_NOEXCEPT;
/// Initialize the calling process to use Windows App Runtime framework package.
///
/// Find a Windows App Runtime framework package meeting the criteria and make it available
/// for use by the current process. If multiple packages meet the criteria the best
/// candidate is selected.
///
/// If called multiple times the parameters must be compatible with the framework package
/// resolved by the first initialization call (i.e. the framework package currently in use).
/// If the request is not compatible with the framework package currently in use
/// the API fails and an error is returned.
///
/// @param majorMinorVersion the major and minor version to use, e..g 0x00010002 for Major.Minor=1.2
/// @param versionTag the version pre-release identifier, or NULL if none.
/// @param minVersion the minimum version to use
STDAPI MddBootstrapInitialize2(
UINT32 majorMinorVersion,
PCWSTR versionTag,
PACKAGE_VERSION minVersion,
MddBootstrapInitializeOptions options) MDDBOOTSTRAP_NOEXCEPT;
/// Undo the changes made by MddBoostrapInitialize().
///
/// @warning Packages made available via MddBootstrapInitialize2() and
/// the Dynamic Dependencies API should not be used after this call.
STDAPI_(void) MddBootstrapShutdown() MDDBOOTSTRAP_NOEXCEPT;
// C++ friendly APIs
#if defined(__cplusplus)
#if defined(WINDOWSAPPSDK_RELEASE_MAJORMINOR) && defined(WINDOWSAPPSDK_RELEASE_VERSION_TAG_W) && defined(WINDOWSAPPSDK_RUNTIME_VERSION_UINT64)
#include <memory>
#include <stdint.h>
namespace Microsoft::Windows::ApplicationModel
{
class PackageVersion : public PACKAGE_VERSION
{
public:
PackageVersion()
{
Version = 0;
}
// Create an instance with the value `major.minor.build.revision`.
PackageVersion(uint16_t major, uint16_t minor = 0, uint16_t build = 0, uint16_t revision = 0) :
PACKAGE_VERSION()
{
Major = major;
Minor = minor;
Build = build;
Revision = revision;
}
// Create an instance from a version as a uint64.
PackageVersion(uint64_t version)
{
Version = version;
}
// Return the version as a uint64.
uint64_t ToVersion() const
{
return Version;
}
#if defined(_XSTRING_) && defined(_STRSAFE_H_INCLUDED_) && defined(WI_VERIFY)
// Return the string as a formatted value "major.minor.build.revision".
std::wstring ToString() const
{
return ToString(Major, Minor, Build, Revision);
}
static std::wstring ToString(uint16_t major, uint16_t minor, uint16_t build, uint16_t revision)
{
wchar_t formattedVersion[5 + 1 + 5 + 1 + 5 + 1 + 5 + 1]{}; // "12345.12345.12345.12345" + null-terminator
WI_VERIFY(SUCCEEDED(StringCchPrintfW(formattedVersion, ARRAYSIZE(formattedVersion), L"%hu.%hu.%hu.%hu", major, minor, build, revision)));
return std::wstring(formattedVersion);
}
#endif
};
namespace DynamicDependency::Bootstrap
{
// Automate Boostrap shutdown when leaving scope
namespace details
{
struct mddbootstrapshutdown_t;
struct mddbootstrapshutdown_deleter_t
{
void operator()(mddbootstrapshutdown_t*)
{
MddBootstrapShutdown();
}
};
}
using unique_mddbootstrapshutdown = std::unique_ptr<details::mddbootstrapshutdown_t, details::mddbootstrapshutdown_deleter_t>;
/// Options for Bootstrap initialization APIs.
/// @see InitializeFailFast(uint32_t, PCWSTR, PackageVersion, InitializeOptions)
/// @see Initialize(uint32_t, PCWSTR, PackageVersion, InitializeOptions)
/// @see InitializeNoThrow(uint32_t, PCWSTR, PackageVersion, InitializeOptions)
enum class InitializeOptions
{
/// Default behavior
None = MddBootstrapInitializeOptions_None,
/// If not successful call DebugBreak()
OnError_DebugBreak = MddBootstrapInitializeOptions_OnError_DebugBreak,
/// If not successful call DebugBreak() if a debugger is attached to the process
OnError_DebugBreak_IfDebuggerAttached = MddBootstrapInitializeOptions_OnError_DebugBreak_IfDebuggerAttached,
/// If not successful perform a fail-fast
OnError_FailFast = MddBootstrapInitializeOptions_OnError_FailFast,
/// If a compatible Windows App Runtime framework package is not found show UI
OnNoMatch_ShowUI = MddBootstrapInitializeOptions_OnNoMatch_ShowUI,
/// Do nothing (do not error) if the process has package identity
OnPackageIdentity_NOOP = MddBootstrapInitializeOptions_OnPackageIdentity_NOOP,
};
DEFINE_ENUM_FLAG_OPERATORS(InitializeOptions)
/// Call MddBootstrapInitialize2() and aborts the process (via std::abort()) if it fails;
/// returns an RAII object that reverts the initialization on success.
///
/// Initialize the calling process to use Windows App SDK's framework package.
///
/// Find a Windows App SDK framework package meeting the criteria and make it available
/// for use by the current process. If multiple packages meet the criteria the best
/// candidate is selected.
///
/// @param majorMinorVersion major and minor version of Windows App SDK's framework package, encoded as `0xMMMMNNNN` where M=Major, N=Minor (e.g. 1.2 == 0x00010002).
/// @param versionTag version tag (if any), e.g. "preview1".
/// @param minVersion the minimum version to use
/// @param options optional behavior
/// @see Initialize(uint32_t, PCWSTR, PackageVersion, InitializeOptions)
/// @see InitializeNoThrow(uint32_t, PCWSTR, PackageVersion, InitializeOptions)
/// @see Shutdown()
/// ~~~~~
/// #include <windows.h>
///
/// #include <WindowsAppSDK-VersionInfo.h>
/// #include <MddBootstrap.h>
///
/// #include <iostream>
///
/// namespace MddBootstrap { using namespace ::Microsoft::Windows::ApplicationModel::DynamicDependency::Bootstrap; }
///
/// int main()
/// {
/// auto mddBootstrapShutdown = MddBootstrap::InitializeFailFast();
/// std::cout << "hello world";
/// return 0;
/// }
/// ~~~~~
[[nodiscard]] inline unique_mddbootstrapshutdown InitializeFailFast(
uint32_t majorMinorVersion = WINDOWSAPPSDK_RELEASE_MAJORMINOR,
PCWSTR versionTag = WINDOWSAPPSDK_RELEASE_VERSION_TAG_W,
PackageVersion minVersion = WINDOWSAPPSDK_RUNTIME_VERSION_UINT64,
InitializeOptions options = ::Microsoft::Windows::ApplicationModel::DynamicDependency::Bootstrap::InitializeOptions::None)
{
const auto hr{ ::MddBootstrapInitialize2(majorMinorVersion, versionTag, minVersion, static_cast<MddBootstrapInitializeOptions>(options)) };
if (FAILED(hr))
{
std::abort();
}
return unique_mddbootstrapshutdown(reinterpret_cast<details::mddbootstrapshutdown_t*>(1));
}
#if defined(_CPPUNWIND) && defined(WINRT_BASE_H)
/// Call MddBootstrapInitialize2() and throws an exception if it fails;
/// returns an RAII object that reverts the initialization on success.
///
/// Initialize the calling process to use Windows App SDK's framework package.
///
/// Find a Windows App SDK framework package meeting the criteria and make it available
/// for use by the current process. If multiple packages meet the criteria the best
/// candidate is selected.
///
/// @param majorMinorVersion major and minor version of Windows App SDK's framework package, encoded as `0xMMMMNNNN` where M=Major, N=Minor (e.g. 1.2 == 0x00010002).
/// @param versionTag version tag (if any), e.g. "preview1".
/// @param minVersion the minimum version to use
/// @param options optional behavior
/// @see Initialize_failfast(uint32_t, PCWSTR, PackageVersion, InitializeOptions)
/// @see Initialize_nothrow(uint32_t, PCWSTR, PackageVersion, InitializeOptions)
/// @see Shutdown()
/// @exception winrt::hresult_error thrown if intialization fails; see code() for more details.
/// ~~~~~
/// #include <windows.h>
///
/// #include <winrt\base.h>
///
/// #include <WindowsAppSDK-VersionInfo.h>
/// #include <MddBootstrap.h>
///
/// #include <iostream>
///
/// namespace MddBootstrap { using namespace ::Microsoft::Windows::ApplicationModel::DynamicDependency::Bootstrap; }
///
/// int main()
/// {
/// try
/// {
/// auto mddBootstrapCleanup = MddBootstrap::Initialize();
/// std::cout << "hello world";
/// }
/// catch (const winrt::hresult_error& ex)
/// {
/// const auto hr{ ex.code() };
/// std::cout << "Error 0x" << std::hex << hr << " in Bootstrap initialization";
/// return hr;
/// }
/// return 0;
/// }
/// ~~~~~
[[nodiscard]] inline unique_mddbootstrapshutdown Initialize(
uint32_t majorMinorVersion = WINDOWSAPPSDK_RELEASE_MAJORMINOR,
PCWSTR versionTag = WINDOWSAPPSDK_RELEASE_VERSION_TAG_W,
PackageVersion minVersion = WINDOWSAPPSDK_RUNTIME_VERSION_UINT64,
InitializeOptions options = ::Microsoft::Windows::ApplicationModel::DynamicDependency::Bootstrap::InitializeOptions::None)
{
winrt::check_hresult(::MddBootstrapInitialize2(majorMinorVersion, versionTag, minVersion, static_cast<MddBootstrapInitializeOptions>(options)));
return unique_mddbootstrapshutdown(reinterpret_cast<details::mddbootstrapshutdown_t*>(1));
}
#endif // defined(_CPPUNWIND) && defined(WINRT_BASE_H)
/// Call MddBootstrapInitialize2() and returns a failure HRESULT if it fails.
///
/// Initialize the calling process to use Windows App SDK's framework package.
///
/// Find a Windows App SDK framework package meeting the criteria and make it available
/// for use by the current process. If multiple packages meet the criteria the best
/// candidate is selected.
///
/// @param majorMinorVersion major and minor version of Windows App SDK's framework package, encoded as `0xMMMMNNNN` where M=Major, N=Minor (e.g. 1.2 == 0x00010002).
/// @param versionTag version tag (if any), e.g. "preview1".
/// @param minVersion the minimum version to use
/// @param options optional behavior
/// @see InitializeFailFast(uint32_t, PCWSTR, PackageVersion, InitializeOptions)
/// @see Initialize(uint32_t, PCWSTR, PackageVersion, InitializeOptions)
/// @see Shutdown()
/// ~~~~~
/// #include <windows.h>
///
/// #include <WindowsAppSDK-VersionInfo.h>
/// #include <MddBootstrap.h>
///
/// #include <iostream>
///
/// namespace MddBootstrap { using namespace ::Microsoft::Windows::ApplicationModel::DynamicDependency::Bootstrap; }
///
/// int main()
/// {
/// const auto hr{ MddBootstrap::InitializeNoThrow() };
/// if (FAILED(hr))
/// {
/// std::cout << "Error 0x" << std::hex << hr << " in Bootstrap initialization";
/// return hr;
/// }
/// auto mddBootstrapShutdown{ MddBootstrap::unique_mddbootstrapshutdown(reinterpret_cast<MddBootstrap::details::mddbootstrapshutdown_t*>(1)) };
/// std::cout << "hello world";
/// return 0;
/// }
/// ~~~~~
inline HRESULT InitializeNoThrow(
uint32_t majorMinorVersion = WINDOWSAPPSDK_RELEASE_MAJORMINOR,
PCWSTR versionTag = WINDOWSAPPSDK_RELEASE_VERSION_TAG_W,
PackageVersion minVersion = WINDOWSAPPSDK_RUNTIME_VERSION_UINT64,
InitializeOptions options = ::Microsoft::Windows::ApplicationModel::DynamicDependency::Bootstrap::InitializeOptions::None)
{
return ::MddBootstrapInitialize2(majorMinorVersion, versionTag, minVersion, static_cast<MddBootstrapInitializeOptions>(options));
}
}
}
#endif // defined(WINDOWSAPPSDK_RELEASE_MAJORMINOR) && defined(WINDOWSAPPSDK_RELEASE_VERSION_TAG_W) && defined(WINDOWSAPPSDK_RUNTIME_VERSION_UINT64)
#endif // defined(__cplusplus)
#endif // MDDBOOTSTRAP_H

View File

@ -0,0 +1,121 @@
//---------------------------------------------------------------------------
// Copyright (c) Microsoft Corporation. All rights reserved.
//---------------------------------------------------------------------------
#if defined(_MSC_VER) && (_MSC_VER >= 1020)
#pragma once
#endif
#include <winrt/Microsoft.ui.composition.h>
#include <sdkddkver.h>
namespace winrt {
namespace Microsoft {
namespace UI {
namespace Composition {
#undef INTERFACE
#define INTERFACE ICompositionDrawingSurfaceInterop
DECLARE_INTERFACE_IID_(ICompositionDrawingSurfaceInterop, ::IUnknown, "2D6355C2-AD57-4EAE-92E4-4C3EFF65D578")
{
IFACEMETHOD(BeginDraw)(
_In_opt_ const RECT * updateRect,
_In_ REFIID iid,
_COM_Outptr_ void ** updateObject,
_Out_ POINT * updateOffset
) PURE;
IFACEMETHOD(EndDraw)(
) PURE;
IFACEMETHOD(Resize)(
_In_ SIZE sizePixels
) PURE;
IFACEMETHOD(Scroll)(
_In_opt_ const RECT * scrollRect,
_In_opt_ const RECT * clipRect,
_In_ int offsetX,
_In_ int offsetY
) PURE;
IFACEMETHOD(ResumeDraw)(
) PURE;
IFACEMETHOD(SuspendDraw)(
) PURE;
};
#undef INTERFACE
#define INTERFACE ICompositionDrawingSurfaceInterop2
DECLARE_INTERFACE_IID_(ICompositionDrawingSurfaceInterop2, ICompositionDrawingSurfaceInterop, "D4B71A65-3052-4ABE-9183-E98DE02A41A9")
{
IFACEMETHOD(CopySurface)(
_In_ ::IUnknown* destinationResource,
_In_ int destinationOffsetX,
_In_ int destinationOffsetY,
_In_opt_ const RECT * sourceRectangle
) PURE;
};
#undef INTERFACE
#define INTERFACE ICompositionGraphicsDeviceInterop
DECLARE_INTERFACE_IID_(ICompositionGraphicsDeviceInterop, ::IUnknown, "4AFA8030-BC70-4B0C-B1C7-6E69F933DC83")
{
IFACEMETHOD(GetRenderingDevice)(
_COM_Outptr_ ::IUnknown ** value
) PURE;
IFACEMETHOD(SetRenderingDevice)(
_In_ ::IUnknown * value
) PURE;
};
#undef INTERFACE
#define INTERFACE ICompositorInterop
DECLARE_INTERFACE_IID_(ICompositorInterop, ::IUnknown, "FAB19398-6D19-4D8A-B752-8F096C396069")
{
public:
HRESULT CreateGraphicsDevice(
_In_ ::IUnknown * renderingDevice,
_Out_ ICompositionGraphicsDevice* result)
{
return CreateGraphicsDevice_Abi(
renderingDevice,
winrt::put_abi(*result));
}
private:
IFACEMETHOD(CreateGraphicsDevice_Abi)(
_In_ ::IUnknown * renderingDevice,
_COM_Outptr_ void** result // ICompositionGraphicsDevice**
) PURE;
};
#pragma region Desktop Family
#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP)
namespace Interactions
{
#undef INTERFACE
#define INTERFACE IVisualInteractionSourceInterop
DECLARE_INTERFACE_IID_(IVisualInteractionSourceInterop, ::IUnknown, "AA170AEE-01D7-4954-89D2-8554415D6946")
{
IFACEMETHOD(TryRedirectForManipulation)(
_In_ const POINTER_INFO& pointerInfo
) PURE;
};
} // Interactions
#endif /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP) */
#pragma endregion
} // namespace Composition
} // namespace UI
} // namespace Microsoft
} // namespace winrt

View File

@ -0,0 +1,12 @@
//---------------------------------------------------------------------------
// Copyright (c) Microsoft Corporation. All rights reserved.
//---------------------------------------------------------------------------
#if defined(_MSC_VER) && (_MSC_VER >= 1020)
#pragma once
#endif
#include <wtypes.h>
extern "C" BOOL __stdcall
ContentPreTranslateMessage(const MSG *pmsg);

View File

@ -0,0 +1,30 @@
//---------------------------------------------------------------------------
// Copyright (c) Microsoft Corporation. All rights reserved.
//---------------------------------------------------------------------------
#if defined(_MSC_VER) && (_MSC_VER >= 1020)
#pragma once
#endif
#include <sdkddkver.h>
namespace winrt {
namespace Microsoft {
namespace UI {
namespace Input {
#undef INTERFACE
#define INTERFACE IInputCursorStaticsInterop
DECLARE_INTERFACE_IID_(IInputCursorStaticsInterop, IInspectable, "ac6f5065-90c4-46ce-beb7-05e138e54117")
{
IFACEMETHOD(CreateFromHCursor)(
_In_ HCURSOR cursor,
_Out_ IInputCursor * *result
) PURE;
};
} // namespace Input
} // namespace UI
} // namespace Microsoft
} // namespace winrt

View File

@ -0,0 +1,63 @@
//---------------------------------------------------------------------------
// Copyright (c) Microsoft Corporation. All rights reserved.
//---------------------------------------------------------------------------
#if defined(_MSC_VER) && (_MSC_VER >= 1020)
#pragma once
#endif
#include <sdkddkver.h>
namespace winrt {
namespace Microsoft {
namespace UI {
namespace Input {
// Ever wondered what all of the macros do for these manual COM-style interface definitions? I
// know I did! And Raymond Chen has the answers: https://devblogs.microsoft.com/oldnewthing/20041005-00/?p=37653
//
// Since we don't support C code calling these interfaces, we've opted to forego a few of the usual
// requirements. Specifically, we don't use "#undef INTERFACE / #define INTERFACE", we don't use the
// BEGIN and END macros, we don't use the THIS or THIS_ macros, and we don't repeat the base class
// members.
interface IInputPreTranslateKeyboardSourceHandler;
DECLARE_INTERFACE_IID_(IInputPreTranslateKeyboardSourceInterop, IUnknown, "C3244A48-DCB4-416C-901A-FFC5E50C2FFA")
{
IFACEMETHOD(SetPreTranslateHandler)(
_In_ IInputPreTranslateKeyboardSourceHandler* handler
) PURE;
};
DECLARE_INTERFACE_IID_(IInputPreTranslateKeyboardSourceHandler, IUnknown, "9A4B69AA-E3BE-4590-95F5-3AAA7B12B260")
{
// "keyboardModifiers" are flags that can hold a combination of the following values:
//
// FVIRTKEY 0x0001 Message is WM_(SYS)KEYDOWN or WM_(SYS)KEYUP.
// FSHIFT 0x0004 VK_SHIFT is pressed.
// FCONTROL 0x0008 VK_CONTROL is pressed (or VK_RCONTROL when the AltGr key is present and pressed).
// FALT 0x0010 VK_MENU is pressed (or VK_LMENU when the AltGr key is present and pressed).
IFACEMETHOD(OnDirectMessage)(
_In_ IInputPreTranslateKeyboardSourceInterop* source,
_In_ const MSG* msg,
_In_ UINT keyboardModifiers,
_Inout_ bool* handled
) PURE;
IFACEMETHOD(OnTreeMessage)(
_In_ IInputPreTranslateKeyboardSourceInterop* source,
_In_ const MSG* msg,
_In_ UINT keyboardModifiers,
_Inout_ bool* handled
) PURE;
};
} // namespace Input
} // namespace UI
} // namespace Microsoft
} // namespace winrt

151
vendor/include/Microsoft.UI.Interop.h vendored Normal file
View File

@ -0,0 +1,151 @@
//----------------------------------------------------------------------------
// Copyright (c) Microsoft Corporation. All rights reserved.
//----------------------------------------------------------------------------
#if defined(_MSC_VER) && (_MSC_VER >= 1020)
#pragma once
#endif
#include <winrt/Microsoft.UI.h>
namespace ABI::Microsoft::UI
{
using WindowId = winrt::Microsoft::UI::WindowId;
using DisplayId = winrt::Microsoft::UI::DisplayId;
using IconId = winrt::Microsoft::UI::IconId;
}
namespace winrt::Microsoft::UI
{
typedef HRESULT (STDAPICALLTYPE *PfnGetWindowIdFromWindow)(_In_ HWND hwnd, _Out_ ABI::Microsoft::UI::WindowId* windowId);
typedef HRESULT (STDAPICALLTYPE *PfnGetWindowFromWindowId)(_In_ ABI::Microsoft::UI::WindowId windowId, _Out_ HWND* hwnd);
typedef HRESULT (STDAPICALLTYPE *PfnGetDisplayIdFromMonitor)(_In_ HMONITOR hmonitor, _Out_ ABI::Microsoft::UI::DisplayId* displayId);
typedef HRESULT (STDAPICALLTYPE *PfnGetMonitorFromDisplayId)(_In_ ABI::Microsoft::UI::DisplayId displayId, _Out_ HMONITOR* hmonitor);
typedef HRESULT (STDAPICALLTYPE *PfnGetIconIdFromIcon)(_In_ HICON hicon, _Out_ ABI::Microsoft::UI::IconId* iconId);
typedef HRESULT (STDAPICALLTYPE *PfnGetIconFromIconId)(_In_ ABI::Microsoft::UI::IconId iconId, _Out_ HICON* hicon);
typedef struct _InteropImpl
{
PfnGetWindowIdFromWindow pfnGetWindowIdFromWindow;
PfnGetWindowFromWindowId pfnGetWindowFromWindowId;
PfnGetDisplayIdFromMonitor pfnGetDisplayIdFromMonitor;
PfnGetMonitorFromDisplayId pfnGetMonitorFromDisplayId;
PfnGetIconIdFromIcon pfnGetIconIdFromIcon;
PfnGetIconFromIconId pfnGetIconFromIconId;
} InteropImpl;
#pragma warning(push)
#pragma warning(disable:4505) // linker warning: unreferenced local function has been removed
__declspec(selectany) InteropImpl s_impl { nullptr };
__declspec(selectany) HMODULE s_module { nullptr };
// Load the FrameworkUdk library if needed and store pointers to the handle conversion functions.
// We need this approach because third-party apps cannot link to the FrameworkUdk directly.
// Note that in unpackaged apps this will only work after a call to MddBootstrapInitialize().
static void EnsureInteropImplLoaded()
{
if (s_module == nullptr)
{
HMODULE hmod = ::GetModuleHandle(TEXT("Microsoft.Internal.FrameworkUdk.dll"));
if (hmod == nullptr)
{
hmod = ::LoadLibrary(TEXT("Microsoft.Internal.FrameworkUdk.dll"));
}
if (hmod != nullptr)
{
// In case of race conditions, this should be idempotent
*reinterpret_cast<FARPROC*>(&s_impl.pfnGetWindowIdFromWindow) = ::GetProcAddress(hmod, "Windowing_GetWindowIdFromWindow");
*reinterpret_cast<FARPROC*>(&s_impl.pfnGetWindowFromWindowId) = ::GetProcAddress(hmod, "Windowing_GetWindowFromWindowId");
*reinterpret_cast<FARPROC*>(&s_impl.pfnGetDisplayIdFromMonitor) = ::GetProcAddress(hmod, "Windowing_GetDisplayIdFromMonitor");
*reinterpret_cast<FARPROC*>(&s_impl.pfnGetMonitorFromDisplayId) = ::GetProcAddress(hmod, "Windowing_GetMonitorFromDisplayId");
*reinterpret_cast<FARPROC*>(&s_impl.pfnGetIconIdFromIcon) = ::GetProcAddress(hmod, "Windowing_GetIconIdFromIcon");
*reinterpret_cast<FARPROC*>(&s_impl.pfnGetIconFromIconId) = ::GetProcAddress(hmod, "Windowing_GetIconFromIconId");
winrt::check_bool(
(s_impl.pfnGetWindowIdFromWindow != nullptr) &&
(s_impl.pfnGetWindowFromWindowId != nullptr) &&
(s_impl.pfnGetDisplayIdFromMonitor != nullptr) &&
(s_impl.pfnGetMonitorFromDisplayId != nullptr) &&
(s_impl.pfnGetIconIdFromIcon != nullptr) &&
(s_impl.pfnGetIconFromIconId != nullptr));
// Store our HMODULE if none has been set so far
::InterlockedCompareExchangePointer(reinterpret_cast<volatile PVOID*>(&s_module), hmod, nullptr);
// It is possible that due to race conditions the FrameworkUdk dll ends up loaded multiple
// times. The expectation is that the FrameworkUdk dll will remain loaded for the lifetime
// of the process so we won't attempt to mitigate the extra lib refcounts.
}
}
winrt::check_bool(s_module != nullptr);
}
static winrt::Microsoft::UI::WindowId GetWindowIdFromWindow(_In_ const HWND& hwnd)
{
::ABI::Microsoft::UI::WindowId abiWindowId = {};
EnsureInteropImplLoaded();
winrt::check_hresult(s_impl.pfnGetWindowIdFromWindow(hwnd, &abiWindowId));
winrt::Microsoft::UI::WindowId winrtWindowId { abiWindowId.Value };
return winrtWindowId;
}
static HWND GetWindowFromWindowId(_In_ const winrt::Microsoft::UI::WindowId& windowId)
{
HWND hwnd = nullptr;
EnsureInteropImplLoaded();
::ABI::Microsoft::UI::WindowId abiWindowId { windowId.Value };
winrt::check_hresult(s_impl.pfnGetWindowFromWindowId(abiWindowId, &hwnd));
return hwnd;
}
static winrt::Microsoft::UI::DisplayId GetDisplayIdFromMonitor(_In_ const HMONITOR& hmonitor)
{
::ABI::Microsoft::UI::DisplayId abiDisplayId = {};
EnsureInteropImplLoaded();
winrt::check_hresult(s_impl.pfnGetDisplayIdFromMonitor(hmonitor, &abiDisplayId));
winrt::Microsoft::UI::DisplayId winrtDisplayId { abiDisplayId.Value };
return winrtDisplayId;
}
static HMONITOR GetMonitorFromDisplayId(_In_ const winrt::Microsoft::UI::DisplayId& displayId)
{
HMONITOR hmonitor = nullptr;
EnsureInteropImplLoaded();
::ABI::Microsoft::UI::DisplayId abiDisplayId { displayId.Value };
winrt::check_hresult(s_impl.pfnGetMonitorFromDisplayId(abiDisplayId, &hmonitor));
return hmonitor;
}
static winrt::Microsoft::UI::IconId GetIconIdFromIcon(_In_ const HICON& hicon)
{
::ABI::Microsoft::UI::IconId abiIconId = {};
EnsureInteropImplLoaded();
winrt::check_hresult(s_impl.pfnGetIconIdFromIcon(hicon, &abiIconId));
winrt::Microsoft::UI::IconId winrtIconId { abiIconId.Value };
return winrtIconId;
}
static HICON GetIconFromIconId(_In_ const winrt::Microsoft::UI::IconId& iconId)
{
HICON hicon = nullptr;
EnsureInteropImplLoaded();
::ABI::Microsoft::UI::IconId abiIconId { iconId.Value };
winrt::check_hresult(s_impl.pfnGetIconFromIconId(abiIconId, &hicon));
return hicon;
}
#pragma warning(pop)
} // namespace winrt::Microsoft::UI

226
vendor/include/MsixDynamicDependency.h vendored Normal file
View File

@ -0,0 +1,226 @@
// Copyright (c) Microsoft Corporation and Contributors.
// Licensed under the MIT License.
#if !defined(MSIXDYNAMICDEPENDENCY_H)
#define MSIXDYNAMICDEPENDENCY_H
#include <appmodel.h>
#include <stdint.h>
/// MSIX Dynamic Dependency HRESULT: Windows App Runtime is not in the package graph.
#define MDD_E_WINDOWSAPPRUNTIME_NOT_IN_PACKAGE_GRAPH _HRESULT_TYPEDEF_(0x80040001L)
/// MSIX Dynamic Dependency HRESULT: Data Store not found (Windows App Runtime's Main package not registered?)
#define MDD_E_WINDOWSAPPRUNTIME_DATASTORE_NOT_FOUND _HRESULT_TYPEDEF_(0x80040002L)
/// MSIX Dynamic Dependency: Bootstrap initialization is scanning for an applicable DynamicDependencyLifetimeManager (DDLM) package
#define MDD_E_BOOTSTRAP_INITIALIZE_SCAN_FOR_DDLM _HRESULT_TYPEDEF_(0x80040010L)
/// MSIX Dynamic Dependency: Bootstrap initialization found a DynamicDependencyLifetimeManager (DDLM) but doesn't match the criteria
#define MDD_E_BOOTSTRAP_INITIALIZE_DDLM_SCAN_NO_MATCH _HRESULT_TYPEDEF_(0x80040011L)
/// MSIX Dynamic Dependency: Bootstrap initialization found a DynamicDependencyLifetimeManager (DDLM) that does match the criteria
#define MDD_E_BOOTSTRAP_INITIALIZE_DDLM_SCAN_MATCH _HRESULT_TYPEDEF_(0x80040012L)
/// MSIX Dynamic Dependency: Bootstrap initialization found an applicable DynamicDependencyLifetimeManager (DDLM) best matching the criteria
#define MDD_E_BOOTSTRAP_INITIALIZE_DDLM_FOUND _HRESULT_TYPEDEF_(0x80040013L)
/// MSIX Dynamic Dependency: Bootstrap initialization request is incompatible with current Bootstrap initialization state.
#define MDD_E_BOOTSTRAP_INITIALIZE_INCOMPATIBLE _HRESULT_TYPEDEF_(0x80040014L)
#if defined(__cplusplus)
enum class MddCreatePackageDependencyOptions : uint32_t
{
None = 0,
/// Disable dependency resolution when pinning a package dependency.
DoNotVerifyDependencyResolution = 0x00000001,
/// Define the package dependency for the system, accessible to all users
/// (default is the package dependency is defined for a specific user).
/// This option requires the caller has adminitrative privileges.
ScopeIsSystem = 0x00000002,
};
DEFINE_ENUM_FLAG_OPERATORS(MddCreatePackageDependencyOptions)
enum class MddPackageDependencyLifetimeKind
{
/// The current process is the lifetime artifact. The package dependency
/// is implicitly deleted when the process terminates.
Process = 0,
/// The lifetime artifact is an absolute filename or path.
/// The package dependency is implicitly deleted when this is deleted.
FilePath = 1,
/// The lifetime artifact is a registry key in the format
/// 'root\\subkey' where root is one of the following: HKLM, HKCU, HKCR, HKU.
/// The package dependency is implicitly deleted when this is deleted.
RegistryKey = 2,
};
enum class MddAddPackageDependencyOptions : uint32_t
{
None = 0,
PrependIfRankCollision = 0x00000001,
};
DEFINE_ENUM_FLAG_OPERATORS(MddAddPackageDependencyOptions)
#define MDD_PACKAGE_DEPENDENCY_RANK_DEFAULT 0
enum class MddPackageDependencyProcessorArchitectures : uint32_t
{
None = 0,
Neutral = 0x00000001,
X86 = 0x00000002,
X64 = 0x00000004,
Arm = 0x00000008,
Arm64 = 0x00000010,
X86OnArm64 = 0x00000020,
};
DEFINE_ENUM_FLAG_OPERATORS(MddPackageDependencyProcessorArchitectures)
DECLARE_HANDLE(MDD_PACKAGEDEPENDENCY_CONTEXT);
/// Define a package dependency. The criteria for a PackageDependency
/// (package family name, minimum version, etc)
/// may match multiple packages, but ensures Deployment won't remove
/// a package if it's the only one satisfying the PackageDependency.
///
/// @note A package matching a PackageDependency pin can still be removed
/// as long as there's another package that satisfies the PackageDependency.
/// For example, if Fwk-v1 is installed and a PackageDependency specifies
/// MinVersion=1 and then Fwk-v2 is installed, Deployment could remove
/// Fwk-v1 because Fwk-v2 will satisfy the PackageDependency. After Fwk-v1
/// is removed Deployment won't remove Fwk-v2 because it's the only package
/// satisfying the PackageDependency. Thus Fwk-v1 and Fwk-v2 (and any other
/// package matching the PackageDependency) are 'loosely pinned'. Deployment
/// guarantees it won't remove a package if it would make a PackageDependency
/// unsatisfied.
///
/// A PackageDependency specifies criteria (package family, minimum version, etc)
/// and not a specific package. Deployment reserves the right to use a different
/// package (e.g. higher version) to satisfy the PackageDependency if/when
/// one becomes available.
///
/// @param user the user scope of the package dependency. If NULL the caller's
/// user context is used. MUST be NULL if MddCreatePackageDependencyOptions::ScopeIsSystem
/// is specified
/// @param lifetimeArtifact MUST be NULL if lifetimeKind=MddPackageDependencyLifetimeKind::Process
/// @param packageDependencyId allocated via HeapAlloc; use HeapFree to deallocate
///
/// @note MddTryCreatePackageDependency() fails if the PackageDependency cannot be resolved to a specific
/// package. This package resolution check is skipped if
/// MddCreatePackageDependencyOptions::DoNotVerifyDependencyResolution is specified. This is useful
/// for installers running as user contexts other than the target user (e.g. installers
/// running as LocalSystem).
STDAPI MddTryCreatePackageDependency(
PSID user,
_In_ PCWSTR packageFamilyName,
PACKAGE_VERSION minVersion,
MddPackageDependencyProcessorArchitectures packageDependencyProcessorArchitectures,
MddPackageDependencyLifetimeKind lifetimeKind,
PCWSTR lifetimeArtifact,
MddCreatePackageDependencyOptions options,
_Outptr_result_maybenull_ PWSTR* packageDependencyId) noexcept;
/// Undefine a package dependency. Removing a pin on a PackageDependency is typically done at uninstall-time.
/// This implicitly occurs if the package dependency's 'lifetime artifact' (specified via MddTryCreatePackageDependency)
/// is deleted. Packages that are not referenced by other packages and have no pins are elegible to be removed.
///
/// @warn MddDeletePackageDependency() requires the caller have administrative privileges
/// if the package dependency was pinned with MddCreatePackageDependencyOptions::ScopeIsSystem.
STDAPI_(void) MddDeletePackageDependency(
_In_ PCWSTR packageDependencyId) noexcept;
/// Resolve a previously-pinned PackageDependency to a specific package and
/// add it to the invoking process' package graph. Once the dependency has
/// been added other code-loading methods (LoadLibrary, CoCreateInstance, etc)
/// can find the binaries in the resolved package.
///
/// Package resolution is specific to a user and can return different values
/// for different users on a system.
///
/// Each successful MddAddPackageDependency() adds the resolved packaged to the
/// calling process' package graph, even if already present. There is no
/// duplicate 'detection' or 'filtering' applied by the API (multiple
/// references from a package is not harmful). Once resolution is complete
/// the package dependency stays resolved for that user until the last reference across
/// all processes for that user is removed via MddRemovePackageDependency (or
/// process termination).
///
/// MddAddPackageDependency() adds the resolved package to the caller's package graph,
/// per the rank specified. A process' package graph is a list of packages sorted by
/// rank in ascending order (-infinity...0...+infinity). If package(s) are present in the
/// package graph with the same rank as the call to MddAddPackageDependency the resolved
/// package is (by default) added after others of the same rank. To add a package
/// before others o the same rank, specify MddAddPackageDependencyOptions::PrependIfRankCollision.
///
/// Every MddAddPackageDependency can be balanced by a MddRemovePackageDependency
/// to remove the entry from the package graph. If the process terminates all package
/// references are removed, but any pins stay behind.
///
/// MddAddPackageDependency adds the resolved package to the process' package
/// graph, per the rank and options parameters. The process' package
/// graph is used to search for DLLs (per Dynamic-Link Library Search Order),
/// WinRT objects and other resources; the caller can now load DLLs, activate
/// WinRT objects and use other resources from the framework package until
/// MddRemovePackageDependency is called. The packageDependencyId parameter
/// must match a package dependency defined for the calling user or the
/// system (i.e. pinned with MddCreatePackageDependencyOptions::ScopeIsSystem) else
/// an error is returned.
///
/// @param packageDependencyContext valid until passed to MddRemovePackageDependency()
/// @param packageFullName allocated via HeapAlloc; use HeapFree to deallocate
STDAPI MddAddPackageDependency(
_In_ PCWSTR packageDependencyId,
INT32 rank,
MddAddPackageDependencyOptions options,
_Out_ MDD_PACKAGEDEPENDENCY_CONTEXT* packageDependencyContext,
_Outptr_opt_result_maybenull_ PWSTR* packageFullName) noexcept;
/// Remove a resolved PackageDependency from the current process' package graph
/// (i.e. undo MddAddPackageDependency). Used at runtime (i.e. the moral equivalent
/// of Windows' RemoveDllDirectory()).
///
/// @note This does not unload loaded resources (DLLs etc). After removing
/// a package dependency any files loaded from the package can continue
/// to be used; future file resolution will fail to see the removed
/// package dependency.
STDAPI_(void) MddRemovePackageDependency(
_In_ MDD_PACKAGEDEPENDENCY_CONTEXT packageDependencyContext) noexcept;
/// Return the package full name that would be used if the
/// PackageDependency were to be resolved. Does not add the
/// package to the process graph.
///
/// @param packageFullName allocated via HeapAlloc; use HeapFree to deallocate.
/// If the package dependency cannot be resolved the function
/// succeeds but packageFullName is nullptr.
STDAPI MddGetResolvedPackageFullNameForPackageDependency(
_In_ PCWSTR packageDependencyId,
_Outptr_result_maybenull_ PWSTR* packageFullName) noexcept;
/// Return the package dependency for the context.
///
/// @param packageDependencyId allocated via HeapAlloc; use HeapFree to deallocate.
/// If the package dependency context cannot be resolved
/// the function succeeds but packageDependencyId is nullptr.
STDAPI MddGetIdForPackageDependencyContext(
_In_ MDD_PACKAGEDEPENDENCY_CONTEXT packageDependencyContext,
_Outptr_result_maybenull_ PWSTR* packageDependencyId) noexcept;
/// Return the package graph's current revision id.
STDAPI_(UINT32) MddGetPackageGraphRevisionId() noexcept;
/// Return the package graph's current revision id.
///
/// @note This API is deprecated and will be removed in a future release.
/// Use MddGetPackageGraphRevisionId().
STDAPI_(UINT32) MddGetGenerationId() noexcept;
#endif // defined(__cplusplus)
#endif // MSIXDYNAMICDEPENDENCY_H

21
vendor/include/Security.AccessControl.h vendored Normal file
View File

@ -0,0 +1,21 @@
// Copyright (c) Microsoft Corporation and Contributors.
// Licensed under the MIT License.
#pragma once
#include <Windows.h>
struct AppContainerNameAndAccess
{
PCWSTR appContainerName;
UINT32 accessMask;
};
STDAPI GetSecurityDescriptorForAppContainerNames(
UINT32 accessRequestCount,
_In_reads_(accessRequestCount) const AppContainerNameAndAccess* accessRequests,
_In_opt_ PSID principal,
UINT32 principalAccessMask,
_Outptr_ PSECURITY_DESCRIPTOR* securityDescriptor,
_Out_opt_ UINT32* securityDescriptorSize
);

48014
vendor/include/WebView2.h vendored Normal file

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,71 @@
// Copyright (c) Microsoft Corporation and Contributors.
// Licensed under the MIT License.
#pragma once
#if __has_include(<wil/tracelogging.h>)
#ifndef __WINDOWSAPPRUNTIMEINSIGHTS_INCLUDED
#define __WINDOWSAPPRUNTIMEINSIGHTS_INCLUDED
#ifdef __WIL_TRACELOGGING_H_INCLUDED
#error "WIL Tracelogging.h must not be explicitly included when including this file"
#endif
#include <wil/resource.h>
#include <string>
namespace Microsoft::WindowsAppRuntime::Insights
{
class RuntimeInformation
{
public:
static std::string WindowsAppRuntimeVersion()
{
const uint32_t c_versionResourceId{ 10000 };
static std::string version{ LoadStringFromResource(c_versionResourceId) };
return version;
}
static std::string WindowsAppRuntimeChannel()
{
const uint32_t c_channelResourceId{ 10001 };
static std::string channel{ LoadStringFromResource(c_channelResourceId) };
return channel;
}
private:
static std::string LoadStringFromResource(uint32_t id)
{
const uint32_t c_ResourceMaxLength{ 100 };
char resourceValue[c_ResourceMaxLength]{};
static wil::unique_hmodule module{ LoadResourceModule() };
if (module)
{
const auto resourceValueLength{ ::LoadStringA(module.get(), id, resourceValue, ARRAYSIZE(resourceValue)) };
LOG_LAST_ERROR_IF_MSG(resourceValueLength == 0, "Failed to load resource string. id: %u", id);
}
return resourceValue;
}
static wil::unique_hmodule LoadResourceModule()
{
const PCWSTR c_resourceDllName{ L"Microsoft.WindowsAppRuntime.Insights.Resource.dll" };
wil::unique_hmodule resourceDllHandle(::LoadLibraryW(c_resourceDllName));
LOG_LAST_ERROR_IF_NULL_MSG(resourceDllHandle, "Unable to load resource dll. %ls", c_resourceDllName);
return resourceDllHandle;
}
};
}
#define _GENERIC_PARTB_FIELDS_ENABLED \
TraceLoggingStruct(4, "COMMON_WINDOWSAPPSDK_PARAMS"), \
TraceLoggingString(::Microsoft::WindowsAppRuntime::Insights::RuntimeInformation::WindowsAppRuntimeVersion().c_str(), "Version"), \
TraceLoggingString(::Microsoft::WindowsAppRuntime::Insights::RuntimeInformation::WindowsAppRuntimeChannel().c_str(), "WindowsAppSDKChannel"), \
TraceLoggingBool(wil::details::IsDebuggerPresent(), "IsDebugging"), \
TraceLoggingBool(true, "UTCReplace_AppSessionGuid")
#include <wil/tracelogging.h>
#endif // __WINDOWSAPPRUNTIMEINSIGHTS_INCLUDED
#else
#error "WIL package must be referenced before including this header"
#endif

View File

@ -0,0 +1,285 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See LICENSE in the project root for license information.
#ifndef __WINDOWSAPPSDK_VERSIONINFO_H__
#define __WINDOWSAPPSDK_VERSIONINFO_H__
// Release information
#define WINDOWSAPPSDK_RELEASE_MAJOR 1
#define WINDOWSAPPSDK_RELEASE_MINOR 5
#define WINDOWSAPPSDK_RELEASE_PATCH 0
#define WINDOWSAPPSDK_RELEASE_MAJORMINOR 0x00010005
#define WINDOWSAPPSDK_RELEASE_CHANNEL "preview"
#define WINDOWSAPPSDK_RELEASE_CHANNEL_W L"preview"
#define WINDOWSAPPSDK_RELEASE_VERSION_TAG "preview1"
#define WINDOWSAPPSDK_RELEASE_VERSION_TAG_W L"preview1"
#define WINDOWSAPPSDK_RELEASE_VERSION_SHORTTAG "p1"
#define WINDOWSAPPSDK_RELEASE_VERSION_SHORTTAG_W L"p1"
#define WINDOWSAPPSDK_RELEASE_FORMATTED_VERSION_TAG "-preview1"
#define WINDOWSAPPSDK_RELEASE_FORMATTED_VERSION_TAG_W L"-preview1"
#define WINDOWSAPPSDK_RELEASE_FORMATTED_VERSION_SHORTTAG "-p1"
#define WINDOWSAPPSDK_RELEASE_FORMATTED_VERSION_SHORTTAG_W L"-p1"
// Runtime information
#define WINDOWSAPPSDK_RUNTIME_IDENTITY_PUBLISHER "CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US"
#define WINDOWSAPPSDK_RUNTIME_IDENTITY_PUBLISHER_W L"CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US"
#define WINDOWSAPPSDK_RUNTIME_IDENTITY_PUBLISHERID "8wekyb3d8bbwe"
#define WINDOWSAPPSDK_RUNTIME_IDENTITY_PUBLISHERID_W L"8wekyb3d8bbwe"
#define WINDOWSAPPSDK_RUNTIME_VERSION_MAJOR 5000u
#define WINDOWSAPPSDK_RUNTIME_VERSION_MINOR 35u
#define WINDOWSAPPSDK_RUNTIME_VERSION_BUILD 2034u
#define WINDOWSAPPSDK_RUNTIME_VERSION_REVISION 0u
#define WINDOWSAPPSDK_RUNTIME_VERSION_UINT64 0x1388002307F20000u
#define WINDOWSAPPSDK_RUNTIME_VERSION_DOTQUADSTRING "5000.35.2034.0"
#define WINDOWSAPPSDK_RUNTIME_VERSION_DOTQUADSTRING_W L"5000.35.2034.0"
#define WINDOWSAPPSDK_RUNTIME_PACKAGE_FRAMEWORK_PACKAGEFAMILYNAME "Microsoft.WindowsAppRuntime.1.5-preview1_8wekyb3d8bbwe"
#define WINDOWSAPPSDK_RUNTIME_PACKAGE_FRAMEWORK_PACKAGEFAMILYNAME_W L"Microsoft.WindowsAppRuntime.1.5-preview1_8wekyb3d8bbwe"
#define WINDOWSAPPSDK_RUNTIME_PACKAGE_MAIN_PACKAGEFAMILYNAME "MicrosoftCorporationII.WinAppRuntime.Main.1.5-p1_8wekyb3d8bbwe"
#define WINDOWSAPPSDK_RUNTIME_PACKAGE_MAIN_PACKAGEFAMILYNAME_W L"MicrosoftCorporationII.WinAppRuntime.Main.1.5-p1_8wekyb3d8bbwe"
#define WINDOWSAPPSDK_RUNTIME_PACKAGE_SINGLETON_PACKAGEFAMILYNAME "MicrosoftCorporationII.WinAppRuntime.Singleton-p1_8wekyb3d8bbwe"
#define WINDOWSAPPSDK_RUNTIME_PACKAGE_SINGLETON_PACKAGEFAMILYNAME_W L"MicrosoftCorporationII.WinAppRuntime.Singleton-p1_8wekyb3d8bbwe"
#define WINDOWSAPPSDK_RUNTIME_PACKAGE_DDLM_X86_PACKAGEFAMILYNAME "Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-x8-p1_8wekyb3d8bbwe"
#define WINDOWSAPPSDK_RUNTIME_PACKAGE_DDLM_X86_PACKAGEFAMILYNAME_W L"Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-x8-p1_8wekyb3d8bbwe"
#define WINDOWSAPPSDK_RUNTIME_PACKAGE_DDLM_X64_PACKAGEFAMILYNAME "Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-x6-p1_8wekyb3d8bbwe"
#define WINDOWSAPPSDK_RUNTIME_PACKAGE_DDLM_X64_PACKAGEFAMILYNAME_W L"Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-x6-p1_8wekyb3d8bbwe"
#define WINDOWSAPPSDK_RUNTIME_PACKAGE_DDLM_ARM64_PACKAGEFAMILYNAME "Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-a6-p1_8wekyb3d8bbwe"
#define WINDOWSAPPSDK_RUNTIME_PACKAGE_DDLM_ARM64_PACKAGEFAMILYNAME_W L"Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-a6-p1_8wekyb3d8bbwe"
#ifdef RC_INVOKED
// Only first 31 characters are significant for ResourceCompiler macro names (anything beyond that's silently ignored)
// These definitions provide RC-compatible equivalents to the macros above. Here's the translation key:
// * WAS == WINDOWSAPPSDK
// * WASR == WINDOWSAPPSDK_RUNTIME
// * FMT == FORMATTED
// * STAG == SHORTTAG
// * PKG == PACKAGE
// * FAMILY == PACKAGEFAMILYNAME
// Release information
#define WAS_RELEASE_MAJOR 1
#define WAS_RELEASE_MINOR 5
#define WAS_RELEASE_PATCH 0
#define WAS_RELEASE_MAJORMINOR 0x00010005
#define WAS_RELEASE_CHANNEL "preview"
#define WAS_RELEASE_CHANNEL_W L"preview"
#define WAS_RELEASE_VERSION_TAG "preview1"
#define WAS_RELEASE_VERSION_TAG_W L"preview1"
#define WAS_RELEASE_VERSION_STAG "p1"
#define WAS_RELEASE_VERSION_STAG_W L"p1"
#define WAS_RELEASE_FMT_VERSION_TAG "-preview1"
#define WAS_RELEASE_FMT_VERSION_TAG_W L"-preview1"
#define WAS_RELEASE_FMT_VERSION_STAG "-p1"
#define WAS_RELEASE_FMT_VERSION_STAG_W L"-p1"
// Runtime information
#define WASR_IDENTITY_PUBLISHER "CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US"
#define WASR_IDENTITY_PUBLISHER_W L"CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US"
#define WASR_IDENTITY_PUBLISHERID "8wekyb3d8bbwe"
#define WASR_IDENTITY_PUBLISHERID_W L"8wekyb3d8bbwe"
#define WASR_VERSION_MAJOR 5000
#define WASR_VERSION_MINOR 35
#define WASR_VERSION_BUILD 2034
#define WASR_VERSION_REVISION 0
#define WASR_VERSION_UINT64 0x1388002307F20000
#define WASR_VERSION_DOTQUADSTRING "5000.35.2034.0"
#define WASR_VERSION_DOTQUADSTRING_W L"5000.35.2034.0"
#define WASR_PKG_FRAMEWORK_FAMILY "Microsoft.WindowsAppRuntime.1.5-preview1_8wekyb3d8bbwe"
#define WASR_PKG_FRAMEWORK_FAMILY_W L"Microsoft.WindowsAppRuntime.1.5-preview1_8wekyb3d8bbwe"
#define WASR_PKG_MAIN_FAMILY "MicrosoftCorporationII.WinAppRuntime.Main.1.5-p1_8wekyb3d8bbwe"
#define WASR_PKG_MAIN_FAMILY_W L"MicrosoftCorporationII.WinAppRuntime.Main.1.5-p1_8wekyb3d8bbwe"
#define WASR_PKG_SINGLETON_FAMILY "MicrosoftCorporationII.WinAppRuntime.Singleton-p1_8wekyb3d8bbwe"
#define WASR_PKG_SINGLETON_FAMILY_W L"MicrosoftCorporationII.WinAppRuntime.Singleton-p1_8wekyb3d8bbwe"
#define WASR_PKG_DDLM_X86_FAMILY "Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-x8-p1_8wekyb3d8bbwe"
#define WASR_PKG_DDLM_X86_FAMILY_W L"Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-x8-p1_8wekyb3d8bbwe"
#define WASR_PKG_DDLM_X64_FAMILY "Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-x6-p1_8wekyb3d8bbwe"
#define WASR_PKG_DDLM_X64_FAMILY_W L"Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-x6-p1_8wekyb3d8bbwe"
#define WASR_PKG_DDLM_ARM64_FAMILY "Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-a6-p1_8wekyb3d8bbwe"
#define WASR_PKG_DDLM_ARM64_FAMILY_W L"Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-a6-p1_8wekyb3d8bbwe"
#endif
#ifdef __cplusplus
#include <stdint.h>
namespace Microsoft::WindowsAppSDK
{
/// Build-time constants for the Windows App SDK release
namespace Release
{
/// The major version of the Windows App SDK release.
constexpr uint16_t Major = 1;
/// The minor version of the Windows App SDK release.
constexpr uint16_t Minor = 5;
/// The patch version of the Windows App SDK release.
constexpr uint16_t Patch = 0;
/// The major and minor version of the Windows App SDK release, encoded as a uint32_t (0xMMMMNNNN where M=major, N=minor).
constexpr uint32_t MajorMinor = 0x00010005;
/// The Windows App SDK release's channel; for example, "preview", or empty string for stable.
constexpr PCWSTR Channel = L"preview";
/// The Windows App SDK release's version tag; for example, "preview2", or empty string for stable.
constexpr PCWSTR VersionTag = L"preview1";
/// The Windows App SDK release's short-form version tag; for example, "p2", or empty string for stable.
constexpr PCWSTR VersionShortTag = L"p1";
/// The Windows App SDK release's version tag, formatted for concatenation when constructing identifiers; for example, "-preview2", or empty string for stable.
constexpr PCWSTR FormattedVersionTag = L"-preview1";
/// The Windows App SDK release's short-form version tag, formatted for concatenation when constructing identifiers; for example, "-p2", or empty string for stable.
constexpr PCWSTR FormattedVersionShortTag = L"-p1";
}
/// Build-time constants for the Windows App SDK runtime
namespace Runtime
{
namespace Identity
{
/// The Windows App SDK runtime's package identity's Publisher.
constexpr PCWSTR Publisher = L"CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US";
/// The Windows App SDK runtime's package identity's PublisherId.
constexpr PCWSTR PublisherId = L"8wekyb3d8bbwe";
}
namespace Version
{
/// The major version of the Windows App SDK runtime; for example, 1000.
constexpr uint16_t Major = 5000;
/// The minor version of the Windows App SDK runtime; for example, 446.
constexpr uint16_t Minor = 35;
/// The build version of the Windows App SDK runtime; for example, 804.
constexpr uint16_t Build = 2034;
/// The revision version of the Windows App SDK runtime; for example, 0.
constexpr uint16_t Revision = 0;
/// The version of the Windows App SDK runtime, as a uint64l for example, 0x03E801BE03240000.
constexpr uint64_t UInt64 = 0x1388002307F20000;
/// The version of the Windows App SDK runtime, as a string (const wchar_t*); for example, "1000.446.804.0".
constexpr PCWSTR DotQuadString = L"5000.35.2034.0";
}
namespace Packages
{
namespace Framework
{
/// The Windows App SDK runtime's Framework package's family name.
constexpr PCWSTR PackageFamilyName = L"Microsoft.WindowsAppRuntime.1.5-preview1_8wekyb3d8bbwe";
}
namespace Main
{
/// The Windows App SDK runtime's Main package's family name.
constexpr PCWSTR PackageFamilyName = L"MicrosoftCorporationII.WinAppRuntime.Main.1.5-p1_8wekyb3d8bbwe";
}
namespace Singleton
{
/// The Windows App SDK runtime's Singleton package's family name.
constexpr PCWSTR PackageFamilyName = L"MicrosoftCorporationII.WinAppRuntime.Singleton-p1_8wekyb3d8bbwe";
}
namespace DDLM
{
namespace X86
{
/// The Windows App SDK runtime's Dynamic Dependency Lifetime Manager (DDLM) package's family name, for x86.
constexpr PCWSTR PackageFamilyName = L"Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-x8-p1_8wekyb3d8bbwe";
}
namespace X64
{
/// The Windows App SDK runtime's Dynamic Dependency Lifetime Manager (DDLM) package's family name, for x64.
constexpr PCWSTR PackageFamilyName = L"Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-x6-p1_8wekyb3d8bbwe";
}
namespace Arm64
{
/// The Windows App SDK runtime's Dynamic Dependency Lifetime Manager (DDLM) package's family name, for arm64.
constexpr PCWSTR PackageFamilyName = L"Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-a6-p1_8wekyb3d8bbwe";
}
}
}
}
/// Run-time query'able version information for the Windows App SDK.
struct VersionInfo
{
/// Run-time query'able version information for the Windows App SDK release
struct Release
{
/// The major version of the Windows App SDK release.
uint16_t Major;
/// The minor version of the Windows App SDK release.
uint16_t Minor;
/// The patch version of the Windows App SDK release.
uint16_t Patch;
/// The major and minor version of the Windows App SDK release, encoded as a uint32_t (0xMMMMNNNN where M=major, N=minor).
uint32_t MajorMinor;
/// The Windows App SDK release's channel; for example, "preview", or empty string for stable.
PCWSTR Channel;
/// The Windows App SDK release's version tag; for example, "preview2", or empty string for stable.
PCWSTR VersionTag;
/// The Windows App SDK release's short-form version tag; for example, "p2", or empty string for stable.
PCWSTR VersionShortTag;
} Release;
/// Run-time query'able version information for the Windows App SDK runtime
struct Runtime
{
struct Identity
{
/// The Windows App SDK runtime's package identity's Publisher.
PCWSTR Publisher;
/// The Windows App SDK runtime's package identity's PublisherId.
PCWSTR PublisherId;
} Identity;
struct Version
{
/// The major version of the Windows App SDK runtime; for example, 1000.
uint16_t Major;
/// The minor version of the Windows App SDK runtime; for example, 446.
uint16_t Minor;
/// The build version of the Windows App SDK runtime; for example, 804.
uint16_t Build;
/// The revision version of the Windows App SDK runtime; for example, 0.
uint16_t Revision;
/// The version of the Windows App SDK runtime, as a uint64l for example, 0x03E801BE03240000.
uint64_t UInt64;
/// The version of the Windows App SDK runtime, as a string (const wchar_t*); for example, "1000.446.804.0".
PCWSTR DotQuadString;
} Version;
} Runtime;
};
}
#endif // __cplusplus
#endif // _WINDOWSAPPSDK_VERSIONINFO_H__

5151
vendor/include/dwrite.h vendored Normal file

File diff suppressed because it is too large Load Diff

1924
vendor/include/dwrite_1.h vendored Normal file

File diff suppressed because it is too large Load Diff

980
vendor/include/dwrite_2.h vendored Normal file
View File

@ -0,0 +1,980 @@
//+--------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
// Abstract:
// DirectX Typography Services public API definitions.
//
//----------------------------------------------------------------------------
#ifndef DWRITE_2_H_INCLUDED
#define DWRITE_2_H_INCLUDED
#pragma once
#include "dwrite_1.h"
interface IDWriteFontFallback;
/// <summary>
/// How to align glyphs to the margin.
/// </summary>
enum DWRITE_OPTICAL_ALIGNMENT
{
/// <summary>
/// Align to the default metrics of the glyph.
/// </summary>
DWRITE_OPTICAL_ALIGNMENT_NONE,
/// <summary>
/// Align glyphs to the margins. Without this, some small whitespace
/// may be present between the text and the margin from the glyph's side
/// bearing values. Note that glyphs may still overhang outside the
/// margin, such as flourishes or italic slants.
/// </summary>
DWRITE_OPTICAL_ALIGNMENT_NO_SIDE_BEARINGS,
};
/// <summary>
/// Whether to enable grid-fitting of glyph outlines (a.k.a. hinting).
/// </summary>
enum DWRITE_GRID_FIT_MODE
{
/// <summary>
/// Choose grid fitting base on the font's gasp table information.
/// </summary>
DWRITE_GRID_FIT_MODE_DEFAULT,
/// <summary>
/// Always disable grid fitting, using the ideal glyph outlines.
/// </summary>
DWRITE_GRID_FIT_MODE_DISABLED,
/// <summary>
/// Enable grid fitting, adjusting glyph outlines for device pixel display.
/// </summary>
DWRITE_GRID_FIT_MODE_ENABLED
};
/// <summary>
/// Overall metrics associated with text after layout.
/// All coordinates are in device independent pixels (DIPs).
/// </summary>
struct DWRITE_TEXT_METRICS1 : DWRITE_TEXT_METRICS
{
/// <summary>
/// The height of the formatted text taking into account the
/// trailing whitespace at the end of each line, which will
/// matter for vertical reading directions.
/// </summary>
FLOAT heightIncludingTrailingWhitespace;
};
/// <summary>
/// The text renderer interface represents a set of application-defined
/// callbacks that perform rendering of text, inline objects, and decorations
/// such as underlines.
/// </summary>
DWRITE_BEGIN_INTERFACE(IDWriteTextRenderer1, "D3E0E934-22A0-427E-AAE4-7D9574B59DB1") : IDWriteTextRenderer
{
/// <summary>
/// IDWriteTextLayout::Draw calls this function to instruct the client to
/// render a run of glyphs.
/// </summary>
/// <param name="clientDrawingContext">The context passed to
/// IDWriteTextLayout::Draw.</param>
/// <param name="baselineOriginX">X-coordinate of the baseline.</param>
/// <param name="baselineOriginY">Y-coordinate of the baseline.</param>
/// <param name="orientationAngle">Orientation of the glyph run.</param>
/// <param name="measuringMode">Specifies measuring method for glyphs in
/// the run. Renderer implementations may choose different rendering
/// modes for given measuring methods, but best results are seen when
/// the rendering mode matches the corresponding measuring mode:
/// DWRITE_RENDERING_MODE_CLEARTYPE_NATURAL for DWRITE_MEASURING_MODE_NATURAL
/// DWRITE_RENDERING_MODE_CLEARTYPE_GDI_CLASSIC for DWRITE_MEASURING_MODE_GDI_CLASSIC
/// DWRITE_RENDERING_MODE_CLEARTYPE_GDI_NATURAL for DWRITE_MEASURING_MODE_GDI_NATURAL
/// </param>
/// <param name="glyphRun">The glyph run to draw.</param>
/// <param name="glyphRunDescription">Properties of the characters
/// associated with this run.</param>
/// <param name="clientDrawingEffect">The drawing effect set in
/// IDWriteTextLayout::SetDrawingEffect.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
/// <remarks>
/// If a non-identity orientation is passed, the glyph run should be
/// rotated around the given baseline x and y coordinates. The function
/// IDWriteAnalyzer2::GetGlyphOrientationTransform will return the
/// necessary transform for you, which can be combined with any existing
/// world transform on the drawing context.
/// </remarks>
STDMETHOD(DrawGlyphRun)(
_In_opt_ void* clientDrawingContext,
FLOAT baselineOriginX,
FLOAT baselineOriginY,
DWRITE_GLYPH_ORIENTATION_ANGLE orientationAngle,
DWRITE_MEASURING_MODE measuringMode,
_In_ DWRITE_GLYPH_RUN const* glyphRun,
_In_ DWRITE_GLYPH_RUN_DESCRIPTION const* glyphRunDescription,
_In_opt_ IUnknown* clientDrawingEffect
) PURE;
/// <summary>
/// IDWriteTextLayout::Draw calls this function to instruct the client to draw
/// an underline.
/// </summary>
/// <param name="clientDrawingContext">The context passed to
/// IDWriteTextLayout::Draw.</param>
/// <param name="baselineOriginX">X-coordinate of the baseline.</param>
/// <param name="baselineOriginY">Y-coordinate of the baseline.</param>
/// <param name="orientationAngle">Orientation of the underline.</param>
/// <param name="underline">Underline logical information.</param>
/// <param name="clientDrawingEffect">The drawing effect set in
/// IDWriteTextLayout::SetDrawingEffect.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
/// <remarks>
/// A single underline can be broken into multiple calls, depending on
/// how the formatting changes attributes. If font sizes/styles change
/// within an underline, the thickness and offset will be averaged
/// weighted according to characters.
///
/// To get the correct top coordinate of the underline rect, add
/// underline::offset to the baseline's Y. Otherwise the underline will
/// be immediately under the text. The x coordinate will always be passed
/// as the left side, regardless of text directionality. This simplifies
/// drawing and reduces the problem of round-off that could potentially
/// cause gaps or a double stamped alpha blend. To avoid alpha overlap,
/// round the end points to the nearest device pixel.
/// </remarks>
STDMETHOD(DrawUnderline)(
_In_opt_ void* clientDrawingContext,
FLOAT baselineOriginX,
FLOAT baselineOriginY,
DWRITE_GLYPH_ORIENTATION_ANGLE orientationAngle,
_In_ DWRITE_UNDERLINE const* underline,
_In_opt_ IUnknown* clientDrawingEffect
) PURE;
/// <summary>
/// IDWriteTextLayout::Draw calls this function to instruct the client to draw
/// a strikethrough.
/// </summary>
/// <param name="clientDrawingContext">The context passed to
/// IDWriteTextLayout::Draw.</param>
/// <param name="baselineOriginX">X-coordinate of the baseline.</param>
/// <param name="baselineOriginY">Y-coordinate of the baseline.</param>
/// <param name="orientationAngle">Orientation of the strikethrough.</param>
/// <param name="strikethrough">Strikethrough logical information.</param>
/// <param name="clientDrawingEffect">The drawing effect set in
/// IDWriteTextLayout::SetDrawingEffect.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
/// <remarks>
/// A single strikethrough can be broken into multiple calls, depending on
/// how the formatting changes attributes. Strikethrough is not averaged
/// across font sizes/styles changes.
/// To get the correct top coordinate of the strikethrough rect,
/// add strikethrough::offset to the baseline's Y.
/// Like underlines, the x coordinate will always be passed as the left side,
/// regardless of text directionality.
/// </remarks>
STDMETHOD(DrawStrikethrough)(
_In_opt_ void* clientDrawingContext,
FLOAT baselineOriginX,
FLOAT baselineOriginY,
DWRITE_GLYPH_ORIENTATION_ANGLE orientationAngle,
_In_ DWRITE_STRIKETHROUGH const* strikethrough,
_In_opt_ IUnknown* clientDrawingEffect
) PURE;
/// <summary>
/// IDWriteTextLayout::Draw calls this application callback when it needs to
/// draw an inline object.
/// </summary>
/// <param name="clientDrawingContext">The context passed to
/// IDWriteTextLayout::Draw.</param>
/// <param name="originX">X-coordinate at the top-left corner of the
/// inline object.</param>
/// <param name="originY">Y-coordinate at the top-left corner of the
/// inline object.</param>
/// <param name="orientationAngle">Orientation of the inline object.</param>
/// <param name="inlineObject">The object set using IDWriteTextLayout::SetInlineObject.</param>
/// <param name="isSideways">The object should be drawn on its side.</param>
/// <param name="isRightToLeft">The object is in an right-to-left context
/// and should be drawn flipped.</param>
/// <param name="clientDrawingEffect">The drawing effect set in
/// IDWriteTextLayout::SetDrawingEffect.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
/// <remarks>
/// The right-to-left flag is a hint to draw the appropriate visual for
/// that reading direction. For example, it would look strange to draw an
/// arrow pointing to the right to indicate a submenu. The sideways flag
/// similarly hints that the object is drawn in a different orientation.
/// If a non-identity orientation is passed, the top left of the inline
/// object should be rotated around the given x and y coordinates.
/// IDWriteAnalyzer2::GetGlyphOrientationTransform returns the necessary
/// transform for this.
/// </remarks>
STDMETHOD(DrawInlineObject)(
_In_opt_ void* clientDrawingContext,
FLOAT originX,
FLOAT originY,
DWRITE_GLYPH_ORIENTATION_ANGLE orientationAngle,
_In_ IDWriteInlineObject* inlineObject,
BOOL isSideways,
BOOL isRightToLeft,
_In_opt_ IUnknown* clientDrawingEffect
) PURE;
using IDWriteTextRenderer::DrawGlyphRun;
using IDWriteTextRenderer::DrawUnderline;
using IDWriteTextRenderer::DrawStrikethrough;
using IDWriteTextRenderer::DrawInlineObject;
};
/// <summary>
/// The format of text used for text layout.
/// </summary>
/// <remarks>
/// This object may not be thread-safe and it may carry the state of text format change.
/// </remarks>
DWRITE_BEGIN_INTERFACE(IDWriteTextFormat1, "5F174B49-0D8B-4CFB-8BCA-F1CCE9D06C67") : IDWriteTextFormat
{
/// <summary>
/// Set the preferred orientation of glyphs when using a vertical reading direction.
/// </summary>
/// <param name="glyphOrientation">Preferred glyph orientation.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
STDMETHOD(SetVerticalGlyphOrientation)(
DWRITE_VERTICAL_GLYPH_ORIENTATION glyphOrientation
) PURE;
/// <summary>
/// Get the preferred orientation of glyphs when using a vertical reading
/// direction.
/// </summary>
STDMETHOD_(DWRITE_VERTICAL_GLYPH_ORIENTATION, GetVerticalGlyphOrientation)() PURE;
/// <summary>
/// Set whether or not the last word on the last line is wrapped.
/// </summary>
/// <param name="isLastLineWrappingEnabled">Line wrapping option.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
STDMETHOD(SetLastLineWrapping)(
BOOL isLastLineWrappingEnabled
) PURE;
/// <summary>
/// Get whether or not the last word on the last line is wrapped.
/// </summary>
STDMETHOD_(BOOL, GetLastLineWrapping)() PURE;
/// <summary>
/// Set how the glyphs align to the edges the margin. Default behavior is
/// to align glyphs using their default glyphs metrics which include side
/// bearings.
/// </summary>
/// <param name="opticalAlignment">Optical alignment option.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
STDMETHOD(SetOpticalAlignment)(
DWRITE_OPTICAL_ALIGNMENT opticalAlignment
) PURE;
/// <summary>
/// Get how the glyphs align to the edges the margin.
/// </summary>
STDMETHOD_(DWRITE_OPTICAL_ALIGNMENT, GetOpticalAlignment)() PURE;
/// <summary>
/// Apply a custom font fallback onto layout. If none is specified,
/// layout uses the system fallback list.
/// </summary>
/// <param name="fontFallback">Custom font fallback created from
/// IDWriteFontFallbackBuilder::CreateFontFallback or from
/// IDWriteFactory2::GetSystemFontFallback.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
STDMETHOD(SetFontFallback)(
IDWriteFontFallback* fontFallback
) PURE;
/// <summary>
/// Get the current font fallback object.
/// </summary>
STDMETHOD(GetFontFallback)(
_COM_Outptr_ IDWriteFontFallback** fontFallback
) PURE;
};
/// <summary>
/// The text layout interface represents a block of text after it has
/// been fully analyzed and formatted.
///
/// All coordinates are in device independent pixels (DIPs).
/// </summary>
DWRITE_BEGIN_INTERFACE(IDWriteTextLayout2, "1093C18F-8D5E-43F0-B064-0917311B525E") : IDWriteTextLayout1
{
/// <summary>
/// GetMetrics retrieves overall metrics for the formatted string.
/// </summary>
/// <param name="textMetrics">The returned metrics.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
/// <remarks>
/// Drawing effects like underline and strikethrough do not contribute
/// to the text size, which is essentially the sum of advance widths and
/// line heights. Additionally, visible swashes and other graphic
/// adornments may extend outside the returned width and height.
/// </remarks>
STDMETHOD(GetMetrics)(
_Out_ DWRITE_TEXT_METRICS1* textMetrics
) PURE;
using IDWriteTextLayout::GetMetrics;
/// <summary>
/// Set the preferred orientation of glyphs when using a vertical reading direction.
/// </summary>
/// <param name="glyphOrientation">Preferred glyph orientation.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
STDMETHOD(SetVerticalGlyphOrientation)(
DWRITE_VERTICAL_GLYPH_ORIENTATION glyphOrientation
) PURE;
/// <summary>
/// Get the preferred orientation of glyphs when using a vertical reading
/// direction.
/// </summary>
STDMETHOD_(DWRITE_VERTICAL_GLYPH_ORIENTATION, GetVerticalGlyphOrientation)() PURE;
/// <summary>
/// Set whether or not the last word on the last line is wrapped.
/// </summary>
/// <param name="isLastLineWrappingEnabled">Line wrapping option.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
STDMETHOD(SetLastLineWrapping)(
BOOL isLastLineWrappingEnabled
) PURE;
/// <summary>
/// Get whether or not the last word on the last line is wrapped.
/// </summary>
STDMETHOD_(BOOL, GetLastLineWrapping)() PURE;
/// <summary>
/// Set how the glyphs align to the edges the margin. Default behavior is
/// to align glyphs using their default glyphs metrics which include side
/// bearings.
/// </summary>
/// <param name="opticalAlignment">Optical alignment option.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
STDMETHOD(SetOpticalAlignment)(
DWRITE_OPTICAL_ALIGNMENT opticalAlignment
) PURE;
/// <summary>
/// Get how the glyphs align to the edges the margin.
/// </summary>
STDMETHOD_(DWRITE_OPTICAL_ALIGNMENT, GetOpticalAlignment)() PURE;
/// <summary>
/// Apply a custom font fallback onto layout. If none is specified,
/// layout uses the system fallback list.
/// </summary>
/// <param name="fontFallback">Custom font fallback created from
/// IDWriteFontFallbackBuilder::CreateFontFallback or
/// IDWriteFactory2::GetSystemFontFallback.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
STDMETHOD(SetFontFallback)(
IDWriteFontFallback* fontFallback
) PURE;
/// <summary>
/// Get the current font fallback object.
/// </summary>
STDMETHOD(GetFontFallback)(
_COM_Outptr_ IDWriteFontFallback** fontFallback
) PURE;
};
/// <summary>
/// The text analyzer interface represents a set of application-defined
/// callbacks that perform rendering of text, inline objects, and decorations
/// such as underlines.
/// </summary>
DWRITE_BEGIN_INTERFACE(IDWriteTextAnalyzer2, "553A9FF3-5693-4DF7-B52B-74806F7F2EB9") : IDWriteTextAnalyzer1
{
/// <summary>
/// Returns 2x3 transform matrix for the respective angle to draw the
/// glyph run or other object.
/// </summary>
/// <param name="glyphOrientationAngle">The angle reported to one of the application callbacks,
/// including IDWriteTextAnalysisSink1::SetGlyphOrientation and IDWriteTextRenderer1::Draw*.</param>
/// <param name="isSideways">Whether the run's glyphs are sideways or not.</param>
/// <param name="originX">X origin of the element, be it a glyph run or underline or other.</param>
/// <param name="originY">Y origin of the element, be it a glyph run or underline or other.</param>
/// <param name="transform">Returned transform.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
/// <remarks>
/// This rotates around the given origin x and y, returning a translation component
/// such that the glyph run, text decoration, or inline object is drawn with the
/// right orientation at the expected coordinate.
/// </remarks>
STDMETHOD(GetGlyphOrientationTransform)(
DWRITE_GLYPH_ORIENTATION_ANGLE glyphOrientationAngle,
BOOL isSideways,
FLOAT originX,
FLOAT originY,
_Out_ DWRITE_MATRIX* transform
) PURE;
/// <summary>
/// Returns a list of typographic feature tags for the given script and language.
/// </summary>
/// <param name="fontFace">The font face to get features from.</param>
/// <param name="scriptAnalysis">Script analysis result from AnalyzeScript.</param>
/// <param name="localeName">The locale to use when selecting the feature,
/// such en-us or ja-jp.</param>
/// <param name="maxTagCount">Maximum tag count.</param>
/// <param name="actualTagCount">Actual tag count. If greater than
/// maxTagCount, E_NOT_SUFFICIENT_BUFFER is returned, and the call
/// should be retried with a larger buffer.</param>
/// <param name="tags">Feature tag list.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
STDMETHOD(GetTypographicFeatures)(
IDWriteFontFace* fontFace,
DWRITE_SCRIPT_ANALYSIS scriptAnalysis,
_In_opt_z_ WCHAR const* localeName,
UINT32 maxTagCount,
_Out_ UINT32* actualTagCount,
_Out_writes_(maxTagCount) DWRITE_FONT_FEATURE_TAG* tags
) PURE;
/// <summary>
/// Returns an array of which glyphs are affected by a given feature.
/// </summary>
/// <param name="fontFace">The font face to read glyph information from.</param>
/// <param name="scriptAnalysis">Script analysis result from AnalyzeScript.</param>
/// <param name="localeName">The locale to use when selecting the feature,
/// such en-us or ja-jp.</param>
/// <param name="featureTag">OpenType feature name to use, which may be one
/// of the DWRITE_FONT_FEATURE_TAG values or a custom feature using
/// DWRITE_MAKE_OPENTYPE_TAG.</param>
/// <param name="glyphCount">Number of glyph indices to check.</param>
/// <param name="glyphIndices">Glyph indices to check for feature application.</param>
/// <param name="featureApplies">Output of which glyphs are affected by the
/// feature, where for each glyph affected, the respective array index
/// will be 1. The result is returned per-glyph without regard to
/// neighboring context of adjacent glyphs.</param>
/// </remarks>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
STDMETHOD(CheckTypographicFeature)(
IDWriteFontFace* fontFace,
DWRITE_SCRIPT_ANALYSIS scriptAnalysis,
_In_opt_z_ WCHAR const* localeName,
DWRITE_FONT_FEATURE_TAG featureTag,
UINT32 glyphCount,
_In_reads_(glyphCount) UINT16 const* glyphIndices,
_Out_writes_(glyphCount) UINT8* featureApplies
) PURE;
using IDWriteTextAnalyzer1::GetGlyphOrientationTransform;
};
/// <summary>
/// A font fallback definition used for mapping characters to fonts capable of
/// supporting them.
/// </summary>
DWRITE_BEGIN_INTERFACE(IDWriteFontFallback, "EFA008F9-F7A1-48BF-B05C-F224713CC0FF") : IUnknown
{
/// <summary>
/// Determines an appropriate font to use to render the range of text.
/// </summary>
/// <param name="source">The text source implementation holds the text and
/// locale.</param>
/// <param name="textLength">Length of the text to analyze.</param>
/// <param name="baseFontCollection">Default font collection to use.</param>
/// <param name="baseFamilyName">Family name of the base font. If you pass
/// null, no matching will be done against the family.</param>
/// <param name="baseWeight">Desired weight.</param>
/// <param name="baseStyle">Desired style.</param>
/// <param name="baseStretch">Desired stretch.</param>
/// <param name="mappedLength">Length of text mapped to the mapped font.
/// This will always be less or equal to the input text length and
/// greater than zero (if the text length is non-zero) so that the
/// caller advances at least one character each call.</param>
/// <param name="mappedFont">The font that should be used to render the
/// first mappedLength characters of the text. If it returns NULL,
/// then no known font can render the text, and mappedLength is the
/// number of unsupported characters to skip.</param>
/// <param name="scale">Scale factor to multiply the em size of the
/// returned font by.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
STDMETHOD(MapCharacters)(
IDWriteTextAnalysisSource* analysisSource,
UINT32 textPosition,
UINT32 textLength,
_In_opt_ IDWriteFontCollection* baseFontCollection,
_In_opt_z_ WCHAR const* baseFamilyName,
DWRITE_FONT_WEIGHT baseWeight,
DWRITE_FONT_STYLE baseStyle,
DWRITE_FONT_STRETCH baseStretch,
_Out_range_(0, textLength) UINT32* mappedLength,
_COM_Outptr_result_maybenull_ IDWriteFont** mappedFont,
_Out_ FLOAT* scale
) PURE;
};
/// <summary>
/// Builder used to create a font fallback definition by appending a series of
/// fallback mappings, followed by a creation call.
/// </summary>
/// <remarks>
/// This object may not be thread-safe.
/// </remarks>
DWRITE_BEGIN_INTERFACE(IDWriteFontFallbackBuilder, "FD882D06-8ABA-4FB8-B849-8BE8B73E14DE") : IUnknown
{
/// <summary>
/// Appends a single mapping to the list. Call this once for each additional mapping.
/// </summary>
/// <param name="ranges">Unicode ranges that apply to this mapping.</param>
/// <param name="rangesCount">Number of Unicode ranges.</param>
/// <param name="localeName">Locale of the context (e.g. document locale).</param>
/// <param name="baseFamilyName">Base family name to match against, if applicable.</param>
/// <param name="fontCollection">Explicit font collection for this mapping (optional).</param>
/// <param name="targetFamilyNames">List of target family name strings.</param>
/// <param name="targetFamilyNamesCount">Number of target family names.</param>
/// <param name="scale">Scale factor to multiply the result target font by.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
STDMETHOD(AddMapping)(
_In_reads_(rangesCount) DWRITE_UNICODE_RANGE const* ranges,
UINT32 rangesCount,
_In_reads_(targetFamilyNamesCount) WCHAR const** targetFamilyNames,
UINT32 targetFamilyNamesCount,
_In_opt_ IDWriteFontCollection* fontCollection = NULL,
_In_opt_z_ WCHAR const* localeName = NULL,
_In_opt_z_ WCHAR const* baseFamilyName = NULL,
FLOAT scale = 1.0f
) PURE;
/// <summary>
/// Appends all the mappings from an existing font fallback object.
/// </summary>
/// <param name="fontFallback">Font fallback to read mappings from.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
STDMETHOD(AddMappings)(
IDWriteFontFallback* fontFallback
) PURE;
/// <summary>
/// Creates the finalized fallback object from the mappings added.
/// </summary>
/// <param name="fontFallback">Created fallback list.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
STDMETHOD(CreateFontFallback)(
_COM_Outptr_ IDWriteFontFallback** fontFallback
) PURE;
};
/// <summary>
/// DWRITE_COLOR_F
/// </summary>
#ifndef D3DCOLORVALUE_DEFINED
typedef struct _D3DCOLORVALUE {
union {
FLOAT r;
FLOAT dvR;
};
union {
FLOAT g;
FLOAT dvG;
};
union {
FLOAT b;
FLOAT dvB;
};
union {
FLOAT a;
FLOAT dvA;
};
} D3DCOLORVALUE;
#define D3DCOLORVALUE_DEFINED
#endif // D3DCOLORVALUE_DEFINED
typedef D3DCOLORVALUE DWRITE_COLOR_F;
/// <summary>
/// The IDWriteFont interface represents a physical font in a font collection.
/// </summary>
DWRITE_BEGIN_INTERFACE(IDWriteFont2, "29748ed6-8c9c-4a6a-be0b-d912e8538944") : IDWriteFont1
{
/// <summary>
/// Returns TRUE if the font contains tables that can provide color information
/// (including COLR, CPAL, SVG, CBDT, sbix tables), or FALSE if not. Note that
/// TRUE is returned even in the case when the font tables contain only grayscale
/// images.
/// </summary>
STDMETHOD_(BOOL, IsColorFont)() PURE;
};
/// <summary>
/// The interface that represents an absolute reference to a font face.
/// It contains font face type, appropriate file references and face identification data.
/// Various font data such as metrics, names and glyph outlines is obtained from IDWriteFontFace.
/// </summary>
DWRITE_BEGIN_INTERFACE(IDWriteFontFace2, "d8b768ff-64bc-4e66-982b-ec8e87f693f7") : IDWriteFontFace1
{
/// <summary>
/// Returns TRUE if the font contains tables that can provide color information
/// (including COLR, CPAL, SVG, CBDT, sbix tables), or FALSE if not. Note that
/// TRUE is returned even in the case when the font tables contain only grayscale
/// images.
/// </summary>
STDMETHOD_(BOOL, IsColorFont)() PURE;
/// <summary>
/// Returns the number of color palettes defined by the font. The return
/// value is zero if the font has no color information. Color fonts must
/// have at least one palette, with palette index zero being the default.
/// </summary>
STDMETHOD_(UINT32, GetColorPaletteCount)() PURE;
/// <summary>
/// Returns the number of entries in each color palette. All color palettes
/// in a font have the same number of palette entries. The return value is
/// zero if the font has no color information.
/// </summary>
STDMETHOD_(UINT32, GetPaletteEntryCount)() PURE;
/// <summary>
/// Reads color values from the font's color palette.
/// </summary>
/// <param name="colorPaletteIndex">Zero-based index of the color palette. If the
/// font does not have a palette with the specified index, the method returns
/// DWRITE_E_NOCOLOR.<param>
/// <param name="firstEntryIndex">Zero-based index of the first palette entry
/// to read.</param>
/// <param name="entryCount">Number of palette entries to read.</param>
/// <param name="paletteEntries">Array that receives the color values.<param>
/// <returns>
/// Standard HRESULT error code.
/// The return value is E_INVALIDARG if firstEntryIndex + entryCount is greater
/// than the actual number of palette entries as returned by GetPaletteEntryCount.
/// The return value is DWRITE_E_NOCOLOR if the font does not have a palette
/// with the specified palette index.
/// </returns>
STDMETHOD(GetPaletteEntries)(
UINT32 colorPaletteIndex,
UINT32 firstEntryIndex,
UINT32 entryCount,
_Out_writes_(entryCount) DWRITE_COLOR_F* paletteEntries
) PURE;
/// <summary>
/// Determines the recommended text rendering and grid-fit mode to be used based on the
/// font, size, world transform, and measuring mode.
/// </summary>
/// <param name="fontEmSize">Logical font size in DIPs.</param>
/// <param name="dpiX">Number of pixels per logical inch in the horizontal direction.</param>
/// <param name="dpiY">Number of pixels per logical inch in the vertical direction.</param>
/// <param name="transform">Specifies the world transform.</param>
/// <param name="outlineThreshold">Specifies the quality of the graphics system's outline rendering,
/// affects the size threshold above which outline rendering is used.</param>
/// <param name="measuringMode">Specifies the method used to measure during text layout. For proper
/// glyph spacing, the function returns a rendering mode that is compatible with the specified
/// measuring mode.</param>
/// <param name="renderingParams">Rendering parameters object. This parameter is necessary in case the rendering parameters
/// object overrides the rendering mode.</param>
/// <param name="renderingMode">Receives the recommended rendering mode.</param>
/// <param name="gridFitMode">Receives the recommended grid-fit mode.</param>
/// <remarks>
/// This method should be used to determine the actual rendering mode in cases where the rendering
/// mode of the rendering params object is DWRITE_RENDERING_MODE_DEFAULT, and the actual grid-fit
/// mode when the rendering params object is DWRITE_GRID_FIT_MODE_DEFAULT.
/// </remarks>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
STDMETHOD(GetRecommendedRenderingMode)(
FLOAT fontEmSize,
FLOAT dpiX,
FLOAT dpiY,
_In_opt_ DWRITE_MATRIX const* transform,
BOOL isSideways,
DWRITE_OUTLINE_THRESHOLD outlineThreshold,
DWRITE_MEASURING_MODE measuringMode,
_In_opt_ IDWriteRenderingParams* renderingParams,
_Out_ DWRITE_RENDERING_MODE* renderingMode,
_Out_ DWRITE_GRID_FIT_MODE* gridFitMode
) PURE;
using IDWriteFontFace1::GetRecommendedRenderingMode;
};
/// <summary>
/// Reserved palette entry index that does not specify any palette entry.
/// </summary>
#define DWRITE_NO_PALETTE_INDEX 0xFFFF
/// <summary>
/// Represents a color glyph run. The IDWriteFactory2::TranslateColorGlyphRun
/// method returns an ordered collection of color glyph runs, which can be
/// layered on top of each other to produce a color representation of the
/// given base glyph run.
/// </summary>
struct DWRITE_COLOR_GLYPH_RUN
{
/// <summary>
/// Glyph run to render.
/// </summary>
DWRITE_GLYPH_RUN glyphRun;
/// <summary>
/// Optional glyph run description.
/// </summary>
_Maybenull_ DWRITE_GLYPH_RUN_DESCRIPTION* glyphRunDescription;
/// <summary>
/// Location at which to draw this glyph run.
/// </summary>
FLOAT baselineOriginX;
FLOAT baselineOriginY;
/// <summary>
/// Color to use for this layer, if any. If the paletteIndex member is
/// DWRITE_NO_PALETTE_INDEX (0xFFFF) then no color is specifed by the font,
/// this member is set to { 0, 0, 0, 0 }, and the client should use the
/// current foreground brush. Otherwise, this member is set to a color from
/// the font's color palette, i.e., the same color that would be returned
/// by IDWriteFontFace2::GetPaletteEntries for the current palette index.
/// </summary>
DWRITE_COLOR_F runColor;
/// <summary>
/// Zero-based index of this layer's color entry in the current color
/// palette, or DWRITE_NO_PALETTE_INDEX (0xFFFF) if this layer
/// is to be rendered using the current foreground brush.
/// </summary>
UINT16 paletteIndex;
};
/// <summary>
/// Enumerator for an ordered collection of color glyph runs.
/// </summary>
DWRITE_BEGIN_INTERFACE(IDWriteColorGlyphRunEnumerator, "d31fbe17-f157-41a2-8d24-cb779e0560e8") : IUnknown
{
/// <summary>
/// Advances to the first or next color run. The runs are enumerated
/// in order from back to front.
/// </summary>
/// <param name="hasRun">Receives TRUE if there is a current run or
/// FALSE if the end of the sequence has been reached.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
STDMETHOD(MoveNext)(
_Out_ BOOL* hasRun
) PURE;
/// <summary>
/// Gets the current color glyph run.
/// </summary>
/// <param name="colorGlyphRun">Receives a pointer to the color
/// glyph run. The pointer remains valid until the next call to
/// MoveNext or until the interface is released.</param>
/// <returns>
/// Standard HRESULT error code. An error is returned if there is
/// no current glyph run, i.e., if MoveNext has not yet been called
/// or if the end of the sequence has been reached.
/// </returns>
STDMETHOD(GetCurrentRun)(
_Outptr_ DWRITE_COLOR_GLYPH_RUN const** colorGlyphRun
) PURE;
};
/// <summary>
/// The interface that represents text rendering settings for glyph rasterization and filtering.
/// </summary>
DWRITE_BEGIN_INTERFACE(IDWriteRenderingParams2, "F9D711C3-9777-40AE-87E8-3E5AF9BF0948") : IDWriteRenderingParams1
{
/// <summary>
/// Gets the grid fitting mode.
/// </summary>
STDMETHOD_(DWRITE_GRID_FIT_MODE, GetGridFitMode)() PURE;
};
/// <summary>
/// The root factory interface for all DWrite objects.
/// </summary>
DWRITE_BEGIN_INTERFACE(IDWriteFactory2, "0439fc60-ca44-4994-8dee-3a9af7b732ec") : IDWriteFactory1
{
/// <summary>
/// Get the system-appropriate font fallback mapping list.
/// </summary>
/// <param name="fontFallback">The system fallback list.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
STDMETHOD(GetSystemFontFallback)(
_COM_Outptr_ IDWriteFontFallback** fontFallback
) PURE;
/// <summary>
/// Create a custom font fallback builder.
/// </summary>
/// <param name="fontFallbackBuilder">Empty font fallback builder.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
STDMETHOD(CreateFontFallbackBuilder)(
_COM_Outptr_ IDWriteFontFallbackBuilder** fontFallbackBuilder
) PURE;
/// <summary>
/// Translates a glyph run to a sequence of color glyph runs, which can be
/// rendered to produce a color representation of the original "base" run.
/// </summary>
/// <param name="baselineOriginX">Horizontal origin of the base glyph run in
/// pre-transform coordinates.</param>
/// <param name="baselineOriginY">Vertical origin of the base glyph run in
/// pre-transform coordinates.</param>
/// <param name="glyphRun">Pointer to the original "base" glyph run.</param>
/// <param name="glyphRunDescription">Optional glyph run description.</param>
/// <param name="measuringMode">Measuring mode, needed to compute the origins
/// of each glyph.</param>
/// <param name="worldToDeviceTransform">Matrix converting from the client's
/// coordinate space to device coordinates (pixels), i.e., the world transform
/// multiplied by any DPI scaling.</param>
/// <param name="colorPaletteIndex">Zero-based index of the color palette to use.
/// Valid indices are less than the number of palettes in the font, as returned
/// by IDWriteFontFace2::GetColorPaletteCount.</param>
/// <param name="colorLayers">If the function succeeds, receives a pointer
/// to an enumerator object that can be used to obtain the color glyph runs.
/// If the base run has no color glyphs, then the output pointer is NULL
/// and the method returns DWRITE_E_NOCOLOR.</param>
/// <returns>
/// Returns DWRITE_E_NOCOLOR if the font has no color information, the base
/// glyph run does not contain any color glyphs, or the specified color palette
/// index is out of range. In this case, the client should render the base glyph
/// run. Otherwise, returns a standard HRESULT error code.
/// </returns>
STDMETHOD(TranslateColorGlyphRun)(
FLOAT baselineOriginX,
FLOAT baselineOriginY,
_In_ DWRITE_GLYPH_RUN const* glyphRun,
_In_opt_ DWRITE_GLYPH_RUN_DESCRIPTION const* glyphRunDescription,
DWRITE_MEASURING_MODE measuringMode,
_In_opt_ DWRITE_MATRIX const* worldToDeviceTransform,
UINT32 colorPaletteIndex,
_COM_Outptr_ IDWriteColorGlyphRunEnumerator** colorLayers
) PURE;
/// <summary>
/// Creates a rendering parameters object with the specified properties.
/// </summary>
/// <param name="gamma">The gamma value used for gamma correction, which must be greater than zero and cannot exceed 256.</param>
/// <param name="enhancedContrast">The amount of contrast enhancement, zero or greater.</param>
/// <param name="clearTypeLevel">The degree of ClearType level, from 0.0f (no ClearType) to 1.0f (full ClearType).</param>
/// <param name="pixelGeometry">The geometry of a device pixel.</param>
/// <param name="renderingMode">Method of rendering glyphs. In most cases, this should be DWRITE_RENDERING_MODE_DEFAULT to automatically use an appropriate mode.</param>
/// <param name="gridFitMode">How to grid fit glyph outlines. In most cases, this should be DWRITE_GRID_FIT_DEFAULT to automatically choose an appropriate mode.</param>
/// <param name="renderingParams">Holds the newly created rendering parameters object, or NULL in case of failure.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
STDMETHOD(CreateCustomRenderingParams)(
FLOAT gamma,
FLOAT enhancedContrast,
FLOAT grayscaleEnhancedContrast,
FLOAT clearTypeLevel,
DWRITE_PIXEL_GEOMETRY pixelGeometry,
DWRITE_RENDERING_MODE renderingMode,
DWRITE_GRID_FIT_MODE gridFitMode,
_COM_Outptr_ IDWriteRenderingParams2** renderingParams
) PURE;
using IDWriteFactory::CreateCustomRenderingParams;
using IDWriteFactory1::CreateCustomRenderingParams;
/// <summary>
/// Creates a glyph run analysis object, which encapsulates information
/// used to render a glyph run.
/// </summary>
/// <param name="glyphRun">Structure specifying the properties of the glyph run.</param>
/// <param name="transform">Optional transform applied to the glyphs and their positions. This transform is applied after the
/// scaling specified by the emSize and pixelsPerDip.</param>
/// <param name="renderingMode">Specifies the rendering mode, which must be one of the raster rendering modes (i.e., not default
/// and not outline).</param>
/// <param name="measuringMode">Specifies the method to measure glyphs.</param>
/// <param name="gridFitMode">How to grid-fit glyph outlines. This must be non-default.</param>
/// <param name="baselineOriginX">Horizontal position of the baseline origin, in DIPs.</param>
/// <param name="baselineOriginY">Vertical position of the baseline origin, in DIPs.</param>
/// <param name="glyphRunAnalysis">Receives a pointer to the newly created object.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
STDMETHOD(CreateGlyphRunAnalysis)(
_In_ DWRITE_GLYPH_RUN const* glyphRun,
_In_opt_ DWRITE_MATRIX const* transform,
DWRITE_RENDERING_MODE renderingMode,
DWRITE_MEASURING_MODE measuringMode,
DWRITE_GRID_FIT_MODE gridFitMode,
DWRITE_TEXT_ANTIALIAS_MODE antialiasMode,
FLOAT baselineOriginX,
FLOAT baselineOriginY,
_COM_Outptr_ IDWriteGlyphRunAnalysis** glyphRunAnalysis
) PURE;
using IDWriteFactory::CreateGlyphRunAnalysis;
};
#endif /* DWRITE_2_H_INCLUDED */

4677
vendor/include/dwrite_3.h vendored Normal file

File diff suppressed because it is too large Load Diff

45
vendor/include/dwrite_core.h vendored Normal file
View File

@ -0,0 +1,45 @@
#define DWRITE_CORE 1
#include "dwrite_3.h"
/// <summary>
/// Creates a factory object that is used for subsequent creation of individual DWriteCore objects.
/// </summary>
/// <param name="factoryType">Identifies whether the factory object will be shared or isolated.</param>
/// <param name="iid">Identifies the DirectWrite factory interface, such as UUIDOF(IDWriteFactory).</param>
/// <param name="factory">Receives the DirectWrite factory object.</param>
/// <returns>
/// Standard HRESULT error code.
/// </returns>
/// <remarks>
/// This is functionally the same as the DWriteCreateFactory function exported by the system version
/// of DirectWrite. The DWriteCore function has a different name to avoid ambiguity.
/// </remarks>
EXTERN_C HRESULT DWRITE_EXPORT DWriteCoreCreateFactory(
_In_ DWRITE_FACTORY_TYPE factoryType,
_In_ REFIID iid,
_COM_Outptr_ IUnknown** factory
);
/// <summary>
/// Registers an object that receives internal DWriteCore events.
/// </summary>
/// <param name="eventSink">Event sink object to register.</param>
/// <returns>Standard HRESULT error code.</returns>
/// <remarks>This method does NOT add a reference to the event sink object.
/// The caller is expected to hold a reference to the event sink object until
/// it later unregisters it by calling DWriteUnregisterEventSink.</remarks>
EXTERN_C HRESULT DWRITE_EXPORT DWriteCoreRegisterEventSink(
IDWriteEventSink* eventSink
);
/// <summary>
/// Unregisters an event sink object that was previously registered
/// using DWriteCoreRegisterEventSink.
/// </summary>
/// <param name="eventSink">Event sink object to unregister.</param>
/// </remarks>Since DWriteCore does not hold a reference to the event sink, this
/// call can be made by the event sink object's destructor.</remarks>
EXTERN_C void DWRITE_EXPORT DWriteCoreUnregisterEventSink(
IDWriteEventSink* eventSink
);

View File

@ -0,0 +1,970 @@
/* this ALWAYS GENERATED file contains the definitions for the interfaces */
/* File created by MIDL compiler version 8.01.0628 */
/* @@MIDL_FILE_HEADING( ) */
/* verify that the <rpcndr.h> version is high enough to compile this file*/
#ifndef __REQUIRED_RPCNDR_H_VERSION__
#define __REQUIRED_RPCNDR_H_VERSION__ 500
#endif
/* verify that the <rpcsal.h> version is high enough to compile this file*/
#ifndef __REQUIRED_RPCSAL_H_VERSION__
#define __REQUIRED_RPCSAL_H_VERSION__ 100
#endif
#include "rpc.h"
#include "rpcndr.h"
#ifndef __RPCNDR_H_VERSION__
#error this stub requires an updated version of <rpcndr.h>
#endif /* __RPCNDR_H_VERSION__ */
#ifndef COM_NO_WINDOWS_H
#include "windows.h"
#include "ole2.h"
#endif /*COM_NO_WINDOWS_H*/
#ifndef __microsoft2Eui2Examl2Ehosting2Ereferencetracker_h__
#define __microsoft2Eui2Examl2Ehosting2Ereferencetracker_h__
#if defined(_MSC_VER) && (_MSC_VER >= 1020)
#pragma once
#endif
#ifndef DECLSPEC_XFGVIRT
#if defined(_CONTROL_FLOW_GUARD_XFG)
#define DECLSPEC_XFGVIRT(base, func) __declspec(xfg_virtual(base, func))
#else
#define DECLSPEC_XFGVIRT(base, func)
#endif
#endif
/* Forward Declarations */
#ifndef __IReferenceTrackerTarget_FWD_DEFINED__
#define __IReferenceTrackerTarget_FWD_DEFINED__
typedef interface IReferenceTrackerTarget IReferenceTrackerTarget;
#endif /* __IReferenceTrackerTarget_FWD_DEFINED__ */
#ifndef __IReferenceTracker_FWD_DEFINED__
#define __IReferenceTracker_FWD_DEFINED__
typedef interface IReferenceTracker IReferenceTracker;
#endif /* __IReferenceTracker_FWD_DEFINED__ */
#ifndef __IReferenceTrackerManager_FWD_DEFINED__
#define __IReferenceTrackerManager_FWD_DEFINED__
typedef interface IReferenceTrackerManager IReferenceTrackerManager;
#endif /* __IReferenceTrackerManager_FWD_DEFINED__ */
#ifndef __IFindReferenceTargetsCallback_FWD_DEFINED__
#define __IFindReferenceTargetsCallback_FWD_DEFINED__
typedef interface IFindReferenceTargetsCallback IFindReferenceTargetsCallback;
#endif /* __IFindReferenceTargetsCallback_FWD_DEFINED__ */
#ifndef __IReferenceTrackerHost_FWD_DEFINED__
#define __IReferenceTrackerHost_FWD_DEFINED__
typedef interface IReferenceTrackerHost IReferenceTrackerHost;
#endif /* __IReferenceTrackerHost_FWD_DEFINED__ */
#ifndef __IReferenceTrackerExtension_FWD_DEFINED__
#define __IReferenceTrackerExtension_FWD_DEFINED__
typedef interface IReferenceTrackerExtension IReferenceTrackerExtension;
#endif /* __IReferenceTrackerExtension_FWD_DEFINED__ */
#ifndef __ITrackerOwner_FWD_DEFINED__
#define __ITrackerOwner_FWD_DEFINED__
typedef interface ITrackerOwner ITrackerOwner;
#endif /* __ITrackerOwner_FWD_DEFINED__ */
/* header files for imported files */
#include "oaidl.h"
#ifdef __cplusplus
extern "C"{
#endif
/* interface __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0000 */
/* [local] */
#pragma warning(push)
#pragma warning(disable:4668)
#pragma warning(disable:4001)
#pragma once
#pragma warning(pop)
#if (NTDDI_VERSION >= NTDDI_WIN8)
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0000_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0000_v0_0_s_ifspec;
#ifndef __IReferenceTrackerTarget_INTERFACE_DEFINED__
#define __IReferenceTrackerTarget_INTERFACE_DEFINED__
/* interface IReferenceTrackerTarget */
/* [unique][local][uuid][object] */
EXTERN_C const IID IID_IReferenceTrackerTarget;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("64bd43f8-bfee-4ec4-b7eb-2935158dae21")
IReferenceTrackerTarget : public IUnknown
{
public:
virtual ULONG STDMETHODCALLTYPE AddRefFromReferenceTracker( void) = 0;
virtual ULONG STDMETHODCALLTYPE ReleaseFromReferenceTracker( void) = 0;
virtual HRESULT STDMETHODCALLTYPE Peg( void) = 0;
virtual HRESULT STDMETHODCALLTYPE Unpeg( void) = 0;
};
#else /* C style interface */
typedef struct IReferenceTrackerTargetVtbl
{
BEGIN_INTERFACE
DECLSPEC_XFGVIRT(IUnknown, QueryInterface)
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
IReferenceTrackerTarget * This,
/* [in] */ REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
DECLSPEC_XFGVIRT(IUnknown, AddRef)
ULONG ( STDMETHODCALLTYPE *AddRef )(
IReferenceTrackerTarget * This);
DECLSPEC_XFGVIRT(IUnknown, Release)
ULONG ( STDMETHODCALLTYPE *Release )(
IReferenceTrackerTarget * This);
DECLSPEC_XFGVIRT(IReferenceTrackerTarget, AddRefFromReferenceTracker)
ULONG ( STDMETHODCALLTYPE *AddRefFromReferenceTracker )(
IReferenceTrackerTarget * This);
DECLSPEC_XFGVIRT(IReferenceTrackerTarget, ReleaseFromReferenceTracker)
ULONG ( STDMETHODCALLTYPE *ReleaseFromReferenceTracker )(
IReferenceTrackerTarget * This);
DECLSPEC_XFGVIRT(IReferenceTrackerTarget, Peg)
HRESULT ( STDMETHODCALLTYPE *Peg )(
IReferenceTrackerTarget * This);
DECLSPEC_XFGVIRT(IReferenceTrackerTarget, Unpeg)
HRESULT ( STDMETHODCALLTYPE *Unpeg )(
IReferenceTrackerTarget * This);
END_INTERFACE
} IReferenceTrackerTargetVtbl;
interface IReferenceTrackerTarget
{
CONST_VTBL struct IReferenceTrackerTargetVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define IReferenceTrackerTarget_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define IReferenceTrackerTarget_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define IReferenceTrackerTarget_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define IReferenceTrackerTarget_AddRefFromReferenceTracker(This) \
( (This)->lpVtbl -> AddRefFromReferenceTracker(This) )
#define IReferenceTrackerTarget_ReleaseFromReferenceTracker(This) \
( (This)->lpVtbl -> ReleaseFromReferenceTracker(This) )
#define IReferenceTrackerTarget_Peg(This) \
( (This)->lpVtbl -> Peg(This) )
#define IReferenceTrackerTarget_Unpeg(This) \
( (This)->lpVtbl -> Unpeg(This) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* __IReferenceTrackerTarget_INTERFACE_DEFINED__ */
#ifndef __IReferenceTracker_INTERFACE_DEFINED__
#define __IReferenceTracker_INTERFACE_DEFINED__
/* interface IReferenceTracker */
/* [unique][local][uuid][object] */
EXTERN_C const IID IID_IReferenceTracker;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("11d3b13a-180e-4789-a8be-7712882893e6")
IReferenceTracker : public IUnknown
{
public:
virtual HRESULT STDMETHODCALLTYPE ConnectFromTrackerSource( void) = 0;
virtual HRESULT STDMETHODCALLTYPE DisconnectFromTrackerSource( void) = 0;
virtual HRESULT STDMETHODCALLTYPE FindTrackerTargets(
/* [annotation][in] */
_In_ IFindReferenceTargetsCallback *callback) = 0;
virtual HRESULT STDMETHODCALLTYPE GetReferenceTrackerManager(
/* [annotation][out] */
_Out_ IReferenceTrackerManager **value) = 0;
virtual HRESULT STDMETHODCALLTYPE AddRefFromTrackerSource( void) = 0;
virtual HRESULT STDMETHODCALLTYPE ReleaseFromTrackerSource( void) = 0;
virtual HRESULT STDMETHODCALLTYPE PegFromTrackerSource( void) = 0;
};
#else /* C style interface */
typedef struct IReferenceTrackerVtbl
{
BEGIN_INTERFACE
DECLSPEC_XFGVIRT(IUnknown, QueryInterface)
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
IReferenceTracker * This,
/* [in] */ REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
DECLSPEC_XFGVIRT(IUnknown, AddRef)
ULONG ( STDMETHODCALLTYPE *AddRef )(
IReferenceTracker * This);
DECLSPEC_XFGVIRT(IUnknown, Release)
ULONG ( STDMETHODCALLTYPE *Release )(
IReferenceTracker * This);
DECLSPEC_XFGVIRT(IReferenceTracker, ConnectFromTrackerSource)
HRESULT ( STDMETHODCALLTYPE *ConnectFromTrackerSource )(
IReferenceTracker * This);
DECLSPEC_XFGVIRT(IReferenceTracker, DisconnectFromTrackerSource)
HRESULT ( STDMETHODCALLTYPE *DisconnectFromTrackerSource )(
IReferenceTracker * This);
DECLSPEC_XFGVIRT(IReferenceTracker, FindTrackerTargets)
HRESULT ( STDMETHODCALLTYPE *FindTrackerTargets )(
IReferenceTracker * This,
/* [annotation][in] */
_In_ IFindReferenceTargetsCallback *callback);
DECLSPEC_XFGVIRT(IReferenceTracker, GetReferenceTrackerManager)
HRESULT ( STDMETHODCALLTYPE *GetReferenceTrackerManager )(
IReferenceTracker * This,
/* [annotation][out] */
_Out_ IReferenceTrackerManager **value);
DECLSPEC_XFGVIRT(IReferenceTracker, AddRefFromTrackerSource)
HRESULT ( STDMETHODCALLTYPE *AddRefFromTrackerSource )(
IReferenceTracker * This);
DECLSPEC_XFGVIRT(IReferenceTracker, ReleaseFromTrackerSource)
HRESULT ( STDMETHODCALLTYPE *ReleaseFromTrackerSource )(
IReferenceTracker * This);
DECLSPEC_XFGVIRT(IReferenceTracker, PegFromTrackerSource)
HRESULT ( STDMETHODCALLTYPE *PegFromTrackerSource )(
IReferenceTracker * This);
END_INTERFACE
} IReferenceTrackerVtbl;
interface IReferenceTracker
{
CONST_VTBL struct IReferenceTrackerVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define IReferenceTracker_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define IReferenceTracker_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define IReferenceTracker_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define IReferenceTracker_ConnectFromTrackerSource(This) \
( (This)->lpVtbl -> ConnectFromTrackerSource(This) )
#define IReferenceTracker_DisconnectFromTrackerSource(This) \
( (This)->lpVtbl -> DisconnectFromTrackerSource(This) )
#define IReferenceTracker_FindTrackerTargets(This,callback) \
( (This)->lpVtbl -> FindTrackerTargets(This,callback) )
#define IReferenceTracker_GetReferenceTrackerManager(This,value) \
( (This)->lpVtbl -> GetReferenceTrackerManager(This,value) )
#define IReferenceTracker_AddRefFromTrackerSource(This) \
( (This)->lpVtbl -> AddRefFromTrackerSource(This) )
#define IReferenceTracker_ReleaseFromTrackerSource(This) \
( (This)->lpVtbl -> ReleaseFromTrackerSource(This) )
#define IReferenceTracker_PegFromTrackerSource(This) \
( (This)->lpVtbl -> PegFromTrackerSource(This) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* __IReferenceTracker_INTERFACE_DEFINED__ */
#ifndef __IReferenceTrackerManager_INTERFACE_DEFINED__
#define __IReferenceTrackerManager_INTERFACE_DEFINED__
/* interface IReferenceTrackerManager */
/* [unique][local][uuid][object] */
EXTERN_C const IID IID_IReferenceTrackerManager;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("3cf184b4-7ccb-4dda-8455-7e6ce99a3298")
IReferenceTrackerManager : public IUnknown
{
public:
virtual HRESULT STDMETHODCALLTYPE ReferenceTrackingStarted( void) = 0;
virtual HRESULT STDMETHODCALLTYPE FindTrackerTargetsCompleted(
/* [annotation][in] */
_In_ boolean findFailed) = 0;
virtual HRESULT STDMETHODCALLTYPE ReferenceTrackingCompleted( void) = 0;
virtual HRESULT STDMETHODCALLTYPE SetReferenceTrackerHost(
/* [annotation][in] */
_In_ IReferenceTrackerHost *value) = 0;
};
#else /* C style interface */
typedef struct IReferenceTrackerManagerVtbl
{
BEGIN_INTERFACE
DECLSPEC_XFGVIRT(IUnknown, QueryInterface)
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
IReferenceTrackerManager * This,
/* [in] */ REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
DECLSPEC_XFGVIRT(IUnknown, AddRef)
ULONG ( STDMETHODCALLTYPE *AddRef )(
IReferenceTrackerManager * This);
DECLSPEC_XFGVIRT(IUnknown, Release)
ULONG ( STDMETHODCALLTYPE *Release )(
IReferenceTrackerManager * This);
DECLSPEC_XFGVIRT(IReferenceTrackerManager, ReferenceTrackingStarted)
HRESULT ( STDMETHODCALLTYPE *ReferenceTrackingStarted )(
IReferenceTrackerManager * This);
DECLSPEC_XFGVIRT(IReferenceTrackerManager, FindTrackerTargetsCompleted)
HRESULT ( STDMETHODCALLTYPE *FindTrackerTargetsCompleted )(
IReferenceTrackerManager * This,
/* [annotation][in] */
_In_ boolean findFailed);
DECLSPEC_XFGVIRT(IReferenceTrackerManager, ReferenceTrackingCompleted)
HRESULT ( STDMETHODCALLTYPE *ReferenceTrackingCompleted )(
IReferenceTrackerManager * This);
DECLSPEC_XFGVIRT(IReferenceTrackerManager, SetReferenceTrackerHost)
HRESULT ( STDMETHODCALLTYPE *SetReferenceTrackerHost )(
IReferenceTrackerManager * This,
/* [annotation][in] */
_In_ IReferenceTrackerHost *value);
END_INTERFACE
} IReferenceTrackerManagerVtbl;
interface IReferenceTrackerManager
{
CONST_VTBL struct IReferenceTrackerManagerVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define IReferenceTrackerManager_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define IReferenceTrackerManager_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define IReferenceTrackerManager_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define IReferenceTrackerManager_ReferenceTrackingStarted(This) \
( (This)->lpVtbl -> ReferenceTrackingStarted(This) )
#define IReferenceTrackerManager_FindTrackerTargetsCompleted(This,findFailed) \
( (This)->lpVtbl -> FindTrackerTargetsCompleted(This,findFailed) )
#define IReferenceTrackerManager_ReferenceTrackingCompleted(This) \
( (This)->lpVtbl -> ReferenceTrackingCompleted(This) )
#define IReferenceTrackerManager_SetReferenceTrackerHost(This,value) \
( (This)->lpVtbl -> SetReferenceTrackerHost(This,value) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* __IReferenceTrackerManager_INTERFACE_DEFINED__ */
#ifndef __IFindReferenceTargetsCallback_INTERFACE_DEFINED__
#define __IFindReferenceTargetsCallback_INTERFACE_DEFINED__
/* interface IFindReferenceTargetsCallback */
/* [unique][local][uuid][object] */
EXTERN_C const IID IID_IFindReferenceTargetsCallback;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("04b3486c-4687-4229-8d14-505ab584dd88")
IFindReferenceTargetsCallback : public IUnknown
{
public:
virtual HRESULT STDMETHODCALLTYPE FoundTrackerTarget(
/* [annotation][in] */
_In_ IReferenceTrackerTarget *target) = 0;
};
#else /* C style interface */
typedef struct IFindReferenceTargetsCallbackVtbl
{
BEGIN_INTERFACE
DECLSPEC_XFGVIRT(IUnknown, QueryInterface)
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
IFindReferenceTargetsCallback * This,
/* [in] */ REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
DECLSPEC_XFGVIRT(IUnknown, AddRef)
ULONG ( STDMETHODCALLTYPE *AddRef )(
IFindReferenceTargetsCallback * This);
DECLSPEC_XFGVIRT(IUnknown, Release)
ULONG ( STDMETHODCALLTYPE *Release )(
IFindReferenceTargetsCallback * This);
DECLSPEC_XFGVIRT(IFindReferenceTargetsCallback, FoundTrackerTarget)
HRESULT ( STDMETHODCALLTYPE *FoundTrackerTarget )(
IFindReferenceTargetsCallback * This,
/* [annotation][in] */
_In_ IReferenceTrackerTarget *target);
END_INTERFACE
} IFindReferenceTargetsCallbackVtbl;
interface IFindReferenceTargetsCallback
{
CONST_VTBL struct IFindReferenceTargetsCallbackVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define IFindReferenceTargetsCallback_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define IFindReferenceTargetsCallback_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define IFindReferenceTargetsCallback_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define IFindReferenceTargetsCallback_FoundTrackerTarget(This,target) \
( (This)->lpVtbl -> FoundTrackerTarget(This,target) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* __IFindReferenceTargetsCallback_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0004 */
/* [local] */
typedef /* [public][public][v1_enum] */
enum __MIDL___MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0004_0001
{
XAML_REFERENCETRACKER_DISCONNECT_DEFAULT = 0,
XAML_REFERENCETRACKER_DISCONNECT_SUSPEND = 1
} XAML_REFERENCETRACKER_DISCONNECT;
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0004_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0004_v0_0_s_ifspec;
#ifndef __IReferenceTrackerHost_INTERFACE_DEFINED__
#define __IReferenceTrackerHost_INTERFACE_DEFINED__
/* interface IReferenceTrackerHost */
/* [unique][local][uuid][object] */
EXTERN_C const IID IID_IReferenceTrackerHost;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("29a71c6a-3c42-4416-a39d-e2825a07a773")
IReferenceTrackerHost : public IUnknown
{
public:
virtual HRESULT STDMETHODCALLTYPE DisconnectUnusedReferenceSources(
/* [in] */ XAML_REFERENCETRACKER_DISCONNECT options) = 0;
virtual HRESULT STDMETHODCALLTYPE ReleaseDisconnectedReferenceSources( void) = 0;
virtual HRESULT STDMETHODCALLTYPE NotifyEndOfReferenceTrackingOnThread( void) = 0;
virtual HRESULT STDMETHODCALLTYPE GetTrackerTarget(
IUnknown *unknown,
IReferenceTrackerTarget **newReference) = 0;
virtual HRESULT STDMETHODCALLTYPE AddMemoryPressure(
UINT64 bytesAllocated) = 0;
virtual HRESULT STDMETHODCALLTYPE RemoveMemoryPressure(
UINT64 bytesAllocated) = 0;
};
#else /* C style interface */
typedef struct IReferenceTrackerHostVtbl
{
BEGIN_INTERFACE
DECLSPEC_XFGVIRT(IUnknown, QueryInterface)
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
IReferenceTrackerHost * This,
/* [in] */ REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
DECLSPEC_XFGVIRT(IUnknown, AddRef)
ULONG ( STDMETHODCALLTYPE *AddRef )(
IReferenceTrackerHost * This);
DECLSPEC_XFGVIRT(IUnknown, Release)
ULONG ( STDMETHODCALLTYPE *Release )(
IReferenceTrackerHost * This);
DECLSPEC_XFGVIRT(IReferenceTrackerHost, DisconnectUnusedReferenceSources)
HRESULT ( STDMETHODCALLTYPE *DisconnectUnusedReferenceSources )(
IReferenceTrackerHost * This,
/* [in] */ XAML_REFERENCETRACKER_DISCONNECT options);
DECLSPEC_XFGVIRT(IReferenceTrackerHost, ReleaseDisconnectedReferenceSources)
HRESULT ( STDMETHODCALLTYPE *ReleaseDisconnectedReferenceSources )(
IReferenceTrackerHost * This);
DECLSPEC_XFGVIRT(IReferenceTrackerHost, NotifyEndOfReferenceTrackingOnThread)
HRESULT ( STDMETHODCALLTYPE *NotifyEndOfReferenceTrackingOnThread )(
IReferenceTrackerHost * This);
DECLSPEC_XFGVIRT(IReferenceTrackerHost, GetTrackerTarget)
HRESULT ( STDMETHODCALLTYPE *GetTrackerTarget )(
IReferenceTrackerHost * This,
IUnknown *unknown,
IReferenceTrackerTarget **newReference);
DECLSPEC_XFGVIRT(IReferenceTrackerHost, AddMemoryPressure)
HRESULT ( STDMETHODCALLTYPE *AddMemoryPressure )(
IReferenceTrackerHost * This,
UINT64 bytesAllocated);
DECLSPEC_XFGVIRT(IReferenceTrackerHost, RemoveMemoryPressure)
HRESULT ( STDMETHODCALLTYPE *RemoveMemoryPressure )(
IReferenceTrackerHost * This,
UINT64 bytesAllocated);
END_INTERFACE
} IReferenceTrackerHostVtbl;
interface IReferenceTrackerHost
{
CONST_VTBL struct IReferenceTrackerHostVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define IReferenceTrackerHost_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define IReferenceTrackerHost_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define IReferenceTrackerHost_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define IReferenceTrackerHost_DisconnectUnusedReferenceSources(This,options) \
( (This)->lpVtbl -> DisconnectUnusedReferenceSources(This,options) )
#define IReferenceTrackerHost_ReleaseDisconnectedReferenceSources(This) \
( (This)->lpVtbl -> ReleaseDisconnectedReferenceSources(This) )
#define IReferenceTrackerHost_NotifyEndOfReferenceTrackingOnThread(This) \
( (This)->lpVtbl -> NotifyEndOfReferenceTrackingOnThread(This) )
#define IReferenceTrackerHost_GetTrackerTarget(This,unknown,newReference) \
( (This)->lpVtbl -> GetTrackerTarget(This,unknown,newReference) )
#define IReferenceTrackerHost_AddMemoryPressure(This,bytesAllocated) \
( (This)->lpVtbl -> AddMemoryPressure(This,bytesAllocated) )
#define IReferenceTrackerHost_RemoveMemoryPressure(This,bytesAllocated) \
( (This)->lpVtbl -> RemoveMemoryPressure(This,bytesAllocated) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* __IReferenceTrackerHost_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0005 */
/* [local] */
#if (NTDDI_VERSION >= NTDDI_WIN10_RS2)
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0005_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0005_v0_0_s_ifspec;
#ifndef __IReferenceTrackerExtension_INTERFACE_DEFINED__
#define __IReferenceTrackerExtension_INTERFACE_DEFINED__
/* interface IReferenceTrackerExtension */
/* [unique][local][uuid][object] */
EXTERN_C const IID IID_IReferenceTrackerExtension;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("4e897caa-59d5-4613-8f8c-f7ebd1f399b0")
IReferenceTrackerExtension : public IUnknown
{
public:
};
#else /* C style interface */
typedef struct IReferenceTrackerExtensionVtbl
{
BEGIN_INTERFACE
DECLSPEC_XFGVIRT(IUnknown, QueryInterface)
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
IReferenceTrackerExtension * This,
/* [in] */ REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
DECLSPEC_XFGVIRT(IUnknown, AddRef)
ULONG ( STDMETHODCALLTYPE *AddRef )(
IReferenceTrackerExtension * This);
DECLSPEC_XFGVIRT(IUnknown, Release)
ULONG ( STDMETHODCALLTYPE *Release )(
IReferenceTrackerExtension * This);
END_INTERFACE
} IReferenceTrackerExtensionVtbl;
interface IReferenceTrackerExtension
{
CONST_VTBL struct IReferenceTrackerExtensionVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define IReferenceTrackerExtension_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define IReferenceTrackerExtension_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define IReferenceTrackerExtension_Release(This) \
( (This)->lpVtbl -> Release(This) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* __IReferenceTrackerExtension_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0006 */
/* [local] */
typedef struct TrackerHandle__
{
int unused;
} TrackerHandle__;
typedef /* [unique] */ __RPC_unique_pointer TrackerHandle__ *TrackerHandle;
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0006_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0006_v0_0_s_ifspec;
#ifndef __ITrackerOwner_INTERFACE_DEFINED__
#define __ITrackerOwner_INTERFACE_DEFINED__
/* interface ITrackerOwner */
/* [unique][local][uuid][object] */
EXTERN_C const IID IID_ITrackerOwner;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("eb24c20b-9816-4ac7-8cff-36f67a118f4e")
ITrackerOwner : public IUnknown
{
public:
virtual HRESULT STDMETHODCALLTYPE CreateTrackerHandle(
/* [retval][out] */ TrackerHandle *returnValue) = 0;
virtual HRESULT STDMETHODCALLTYPE DeleteTrackerHandle(
/* [in] */ TrackerHandle handle) = 0;
virtual HRESULT STDMETHODCALLTYPE SetTrackerValue(
/* [in] */ TrackerHandle handle,
/* [in] */ IUnknown *value) = 0;
virtual boolean STDMETHODCALLTYPE TryGetSafeTrackerValue(
/* [in] */ TrackerHandle handle,
/* [retval][out] */ IUnknown **returnValue) = 0;
};
#else /* C style interface */
typedef struct ITrackerOwnerVtbl
{
BEGIN_INTERFACE
DECLSPEC_XFGVIRT(IUnknown, QueryInterface)
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
ITrackerOwner * This,
/* [in] */ REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
DECLSPEC_XFGVIRT(IUnknown, AddRef)
ULONG ( STDMETHODCALLTYPE *AddRef )(
ITrackerOwner * This);
DECLSPEC_XFGVIRT(IUnknown, Release)
ULONG ( STDMETHODCALLTYPE *Release )(
ITrackerOwner * This);
DECLSPEC_XFGVIRT(ITrackerOwner, CreateTrackerHandle)
HRESULT ( STDMETHODCALLTYPE *CreateTrackerHandle )(
ITrackerOwner * This,
/* [retval][out] */ TrackerHandle *returnValue);
DECLSPEC_XFGVIRT(ITrackerOwner, DeleteTrackerHandle)
HRESULT ( STDMETHODCALLTYPE *DeleteTrackerHandle )(
ITrackerOwner * This,
/* [in] */ TrackerHandle handle);
DECLSPEC_XFGVIRT(ITrackerOwner, SetTrackerValue)
HRESULT ( STDMETHODCALLTYPE *SetTrackerValue )(
ITrackerOwner * This,
/* [in] */ TrackerHandle handle,
/* [in] */ IUnknown *value);
DECLSPEC_XFGVIRT(ITrackerOwner, TryGetSafeTrackerValue)
boolean ( STDMETHODCALLTYPE *TryGetSafeTrackerValue )(
ITrackerOwner * This,
/* [in] */ TrackerHandle handle,
/* [retval][out] */ IUnknown **returnValue);
END_INTERFACE
} ITrackerOwnerVtbl;
interface ITrackerOwner
{
CONST_VTBL struct ITrackerOwnerVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define ITrackerOwner_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define ITrackerOwner_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define ITrackerOwner_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define ITrackerOwner_CreateTrackerHandle(This,returnValue) \
( (This)->lpVtbl -> CreateTrackerHandle(This,returnValue) )
#define ITrackerOwner_DeleteTrackerHandle(This,handle) \
( (This)->lpVtbl -> DeleteTrackerHandle(This,handle) )
#define ITrackerOwner_SetTrackerValue(This,handle,value) \
( (This)->lpVtbl -> SetTrackerValue(This,handle,value) )
#define ITrackerOwner_TryGetSafeTrackerValue(This,handle,returnValue) \
( (This)->lpVtbl -> TryGetSafeTrackerValue(This,handle,returnValue) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* __ITrackerOwner_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0007 */
/* [local] */
#endif // NTDDI_VERSION >= NTDDI_WIN10_RS2
#endif // NTDDI_VERSION >= NTDDI_WIN8
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0007_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0007_v0_0_s_ifspec;
/* Additional Prototypes for ALL interfaces */
/* end of Additional Prototypes */
#ifdef __cplusplus
}
#endif
#endif

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,177 @@
/* this ALWAYS GENERATED file contains the definitions for the interfaces */
/* File created by MIDL compiler version 8.01.0628 */
/* @@MIDL_FILE_HEADING( ) */
/* verify that the <rpcndr.h> version is high enough to compile this file*/
#ifndef __REQUIRED_RPCNDR_H_VERSION__
#define __REQUIRED_RPCNDR_H_VERSION__ 500
#endif
/* verify that the <rpcsal.h> version is high enough to compile this file*/
#ifndef __REQUIRED_RPCSAL_H_VERSION__
#define __REQUIRED_RPCSAL_H_VERSION__ 100
#endif
#include "rpc.h"
#include "rpcndr.h"
#ifndef __RPCNDR_H_VERSION__
#error this stub requires an updated version of <rpcndr.h>
#endif /* __RPCNDR_H_VERSION__ */
#ifndef COM_NO_WINDOWS_H
#include "windows.h"
#include "ole2.h"
#endif /*COM_NO_WINDOWS_H*/
#ifndef __microsoft2Eui2Examl2Ewindow_h__
#define __microsoft2Eui2Examl2Ewindow_h__
#if defined(_MSC_VER) && (_MSC_VER >= 1020)
#pragma once
#endif
#ifndef DECLSPEC_XFGVIRT
#if defined(_CONTROL_FLOW_GUARD_XFG)
#define DECLSPEC_XFGVIRT(base, func) __declspec(xfg_virtual(base, func))
#else
#define DECLSPEC_XFGVIRT(base, func)
#endif
#endif
/* Forward Declarations */
#ifndef __IWindowNative_FWD_DEFINED__
#define __IWindowNative_FWD_DEFINED__
typedef interface IWindowNative IWindowNative;
#endif /* __IWindowNative_FWD_DEFINED__ */
/* header files for imported files */
#include "oaidl.h"
#ifdef __cplusplus
extern "C"{
#endif
/* interface __MIDL_itf_microsoft2Eui2Examl2Ewindow_0000_0000 */
/* [local] */
#if (NTDDI_VERSION >= NTDDI_WIN10_RS4)
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ewindow_0000_0000_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ewindow_0000_0000_v0_0_s_ifspec;
#ifndef __IWindowNative_INTERFACE_DEFINED__
#define __IWindowNative_INTERFACE_DEFINED__
/* interface IWindowNative */
/* [unique][local][uuid][object] */
EXTERN_C const IID IID_IWindowNative;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("EECDBF0E-BAE9-4CB6-A68E-9598E1CB57BB")
IWindowNative : public IUnknown
{
public:
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_WindowHandle(
/* [retval][out] */ HWND *hWnd) = 0;
};
#else /* C style interface */
typedef struct IWindowNativeVtbl
{
BEGIN_INTERFACE
DECLSPEC_XFGVIRT(IUnknown, QueryInterface)
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
IWindowNative * This,
/* [in] */ REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
DECLSPEC_XFGVIRT(IUnknown, AddRef)
ULONG ( STDMETHODCALLTYPE *AddRef )(
IWindowNative * This);
DECLSPEC_XFGVIRT(IUnknown, Release)
ULONG ( STDMETHODCALLTYPE *Release )(
IWindowNative * This);
DECLSPEC_XFGVIRT(IWindowNative, get_WindowHandle)
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_WindowHandle )(
IWindowNative * This,
/* [retval][out] */ HWND *hWnd);
END_INTERFACE
} IWindowNativeVtbl;
interface IWindowNative
{
CONST_VTBL struct IWindowNativeVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define IWindowNative_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define IWindowNative_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define IWindowNative_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define IWindowNative_get_WindowHandle(This,hWnd) \
( (This)->lpVtbl -> get_WindowHandle(This,hWnd) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* __IWindowNative_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_microsoft2Eui2Examl2Ewindow_0000_0001 */
/* [local] */
#endif // NTDDI_VERSION >= NTDDI_WIN10_RS4
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ewindow_0000_0001_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ewindow_0000_0001_v0_0_s_ifspec;
/* Additional Prototypes for ALL interfaces */
/* end of Additional Prototypes */
#ifdef __cplusplus
}
#endif
#endif

View File

@ -0,0 +1,25 @@
// Copyright (c) Microsoft Corporation and Contributors.
// Licensed under the MIT License.
namespace wil
{
#if defined(_APISETLIBLOADER_) && !defined(__WIL_APISETLIBLOADER_)
#define __WIL_APISETLIBLOADER_
typedef unique_any<DLL_DIRECTORY_COOKIE, decltype(&::RemoveDllDirectory), ::RemoveDllDirectory> unique_dll_directory_cookie;
#endif // __WIL_APISETLIBLOADER_
#if defined(MSIXDYNAMICDEPENDENCY_H) && !defined(__WIL_MSIXDYNAMICDEPENDENCY_H)
#define __WIL_MSIXDYNAMICDEPENDENCY_H
typedef unique_any<MDD_PACKAGEDEPENDENCY_CONTEXT, decltype(&::MddRemovePackageDependency), ::MddRemovePackageDependency> unique_mdd_package_dependency_context;
#endif // __WIL_MSIXDYNAMICDEPENDENCY_H
#if defined(_APPMODEL_H_) && !defined(__WIL_APPMODEL_H_) && WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP)
#define __WIL_APPMODEL_H_
typedef unique_any<PACKAGE_INFO_REFERENCE, decltype(&::ClosePackageInfo), ::ClosePackageInfo> unique_package_info_reference;
#endif // __WIL_APPMODEL_H_
#if defined(__WIL_APPMODEL_H_) && !defined(__WIL_APPMODEL_H_STL) && defined(WIL_RESOURCE_STL)
#define __WIL_APPMODEL_H_STL
typedef shared_any<unique_package_info_reference> shared_package_info_reference;
typedef weak_any<shared_package_info_reference> weak_package_info_reference;
#endif // __WIL_APPMODEL_H_STL
}

702
vendor/include/winrtdirect3d11.h vendored Normal file
View File

@ -0,0 +1,702 @@
/* Header file automatically generated from winrtdirect3d11.idl */
/*
* File built with Microsoft(R) MIDLRT Compiler Engine Version 10.00.0231
*/
#pragma warning( disable: 4049 ) /* more than 64k source lines */
/* verify that the <rpcndr.h> version is high enough to compile this file*/
#ifndef __REQUIRED_RPCNDR_H_VERSION__
#define __REQUIRED_RPCNDR_H_VERSION__ 500
#endif
/* verify that the <rpcsal.h> version is high enough to compile this file*/
#ifndef __REQUIRED_RPCSAL_H_VERSION__
#define __REQUIRED_RPCSAL_H_VERSION__ 100
#endif
#include <rpc.h>
#include <rpcndr.h>
#ifndef __RPCNDR_H_VERSION__
#error this stub requires an updated version of <rpcndr.h>
#endif /* __RPCNDR_H_VERSION__ */
#ifndef COM_NO_WINDOWS_H
#include <windows.h>
#include <ole2.h>
#endif /*COM_NO_WINDOWS_H*/
#ifndef __winrtdirect3d11_h__
#define __winrtdirect3d11_h__
#ifndef __winrtdirect3d11_p_h__
#define __winrtdirect3d11_p_h__
#pragma once
// Ensure that the setting of the /ns_prefix command line switch is consistent for all headers.
// If you get an error from the compiler indicating "warning C4005: 'CHECK_NS_PREFIX_STATE': macro redefinition", this
// indicates that you have included two different headers with different settings for the /ns_prefix MIDL command line switch
#if !defined(DISABLE_NS_PREFIX_CHECKS)
#if defined(MIDL_NS_PREFIX)
#define CHECK_NS_PREFIX_STATE "always"
#else
#define CHECK_NS_PREFIX_STATE "never"
#endif // MIDL_NS_PREFIX
#endif // !defined(DISABLE_NS_PREFIX_CHECKS)
#pragma push_macro("ABI_CONCAT")
#pragma push_macro("ABI_PARAMETER")
#pragma push_macro("ABI_NAMESPACE_BEGIN")
#pragma push_macro("ABI_NAMESPACE_END")
#pragma push_macro("C_IID")
#undef ABI_CONCAT
#undef ABI_PARAMETER
#undef ABI_NAMESPACE_BEGIN
#undef ABI_NAMESPACE_END
#undef C_IID
#define ABI_CONCAT(x,y) x##y
// /ns_prefix optional state
#if defined(MIDL_NS_PREFIX)
#if defined(__cplusplus) && !defined(CINTERFACE)
#define ABI_PARAMETER(x) ABI::x
#define ABI_NAMESPACE_BEGIN namespace ABI {
#define ABI_NAMESPACE_END }
#else // !defined(__cplusplus) || defined(CINTERFACE)
#define C_ABI_PARAMETER(x) ABI_CONCAT(__x_ABI_C, x)
#endif // !defined(__cplusplus)
#define C_IID(x) ABI_CONCAT(IID___x_ABI_C, x)
#else
#if defined(__cplusplus) && !defined(CINTERFACE)
#define ABI_PARAMETER(x) x
#define ABI_NAMESPACE_BEGIN
#define ABI_NAMESPACE_END
#else // !defined(__cplusplus) || defined(CINTERFACE)
#define C_ABI_PARAMETER(x) ABI_CONCAT(__x_, x)
#endif // !defined(__cplusplus)
#define C_IID(x) ABI_CONCAT(IID___x_, x)
#endif // defined(MIDL_NS_PREFIX)
#pragma push_macro("MIDL_CONST_ID")
#undef MIDL_CONST_ID
#define MIDL_CONST_ID const __declspec(selectany)
// API Contract Inclusion Definitions
#if !defined(SPECIFIC_API_CONTRACT_DEFINITIONS)
#if !defined(WINDOWS_APPLICATIONMODEL_CALLS_CALLSPHONECONTRACT_VERSION)
#define WINDOWS_APPLICATIONMODEL_CALLS_CALLSPHONECONTRACT_VERSION 0x70000
#endif // defined(WINDOWS_APPLICATIONMODEL_CALLS_CALLSPHONECONTRACT_VERSION)
#if !defined(WINDOWS_FOUNDATION_FOUNDATIONCONTRACT_VERSION)
#define WINDOWS_FOUNDATION_FOUNDATIONCONTRACT_VERSION 0x40000
#endif // defined(WINDOWS_FOUNDATION_FOUNDATIONCONTRACT_VERSION)
#if !defined(WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION)
#define WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION 0x130000
#endif // defined(WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION)
#if !defined(WINDOWS_NETWORKING_SOCKETS_CONTROLCHANNELTRIGGERCONTRACT_VERSION)
#define WINDOWS_NETWORKING_SOCKETS_CONTROLCHANNELTRIGGERCONTRACT_VERSION 0x30000
#endif // defined(WINDOWS_NETWORKING_SOCKETS_CONTROLCHANNELTRIGGERCONTRACT_VERSION)
#if !defined(WINDOWS_PHONE_PHONECONTRACT_VERSION)
#define WINDOWS_PHONE_PHONECONTRACT_VERSION 0x10000
#endif // defined(WINDOWS_PHONE_PHONECONTRACT_VERSION)
#if !defined(WINDOWS_PHONE_PHONEINTERNALCONTRACT_VERSION)
#define WINDOWS_PHONE_PHONEINTERNALCONTRACT_VERSION 0x10000
#endif // defined(WINDOWS_PHONE_PHONEINTERNALCONTRACT_VERSION)
#if !defined(WINDOWS_UI_WEBUI_CORE_WEBUICOMMANDBARCONTRACT_VERSION)
#define WINDOWS_UI_WEBUI_CORE_WEBUICOMMANDBARCONTRACT_VERSION 0x10000
#endif // defined(WINDOWS_UI_WEBUI_CORE_WEBUICOMMANDBARCONTRACT_VERSION)
#endif // defined(SPECIFIC_API_CONTRACT_DEFINITIONS)
// Header files for imported files
#include "inspectable.h"
#include "Windows.Foundation.h"
#include "WinRTDirectXCommon.h"
#if defined(__cplusplus) && !defined(CINTERFACE)
/* Forward Declarations */
#ifndef ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_FWD_DEFINED__
#define ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_FWD_DEFINED__
ABI_NAMESPACE_BEGIN
namespace Windows {
namespace Graphics {
namespace DirectX {
namespace Direct3D11 {
interface IDirect3DDevice;
} /* Direct3D11 */
} /* DirectX */
} /* Graphics */
} /* Windows */
ABI_NAMESPACE_END
#define __x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice ABI_PARAMETER(Windows::Graphics::DirectX::Direct3D11::IDirect3DDevice)
#endif // ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_FWD_DEFINED__
#ifndef ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_FWD_DEFINED__
#define ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_FWD_DEFINED__
ABI_NAMESPACE_BEGIN
namespace Windows {
namespace Graphics {
namespace DirectX {
namespace Direct3D11 {
interface IDirect3DSurface;
} /* Direct3D11 */
} /* DirectX */
} /* Graphics */
} /* Windows */
ABI_NAMESPACE_END
#define __x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface ABI_PARAMETER(Windows::Graphics::DirectX::Direct3D11::IDirect3DSurface)
#endif // ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_FWD_DEFINED__
#pragma warning (push)
#pragma warning (disable:4668)
#pragma warning (disable:4001)
#pragma once
#pragma warning (pop)
/*
*
* Typedef of Windows.Graphics.DirectX.Direct3D11.Direct3DMultisampleDescription
*
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
*
*
*/
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
ABI_NAMESPACE_BEGIN
namespace Windows {
namespace Graphics {
namespace DirectX {
namespace Direct3D11 {
/* [contract, version, version] */
typedef
struct Direct3DMultisampleDescription
{
INT32 Count;
INT32 Quality;
} Direct3DMultisampleDescription;
} /* Direct3D11 */
} /* DirectX */
} /* Graphics */
} /* Windows */
ABI_NAMESPACE_END
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
/*
*
* Typedef of Windows.Graphics.DirectX.Direct3D11.Direct3DSurfaceDescription
*
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
*
*
*/
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
ABI_NAMESPACE_BEGIN
namespace Windows {
namespace Graphics {
namespace DirectX {
namespace Direct3D11 {
/* [contract, version, version] */
typedef
struct Direct3DSurfaceDescription
{
INT32 Width;
INT32 Height;
ABI_PARAMETER(Windows::Graphics::DirectX::DirectXPixelFormat) Format;
ABI_PARAMETER(Windows::Graphics::DirectX::Direct3D11::Direct3DMultisampleDescription) MultisampleDescription;
} Direct3DSurfaceDescription;
} /* Direct3D11 */
} /* DirectX */
} /* Graphics */
} /* Windows */
ABI_NAMESPACE_END
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
/*
*
* Typedef of Windows.Graphics.DirectX.Direct3D11.Direct3DUsage
*
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
*
*
*/
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
ABI_NAMESPACE_BEGIN
namespace Windows {
namespace Graphics {
namespace DirectX {
namespace Direct3D11 {
/* [contract, version, version] */
typedef /* [v1_enum] */
enum Direct3DUsage : int
{
Direct3DUsage_Default = 0,
Direct3DUsage_Immutable = 1,
Direct3DUsage_Dynamic = 2,
Direct3DUsage_Staging = 3,
} Direct3DUsage;
} /* Direct3D11 */
} /* DirectX */
} /* Graphics */
} /* Windows */
ABI_NAMESPACE_END
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
/*
*
* Typedef of Windows.Graphics.DirectX.Direct3D11.Direct3DBindings
*
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
*
*
*/
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
ABI_NAMESPACE_BEGIN
namespace Windows {
namespace Graphics {
namespace DirectX {
namespace Direct3D11 {
/* [contract, flags, version, version] */
typedef /* [v1_enum] */
enum Direct3DBindings : unsigned int
{
Direct3DBindings_VertexBuffer = 0x1,
Direct3DBindings_IndexBuffer = 0x2,
Direct3DBindings_ConstantBuffer = 0x4,
Direct3DBindings_ShaderResource = 0x8,
Direct3DBindings_StreamOutput = 0x10,
Direct3DBindings_RenderTarget = 0x20,
Direct3DBindings_DepthStencil = 0x40,
Direct3DBindings_UnorderedAccess = 0x80,
Direct3DBindings_Decoder = 0x200,
Direct3DBindings_VideoEncoder = 0x400,
} Direct3DBindings;
DEFINE_ENUM_FLAG_OPERATORS(Direct3DBindings)
} /* Direct3D11 */
} /* DirectX */
} /* Graphics */
} /* Windows */
ABI_NAMESPACE_END
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
/*
*
* Interface Windows.Graphics.DirectX.Direct3D11.IDirect3DDevice
*
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
*
*
* Any object which implements this interface must also implement the following interfaces:
* Windows.Foundation.IClosable
*
*
*/
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
#if !defined(____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_INTERFACE_DEFINED__)
#define ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_INTERFACE_DEFINED__
extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_Graphics_DirectX_Direct3D11_IDirect3DDevice[] = L"Windows.Graphics.DirectX.Direct3D11.IDirect3DDevice";
ABI_NAMESPACE_BEGIN
namespace Windows {
namespace Graphics {
namespace DirectX {
namespace Direct3D11 {
/* [object, contract, uuid("A37624AB-8D5F-4650-9D3E-9EAE3D9BC670"), version, version] */
MIDL_INTERFACE("A37624AB-8D5F-4650-9D3E-9EAE3D9BC670")
IDirect3DDevice : public IInspectable
{
public:
virtual HRESULT STDMETHODCALLTYPE Trim(void) = 0;
};
MIDL_CONST_ID IID & IID_IDirect3DDevice=__uuidof(IDirect3DDevice);
} /* Direct3D11 */
} /* DirectX */
} /* Graphics */
} /* Windows */
ABI_NAMESPACE_END
EXTERN_C const IID C_IID(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice);
#endif /* !defined(____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_INTERFACE_DEFINED__) */
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
/*
*
* Interface Windows.Graphics.DirectX.Direct3D11.IDirect3DSurface
*
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
*
*
* Any object which implements this interface must also implement the following interfaces:
* Windows.Foundation.IClosable
*
*
*/
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
#if !defined(____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_INTERFACE_DEFINED__)
#define ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_INTERFACE_DEFINED__
extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_Graphics_DirectX_Direct3D11_IDirect3DSurface[] = L"Windows.Graphics.DirectX.Direct3D11.IDirect3DSurface";
ABI_NAMESPACE_BEGIN
namespace Windows {
namespace Graphics {
namespace DirectX {
namespace Direct3D11 {
/* [object, contract, uuid("0BF4A146-13C1-4694-BEE3-7ABF15EAF586"), version, version] */
MIDL_INTERFACE("0BF4A146-13C1-4694-BEE3-7ABF15EAF586")
IDirect3DSurface : public IInspectable
{
public:
/* [propget] */virtual HRESULT STDMETHODCALLTYPE get_Description(
/* [retval, out] */__RPC__out ABI_PARAMETER(Windows::Graphics::DirectX::Direct3D11::Direct3DSurfaceDescription) * value
) = 0;
};
MIDL_CONST_ID IID & IID_IDirect3DSurface=__uuidof(IDirect3DSurface);
} /* Direct3D11 */
} /* DirectX */
} /* Graphics */
} /* Windows */
ABI_NAMESPACE_END
EXTERN_C const IID C_IID(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface);
#endif /* !defined(____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_INTERFACE_DEFINED__) */
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
#else // !defined(__cplusplus)
/* Forward Declarations */
#ifndef ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_FWD_DEFINED__
#define ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_FWD_DEFINED__
typedef interface C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice) C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice);
#endif // ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_FWD_DEFINED__
#ifndef ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_FWD_DEFINED__
#define ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_FWD_DEFINED__
typedef interface C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface) C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface);
#endif // ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_FWD_DEFINED__
#pragma warning (push)
#pragma warning (disable:4668)
#pragma warning (disable:4001)
#pragma once
#pragma warning (pop)
/*
*
* Typedef of Windows.Graphics.DirectX.Direct3D11.Direct3DMultisampleDescription
*
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
*
*
*/
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
/* [contract, version, version] */
typedef
struct C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CDirect3DMultisampleDescription)
{
INT32 Count;
INT32 Quality;
} C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CDirect3DMultisampleDescription);
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
/*
*
* Typedef of Windows.Graphics.DirectX.Direct3D11.Direct3DSurfaceDescription
*
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
*
*
*/
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
/* [contract, version, version] */
typedef
struct C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CDirect3DSurfaceDescription)
{
INT32 Width;
INT32 Height;
C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirectXPixelFormat) Format;
C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CDirect3DMultisampleDescription) MultisampleDescription;
} C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CDirect3DSurfaceDescription);
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
/*
*
* Typedef of Windows.Graphics.DirectX.Direct3D11.Direct3DUsage
*
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
*
*
*/
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
/* [contract, version, version] */
typedef /* [v1_enum] */
enum C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CDirect3DUsage)
{
Direct3DUsage_Default = 0,
Direct3DUsage_Immutable = 1,
Direct3DUsage_Dynamic = 2,
Direct3DUsage_Staging = 3,
} C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CDirect3DUsage);
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
/*
*
* Typedef of Windows.Graphics.DirectX.Direct3D11.Direct3DBindings
*
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
*
*
*/
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
/* [contract, flags, version, version] */
typedef /* [v1_enum] */
enum C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CDirect3DBindings)
{
Direct3DBindings_VertexBuffer = 0x1,
Direct3DBindings_IndexBuffer = 0x2,
Direct3DBindings_ConstantBuffer = 0x4,
Direct3DBindings_ShaderResource = 0x8,
Direct3DBindings_StreamOutput = 0x10,
Direct3DBindings_RenderTarget = 0x20,
Direct3DBindings_DepthStencil = 0x40,
Direct3DBindings_UnorderedAccess = 0x80,
Direct3DBindings_Decoder = 0x200,
Direct3DBindings_VideoEncoder = 0x400,
} C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CDirect3DBindings);
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
/*
*
* Interface Windows.Graphics.DirectX.Direct3D11.IDirect3DDevice
*
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
*
*
* Any object which implements this interface must also implement the following interfaces:
* Windows.Foundation.IClosable
*
*
*/
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
#if !defined(____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_INTERFACE_DEFINED__)
#define ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_INTERFACE_DEFINED__
extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_Graphics_DirectX_Direct3D11_IDirect3DDevice[] = L"Windows.Graphics.DirectX.Direct3D11.IDirect3DDevice";
/* [object, contract, uuid("A37624AB-8D5F-4650-9D3E-9EAE3D9BC670"), version, version] */
typedef struct C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDeviceVtbl)
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface)(
__RPC__in C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice) * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject
);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice) * This
);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice) * This
);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice) * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids
);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice) * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className
);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice) * This,
/* [OUT ] */ __RPC__out TrustLevel *trustLevel
);
HRESULT ( STDMETHODCALLTYPE *Trim )(
C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice) * This
);
END_INTERFACE
} C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDeviceVtbl);
interface C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice)
{
CONST_VTBL struct C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDeviceVtbl) *lpVtbl;
};
#ifdef COBJMACROS
#define C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice)_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl->QueryInterface(This,riid,ppvObject) )
#define C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice)_AddRef(This) \
( (This)->lpVtbl->AddRef(This) )
#define C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice)_Release(This) \
( (This)->lpVtbl->Release(This) )
#define C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice)_GetIids(This,iidCount,iids) \
( (This)->lpVtbl->GetIids(This,iidCount,iids) )
#define C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice)_GetRuntimeClassName(This,className) \
( (This)->lpVtbl->GetRuntimeClassName(This,className) )
#define C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice)_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl->GetTrustLevel(This,trustLevel) )
#define __x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_Trim(This) \
( (This)->lpVtbl->Trim(This) )
#endif /* COBJMACROS */
EXTERN_C const IID C_IID(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice);
#endif /* !defined(____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_INTERFACE_DEFINED__) */
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
/*
*
* Interface Windows.Graphics.DirectX.Direct3D11.IDirect3DSurface
*
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
*
*
* Any object which implements this interface must also implement the following interfaces:
* Windows.Foundation.IClosable
*
*
*/
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
#if !defined(____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_INTERFACE_DEFINED__)
#define ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_INTERFACE_DEFINED__
extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_Graphics_DirectX_Direct3D11_IDirect3DSurface[] = L"Windows.Graphics.DirectX.Direct3D11.IDirect3DSurface";
/* [object, contract, uuid("0BF4A146-13C1-4694-BEE3-7ABF15EAF586"), version, version] */
typedef struct C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurfaceVtbl)
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface)(
__RPC__in C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface) * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject
);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface) * This
);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface) * This
);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface) * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids
);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface) * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className
);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface) * This,
/* [OUT ] */ __RPC__out TrustLevel *trustLevel
);
/* [propget] */HRESULT ( STDMETHODCALLTYPE *get_Description )(
C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface) * This,
/* [retval, out] */__RPC__out C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CDirect3DSurfaceDescription) * value
);
END_INTERFACE
} C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurfaceVtbl);
interface C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface)
{
CONST_VTBL struct C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurfaceVtbl) *lpVtbl;
};
#ifdef COBJMACROS
#define C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface)_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl->QueryInterface(This,riid,ppvObject) )
#define C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface)_AddRef(This) \
( (This)->lpVtbl->AddRef(This) )
#define C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface)_Release(This) \
( (This)->lpVtbl->Release(This) )
#define C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface)_GetIids(This,iidCount,iids) \
( (This)->lpVtbl->GetIids(This,iidCount,iids) )
#define C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface)_GetRuntimeClassName(This,className) \
( (This)->lpVtbl->GetRuntimeClassName(This,className) )
#define C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface)_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl->GetTrustLevel(This,trustLevel) )
#define __x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_get_Description(This,value) \
( (This)->lpVtbl->get_Description(This,value) )
#endif /* COBJMACROS */
EXTERN_C const IID C_IID(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface);
#endif /* !defined(____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_INTERFACE_DEFINED__) */
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
#endif // defined(__cplusplus)
#pragma pop_macro("MIDL_CONST_ID")
#pragma pop_macro("C_IID")
#pragma pop_macro("ABI_CONCAT")
#pragma pop_macro("ABI_PARAMETER")
#pragma pop_macro("ABI_NAMESPACE_BEGIN")
#pragma pop_macro("ABI_NAMESPACE_END")
#endif // __winrtdirect3d11_p_h__
#endif // __winrtdirect3d11_h__

684
vendor/include/winrtdirectxcommon.h vendored Normal file
View File

@ -0,0 +1,684 @@
/* Header file automatically generated from winrtdirectxcommon.idl */
/*
* File built with Microsoft(R) MIDLRT Compiler Engine Version 10.00.0231
*/
#pragma warning( disable: 4049 ) /* more than 64k source lines */
/* verify that the <rpcndr.h> version is high enough to compile this file*/
#ifndef __REQUIRED_RPCNDR_H_VERSION__
#define __REQUIRED_RPCNDR_H_VERSION__ 500
#endif
/* verify that the <rpcsal.h> version is high enough to compile this file*/
#ifndef __REQUIRED_RPCSAL_H_VERSION__
#define __REQUIRED_RPCSAL_H_VERSION__ 100
#endif
#include <rpc.h>
#include <rpcndr.h>
#ifndef __RPCNDR_H_VERSION__
#error this stub requires an updated version of <rpcndr.h>
#endif /* __RPCNDR_H_VERSION__ */
#ifndef COM_NO_WINDOWS_H
#include <windows.h>
#include <ole2.h>
#endif /*COM_NO_WINDOWS_H*/
#ifndef __winrtdirectxcommon_h__
#define __winrtdirectxcommon_h__
#ifndef __winrtdirectxcommon_p_h__
#define __winrtdirectxcommon_p_h__
#pragma once
// Ensure that the setting of the /ns_prefix command line switch is consistent for all headers.
// If you get an error from the compiler indicating "warning C4005: 'CHECK_NS_PREFIX_STATE': macro redefinition", this
// indicates that you have included two different headers with different settings for the /ns_prefix MIDL command line switch
#if !defined(DISABLE_NS_PREFIX_CHECKS)
#if defined(MIDL_NS_PREFIX)
#define CHECK_NS_PREFIX_STATE "always"
#else
#define CHECK_NS_PREFIX_STATE "never"
#endif // MIDL_NS_PREFIX
#endif // !defined(DISABLE_NS_PREFIX_CHECKS)
#pragma push_macro("ABI_CONCAT")
#pragma push_macro("ABI_PARAMETER")
#pragma push_macro("ABI_NAMESPACE_BEGIN")
#pragma push_macro("ABI_NAMESPACE_END")
#pragma push_macro("C_IID")
#undef ABI_CONCAT
#undef ABI_PARAMETER
#undef ABI_NAMESPACE_BEGIN
#undef ABI_NAMESPACE_END
#undef C_IID
#define ABI_CONCAT(x,y) x##y
// /ns_prefix optional state
#if defined(MIDL_NS_PREFIX)
#if defined(__cplusplus) && !defined(CINTERFACE)
#define ABI_PARAMETER(x) ABI::x
#define ABI_NAMESPACE_BEGIN namespace ABI {
#define ABI_NAMESPACE_END }
#else // !defined(__cplusplus) || defined(CINTERFACE)
#define C_ABI_PARAMETER(x) ABI_CONCAT(__x_ABI_C, x)
#endif // !defined(__cplusplus)
#define C_IID(x) ABI_CONCAT(IID___x_ABI_C, x)
#else
#if defined(__cplusplus) && !defined(CINTERFACE)
#define ABI_PARAMETER(x) x
#define ABI_NAMESPACE_BEGIN
#define ABI_NAMESPACE_END
#else // !defined(__cplusplus) || defined(CINTERFACE)
#define C_ABI_PARAMETER(x) ABI_CONCAT(__x_, x)
#endif // !defined(__cplusplus)
#define C_IID(x) ABI_CONCAT(IID___x_, x)
#endif // defined(MIDL_NS_PREFIX)
#pragma push_macro("MIDL_CONST_ID")
#undef MIDL_CONST_ID
#define MIDL_CONST_ID const __declspec(selectany)
// API Contract Inclusion Definitions
#if !defined(SPECIFIC_API_CONTRACT_DEFINITIONS)
#if !defined(WINDOWS_APPLICATIONMODEL_CALLS_CALLSPHONECONTRACT_VERSION)
#define WINDOWS_APPLICATIONMODEL_CALLS_CALLSPHONECONTRACT_VERSION 0x70000
#endif // defined(WINDOWS_APPLICATIONMODEL_CALLS_CALLSPHONECONTRACT_VERSION)
#if !defined(WINDOWS_FOUNDATION_FOUNDATIONCONTRACT_VERSION)
#define WINDOWS_FOUNDATION_FOUNDATIONCONTRACT_VERSION 0x40000
#endif // defined(WINDOWS_FOUNDATION_FOUNDATIONCONTRACT_VERSION)
#if !defined(WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION)
#define WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION 0x130000
#endif // defined(WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION)
#if !defined(WINDOWS_NETWORKING_SOCKETS_CONTROLCHANNELTRIGGERCONTRACT_VERSION)
#define WINDOWS_NETWORKING_SOCKETS_CONTROLCHANNELTRIGGERCONTRACT_VERSION 0x30000
#endif // defined(WINDOWS_NETWORKING_SOCKETS_CONTROLCHANNELTRIGGERCONTRACT_VERSION)
#if !defined(WINDOWS_PHONE_PHONECONTRACT_VERSION)
#define WINDOWS_PHONE_PHONECONTRACT_VERSION 0x10000
#endif // defined(WINDOWS_PHONE_PHONECONTRACT_VERSION)
#if !defined(WINDOWS_PHONE_PHONEINTERNALCONTRACT_VERSION)
#define WINDOWS_PHONE_PHONEINTERNALCONTRACT_VERSION 0x10000
#endif // defined(WINDOWS_PHONE_PHONEINTERNALCONTRACT_VERSION)
#if !defined(WINDOWS_UI_WEBUI_CORE_WEBUICOMMANDBARCONTRACT_VERSION)
#define WINDOWS_UI_WEBUI_CORE_WEBUICOMMANDBARCONTRACT_VERSION 0x10000
#endif // defined(WINDOWS_UI_WEBUI_CORE_WEBUICOMMANDBARCONTRACT_VERSION)
#endif // defined(SPECIFIC_API_CONTRACT_DEFINITIONS)
// Header files for imported files
#include "inspectable.h"
#include "Windows.Foundation.h"
#if defined(__cplusplus) && !defined(CINTERFACE)
/* Forward Declarations */
#pragma once
#pragma warning (push)
#pragma warning (disable:4668)
#pragma warning (disable:4001)
#pragma once
#pragma warning (pop)
/*
*
* Typedef of Windows.Graphics.DirectX.DirectXAlphaMode
*
* Introduced to Windows.Foundation.UniversalApiContract in version 2.0
*
*
*/
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x20000
ABI_NAMESPACE_BEGIN
namespace Windows {
namespace Graphics {
namespace DirectX {
/* [contract, version, version] */
typedef /* [v1_enum] */
enum DirectXAlphaMode : int
{
DirectXAlphaMode_Unspecified = 0,
DirectXAlphaMode_Premultiplied = 1,
DirectXAlphaMode_Straight = 2,
DirectXAlphaMode_Ignore = 3,
} DirectXAlphaMode;
} /* DirectX */
} /* Graphics */
} /* Windows */
ABI_NAMESPACE_END
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x20000
/*
*
* Typedef of Windows.Graphics.DirectX.DirectXPixelFormat
*
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
*
*
*/
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
ABI_NAMESPACE_BEGIN
namespace Windows {
namespace Graphics {
namespace DirectX {
/* [contract, version, version] */
typedef /* [v1_enum] */
enum DirectXPixelFormat : int
{
DirectXPixelFormat_Unknown = 0,
DirectXPixelFormat_R32G32B32A32Typeless = 1,
DirectXPixelFormat_R32G32B32A32Float = 2,
DirectXPixelFormat_R32G32B32A32UInt = 3,
DirectXPixelFormat_R32G32B32A32Int = 4,
DirectXPixelFormat_R32G32B32Typeless = 5,
DirectXPixelFormat_R32G32B32Float = 6,
DirectXPixelFormat_R32G32B32UInt = 7,
DirectXPixelFormat_R32G32B32Int = 8,
DirectXPixelFormat_R16G16B16A16Typeless = 9,
DirectXPixelFormat_R16G16B16A16Float = 10,
DirectXPixelFormat_R16G16B16A16UIntNormalized = 11,
DirectXPixelFormat_R16G16B16A16UInt = 12,
DirectXPixelFormat_R16G16B16A16IntNormalized = 13,
DirectXPixelFormat_R16G16B16A16Int = 14,
DirectXPixelFormat_R32G32Typeless = 15,
DirectXPixelFormat_R32G32Float = 16,
DirectXPixelFormat_R32G32UInt = 17,
DirectXPixelFormat_R32G32Int = 18,
DirectXPixelFormat_R32G8X24Typeless = 19,
DirectXPixelFormat_D32FloatS8X24UInt = 20,
DirectXPixelFormat_R32FloatX8X24Typeless = 21,
DirectXPixelFormat_X32TypelessG8X24UInt = 22,
DirectXPixelFormat_R10G10B10A2Typeless = 23,
DirectXPixelFormat_R10G10B10A2UIntNormalized = 24,
DirectXPixelFormat_R10G10B10A2UInt = 25,
DirectXPixelFormat_R11G11B10Float = 26,
DirectXPixelFormat_R8G8B8A8Typeless = 27,
DirectXPixelFormat_R8G8B8A8UIntNormalized = 28,
DirectXPixelFormat_R8G8B8A8UIntNormalizedSrgb = 29,
DirectXPixelFormat_R8G8B8A8UInt = 30,
DirectXPixelFormat_R8G8B8A8IntNormalized = 31,
DirectXPixelFormat_R8G8B8A8Int = 32,
DirectXPixelFormat_R16G16Typeless = 33,
DirectXPixelFormat_R16G16Float = 34,
DirectXPixelFormat_R16G16UIntNormalized = 35,
DirectXPixelFormat_R16G16UInt = 36,
DirectXPixelFormat_R16G16IntNormalized = 37,
DirectXPixelFormat_R16G16Int = 38,
DirectXPixelFormat_R32Typeless = 39,
DirectXPixelFormat_D32Float = 40,
DirectXPixelFormat_R32Float = 41,
DirectXPixelFormat_R32UInt = 42,
DirectXPixelFormat_R32Int = 43,
DirectXPixelFormat_R24G8Typeless = 44,
DirectXPixelFormat_D24UIntNormalizedS8UInt = 45,
DirectXPixelFormat_R24UIntNormalizedX8Typeless = 46,
DirectXPixelFormat_X24TypelessG8UInt = 47,
DirectXPixelFormat_R8G8Typeless = 48,
DirectXPixelFormat_R8G8UIntNormalized = 49,
DirectXPixelFormat_R8G8UInt = 50,
DirectXPixelFormat_R8G8IntNormalized = 51,
DirectXPixelFormat_R8G8Int = 52,
DirectXPixelFormat_R16Typeless = 53,
DirectXPixelFormat_R16Float = 54,
DirectXPixelFormat_D16UIntNormalized = 55,
DirectXPixelFormat_R16UIntNormalized = 56,
DirectXPixelFormat_R16UInt = 57,
DirectXPixelFormat_R16IntNormalized = 58,
DirectXPixelFormat_R16Int = 59,
DirectXPixelFormat_R8Typeless = 60,
DirectXPixelFormat_R8UIntNormalized = 61,
DirectXPixelFormat_R8UInt = 62,
DirectXPixelFormat_R8IntNormalized = 63,
DirectXPixelFormat_R8Int = 64,
DirectXPixelFormat_A8UIntNormalized = 65,
DirectXPixelFormat_R1UIntNormalized = 66,
DirectXPixelFormat_R9G9B9E5SharedExponent = 67,
DirectXPixelFormat_R8G8B8G8UIntNormalized = 68,
DirectXPixelFormat_G8R8G8B8UIntNormalized = 69,
DirectXPixelFormat_BC1Typeless = 70,
DirectXPixelFormat_BC1UIntNormalized = 71,
DirectXPixelFormat_BC1UIntNormalizedSrgb = 72,
DirectXPixelFormat_BC2Typeless = 73,
DirectXPixelFormat_BC2UIntNormalized = 74,
DirectXPixelFormat_BC2UIntNormalizedSrgb = 75,
DirectXPixelFormat_BC3Typeless = 76,
DirectXPixelFormat_BC3UIntNormalized = 77,
DirectXPixelFormat_BC3UIntNormalizedSrgb = 78,
DirectXPixelFormat_BC4Typeless = 79,
DirectXPixelFormat_BC4UIntNormalized = 80,
DirectXPixelFormat_BC4IntNormalized = 81,
DirectXPixelFormat_BC5Typeless = 82,
DirectXPixelFormat_BC5UIntNormalized = 83,
DirectXPixelFormat_BC5IntNormalized = 84,
DirectXPixelFormat_B5G6R5UIntNormalized = 85,
DirectXPixelFormat_B5G5R5A1UIntNormalized = 86,
DirectXPixelFormat_B8G8R8A8UIntNormalized = 87,
DirectXPixelFormat_B8G8R8X8UIntNormalized = 88,
DirectXPixelFormat_R10G10B10XRBiasA2UIntNormalized = 89,
DirectXPixelFormat_B8G8R8A8Typeless = 90,
DirectXPixelFormat_B8G8R8A8UIntNormalizedSrgb = 91,
DirectXPixelFormat_B8G8R8X8Typeless = 92,
DirectXPixelFormat_B8G8R8X8UIntNormalizedSrgb = 93,
DirectXPixelFormat_BC6HTypeless = 94,
DirectXPixelFormat_BC6H16UnsignedFloat = 95,
DirectXPixelFormat_BC6H16Float = 96,
DirectXPixelFormat_BC7Typeless = 97,
DirectXPixelFormat_BC7UIntNormalized = 98,
DirectXPixelFormat_BC7UIntNormalizedSrgb = 99,
DirectXPixelFormat_Ayuv = 100,
DirectXPixelFormat_Y410 = 101,
DirectXPixelFormat_Y416 = 102,
DirectXPixelFormat_NV12 = 103,
DirectXPixelFormat_P010 = 104,
DirectXPixelFormat_P016 = 105,
DirectXPixelFormat_Opaque420 = 106,
DirectXPixelFormat_Yuy2 = 107,
DirectXPixelFormat_Y210 = 108,
DirectXPixelFormat_Y216 = 109,
DirectXPixelFormat_NV11 = 110,
DirectXPixelFormat_AI44 = 111,
DirectXPixelFormat_IA44 = 112,
DirectXPixelFormat_P8 = 113,
DirectXPixelFormat_A8P8 = 114,
DirectXPixelFormat_B4G4R4A4UIntNormalized = 115,
DirectXPixelFormat_P208 = 130,
DirectXPixelFormat_V208 = 131,
DirectXPixelFormat_V408 = 132,
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0xa0000
DirectXPixelFormat_SamplerFeedbackMinMipOpaque = 189,
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0xa0000
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0xa0000
DirectXPixelFormat_SamplerFeedbackMipRegionUsedOpaque = 190,
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0xa0000
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x100000
DirectXPixelFormat_A4B4G4R4 = 191,
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x100000
} DirectXPixelFormat;
} /* DirectX */
} /* Graphics */
} /* Windows */
ABI_NAMESPACE_END
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
/*
*
* Typedef of Windows.Graphics.DirectX.DirectXColorSpace
*
* Introduced to Windows.Foundation.UniversalApiContract in version 6.0
*
*
*/
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x60000
ABI_NAMESPACE_BEGIN
namespace Windows {
namespace Graphics {
namespace DirectX {
/* [contract] */
typedef /* [v1_enum] */
enum DirectXColorSpace : int
{
DirectXColorSpace_RgbFullG22NoneP709 = 0,
DirectXColorSpace_RgbFullG10NoneP709 = 1,
DirectXColorSpace_RgbStudioG22NoneP709 = 2,
DirectXColorSpace_RgbStudioG22NoneP2020 = 3,
DirectXColorSpace_Reserved = 4,
DirectXColorSpace_YccFullG22NoneP709X601 = 5,
DirectXColorSpace_YccStudioG22LeftP601 = 6,
DirectXColorSpace_YccFullG22LeftP601 = 7,
DirectXColorSpace_YccStudioG22LeftP709 = 8,
DirectXColorSpace_YccFullG22LeftP709 = 9,
DirectXColorSpace_YccStudioG22LeftP2020 = 10,
DirectXColorSpace_YccFullG22LeftP2020 = 11,
DirectXColorSpace_RgbFullG2084NoneP2020 = 12,
DirectXColorSpace_YccStudioG2084LeftP2020 = 13,
DirectXColorSpace_RgbStudioG2084NoneP2020 = 14,
DirectXColorSpace_YccStudioG22TopLeftP2020 = 15,
DirectXColorSpace_YccStudioG2084TopLeftP2020 = 16,
DirectXColorSpace_RgbFullG22NoneP2020 = 17,
DirectXColorSpace_YccStudioGHlgTopLeftP2020 = 18,
DirectXColorSpace_YccFullGHlgTopLeftP2020 = 19,
DirectXColorSpace_RgbStudioG24NoneP709 = 20,
DirectXColorSpace_RgbStudioG24NoneP2020 = 21,
DirectXColorSpace_YccStudioG24LeftP709 = 22,
DirectXColorSpace_YccStudioG24LeftP2020 = 23,
DirectXColorSpace_YccStudioG24TopLeftP2020 = 24,
} DirectXColorSpace;
} /* DirectX */
} /* Graphics */
} /* Windows */
ABI_NAMESPACE_END
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x60000
/*
*
* Typedef of Windows.Graphics.DirectX.DirectXPrimitiveTopology
*
* Introduced to Windows.Foundation.UniversalApiContract in version 8.0
*
*
*/
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x80000
ABI_NAMESPACE_BEGIN
namespace Windows {
namespace Graphics {
namespace DirectX {
/* [contract] */
typedef /* [v1_enum] */
enum DirectXPrimitiveTopology : int
{
DirectXPrimitiveTopology_Undefined = 0,
DirectXPrimitiveTopology_PointList = 1,
DirectXPrimitiveTopology_LineList = 2,
DirectXPrimitiveTopology_LineStrip = 3,
DirectXPrimitiveTopology_TriangleList = 4,
DirectXPrimitiveTopology_TriangleStrip = 5,
} DirectXPrimitiveTopology;
} /* DirectX */
} /* Graphics */
} /* Windows */
ABI_NAMESPACE_END
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x80000
#else // !defined(__cplusplus)
/* Forward Declarations */
#pragma once
#pragma warning (push)
#pragma warning (disable:4668)
#pragma warning (disable:4001)
#pragma once
#pragma warning (pop)
/*
*
* Typedef of Windows.Graphics.DirectX.DirectXAlphaMode
*
* Introduced to Windows.Foundation.UniversalApiContract in version 2.0
*
*
*/
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x20000
/* [contract, version, version] */
typedef /* [v1_enum] */
enum C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirectXAlphaMode)
{
DirectXAlphaMode_Unspecified = 0,
DirectXAlphaMode_Premultiplied = 1,
DirectXAlphaMode_Straight = 2,
DirectXAlphaMode_Ignore = 3,
} C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirectXAlphaMode);
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x20000
/*
*
* Typedef of Windows.Graphics.DirectX.DirectXPixelFormat
*
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
*
*
*/
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
/* [contract, version, version] */
typedef /* [v1_enum] */
enum C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirectXPixelFormat)
{
DirectXPixelFormat_Unknown = 0,
DirectXPixelFormat_R32G32B32A32Typeless = 1,
DirectXPixelFormat_R32G32B32A32Float = 2,
DirectXPixelFormat_R32G32B32A32UInt = 3,
DirectXPixelFormat_R32G32B32A32Int = 4,
DirectXPixelFormat_R32G32B32Typeless = 5,
DirectXPixelFormat_R32G32B32Float = 6,
DirectXPixelFormat_R32G32B32UInt = 7,
DirectXPixelFormat_R32G32B32Int = 8,
DirectXPixelFormat_R16G16B16A16Typeless = 9,
DirectXPixelFormat_R16G16B16A16Float = 10,
DirectXPixelFormat_R16G16B16A16UIntNormalized = 11,
DirectXPixelFormat_R16G16B16A16UInt = 12,
DirectXPixelFormat_R16G16B16A16IntNormalized = 13,
DirectXPixelFormat_R16G16B16A16Int = 14,
DirectXPixelFormat_R32G32Typeless = 15,
DirectXPixelFormat_R32G32Float = 16,
DirectXPixelFormat_R32G32UInt = 17,
DirectXPixelFormat_R32G32Int = 18,
DirectXPixelFormat_R32G8X24Typeless = 19,
DirectXPixelFormat_D32FloatS8X24UInt = 20,
DirectXPixelFormat_R32FloatX8X24Typeless = 21,
DirectXPixelFormat_X32TypelessG8X24UInt = 22,
DirectXPixelFormat_R10G10B10A2Typeless = 23,
DirectXPixelFormat_R10G10B10A2UIntNormalized = 24,
DirectXPixelFormat_R10G10B10A2UInt = 25,
DirectXPixelFormat_R11G11B10Float = 26,
DirectXPixelFormat_R8G8B8A8Typeless = 27,
DirectXPixelFormat_R8G8B8A8UIntNormalized = 28,
DirectXPixelFormat_R8G8B8A8UIntNormalizedSrgb = 29,
DirectXPixelFormat_R8G8B8A8UInt = 30,
DirectXPixelFormat_R8G8B8A8IntNormalized = 31,
DirectXPixelFormat_R8G8B8A8Int = 32,
DirectXPixelFormat_R16G16Typeless = 33,
DirectXPixelFormat_R16G16Float = 34,
DirectXPixelFormat_R16G16UIntNormalized = 35,
DirectXPixelFormat_R16G16UInt = 36,
DirectXPixelFormat_R16G16IntNormalized = 37,
DirectXPixelFormat_R16G16Int = 38,
DirectXPixelFormat_R32Typeless = 39,
DirectXPixelFormat_D32Float = 40,
DirectXPixelFormat_R32Float = 41,
DirectXPixelFormat_R32UInt = 42,
DirectXPixelFormat_R32Int = 43,
DirectXPixelFormat_R24G8Typeless = 44,
DirectXPixelFormat_D24UIntNormalizedS8UInt = 45,
DirectXPixelFormat_R24UIntNormalizedX8Typeless = 46,
DirectXPixelFormat_X24TypelessG8UInt = 47,
DirectXPixelFormat_R8G8Typeless = 48,
DirectXPixelFormat_R8G8UIntNormalized = 49,
DirectXPixelFormat_R8G8UInt = 50,
DirectXPixelFormat_R8G8IntNormalized = 51,
DirectXPixelFormat_R8G8Int = 52,
DirectXPixelFormat_R16Typeless = 53,
DirectXPixelFormat_R16Float = 54,
DirectXPixelFormat_D16UIntNormalized = 55,
DirectXPixelFormat_R16UIntNormalized = 56,
DirectXPixelFormat_R16UInt = 57,
DirectXPixelFormat_R16IntNormalized = 58,
DirectXPixelFormat_R16Int = 59,
DirectXPixelFormat_R8Typeless = 60,
DirectXPixelFormat_R8UIntNormalized = 61,
DirectXPixelFormat_R8UInt = 62,
DirectXPixelFormat_R8IntNormalized = 63,
DirectXPixelFormat_R8Int = 64,
DirectXPixelFormat_A8UIntNormalized = 65,
DirectXPixelFormat_R1UIntNormalized = 66,
DirectXPixelFormat_R9G9B9E5SharedExponent = 67,
DirectXPixelFormat_R8G8B8G8UIntNormalized = 68,
DirectXPixelFormat_G8R8G8B8UIntNormalized = 69,
DirectXPixelFormat_BC1Typeless = 70,
DirectXPixelFormat_BC1UIntNormalized = 71,
DirectXPixelFormat_BC1UIntNormalizedSrgb = 72,
DirectXPixelFormat_BC2Typeless = 73,
DirectXPixelFormat_BC2UIntNormalized = 74,
DirectXPixelFormat_BC2UIntNormalizedSrgb = 75,
DirectXPixelFormat_BC3Typeless = 76,
DirectXPixelFormat_BC3UIntNormalized = 77,
DirectXPixelFormat_BC3UIntNormalizedSrgb = 78,
DirectXPixelFormat_BC4Typeless = 79,
DirectXPixelFormat_BC4UIntNormalized = 80,
DirectXPixelFormat_BC4IntNormalized = 81,
DirectXPixelFormat_BC5Typeless = 82,
DirectXPixelFormat_BC5UIntNormalized = 83,
DirectXPixelFormat_BC5IntNormalized = 84,
DirectXPixelFormat_B5G6R5UIntNormalized = 85,
DirectXPixelFormat_B5G5R5A1UIntNormalized = 86,
DirectXPixelFormat_B8G8R8A8UIntNormalized = 87,
DirectXPixelFormat_B8G8R8X8UIntNormalized = 88,
DirectXPixelFormat_R10G10B10XRBiasA2UIntNormalized = 89,
DirectXPixelFormat_B8G8R8A8Typeless = 90,
DirectXPixelFormat_B8G8R8A8UIntNormalizedSrgb = 91,
DirectXPixelFormat_B8G8R8X8Typeless = 92,
DirectXPixelFormat_B8G8R8X8UIntNormalizedSrgb = 93,
DirectXPixelFormat_BC6HTypeless = 94,
DirectXPixelFormat_BC6H16UnsignedFloat = 95,
DirectXPixelFormat_BC6H16Float = 96,
DirectXPixelFormat_BC7Typeless = 97,
DirectXPixelFormat_BC7UIntNormalized = 98,
DirectXPixelFormat_BC7UIntNormalizedSrgb = 99,
DirectXPixelFormat_Ayuv = 100,
DirectXPixelFormat_Y410 = 101,
DirectXPixelFormat_Y416 = 102,
DirectXPixelFormat_NV12 = 103,
DirectXPixelFormat_P010 = 104,
DirectXPixelFormat_P016 = 105,
DirectXPixelFormat_Opaque420 = 106,
DirectXPixelFormat_Yuy2 = 107,
DirectXPixelFormat_Y210 = 108,
DirectXPixelFormat_Y216 = 109,
DirectXPixelFormat_NV11 = 110,
DirectXPixelFormat_AI44 = 111,
DirectXPixelFormat_IA44 = 112,
DirectXPixelFormat_P8 = 113,
DirectXPixelFormat_A8P8 = 114,
DirectXPixelFormat_B4G4R4A4UIntNormalized = 115,
DirectXPixelFormat_P208 = 130,
DirectXPixelFormat_V208 = 131,
DirectXPixelFormat_V408 = 132,
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0xa0000
DirectXPixelFormat_SamplerFeedbackMinMipOpaque = 189,
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0xa0000
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0xa0000
DirectXPixelFormat_SamplerFeedbackMipRegionUsedOpaque = 190,
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0xa0000
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x100000
DirectXPixelFormat_A4B4G4R4 = 191,
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x100000
} C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirectXPixelFormat);
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
/*
*
* Typedef of Windows.Graphics.DirectX.DirectXColorSpace
*
* Introduced to Windows.Foundation.UniversalApiContract in version 6.0
*
*
*/
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x60000
/* [contract] */
typedef /* [v1_enum] */
enum C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirectXColorSpace)
{
DirectXColorSpace_RgbFullG22NoneP709 = 0,
DirectXColorSpace_RgbFullG10NoneP709 = 1,
DirectXColorSpace_RgbStudioG22NoneP709 = 2,
DirectXColorSpace_RgbStudioG22NoneP2020 = 3,
DirectXColorSpace_Reserved = 4,
DirectXColorSpace_YccFullG22NoneP709X601 = 5,
DirectXColorSpace_YccStudioG22LeftP601 = 6,
DirectXColorSpace_YccFullG22LeftP601 = 7,
DirectXColorSpace_YccStudioG22LeftP709 = 8,
DirectXColorSpace_YccFullG22LeftP709 = 9,
DirectXColorSpace_YccStudioG22LeftP2020 = 10,
DirectXColorSpace_YccFullG22LeftP2020 = 11,
DirectXColorSpace_RgbFullG2084NoneP2020 = 12,
DirectXColorSpace_YccStudioG2084LeftP2020 = 13,
DirectXColorSpace_RgbStudioG2084NoneP2020 = 14,
DirectXColorSpace_YccStudioG22TopLeftP2020 = 15,
DirectXColorSpace_YccStudioG2084TopLeftP2020 = 16,
DirectXColorSpace_RgbFullG22NoneP2020 = 17,
DirectXColorSpace_YccStudioGHlgTopLeftP2020 = 18,
DirectXColorSpace_YccFullGHlgTopLeftP2020 = 19,
DirectXColorSpace_RgbStudioG24NoneP709 = 20,
DirectXColorSpace_RgbStudioG24NoneP2020 = 21,
DirectXColorSpace_YccStudioG24LeftP709 = 22,
DirectXColorSpace_YccStudioG24LeftP2020 = 23,
DirectXColorSpace_YccStudioG24TopLeftP2020 = 24,
} C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirectXColorSpace);
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x60000
/*
*
* Typedef of Windows.Graphics.DirectX.DirectXPrimitiveTopology
*
* Introduced to Windows.Foundation.UniversalApiContract in version 8.0
*
*
*/
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x80000
/* [contract] */
typedef /* [v1_enum] */
enum C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirectXPrimitiveTopology)
{
DirectXPrimitiveTopology_Undefined = 0,
DirectXPrimitiveTopology_PointList = 1,
DirectXPrimitiveTopology_LineList = 2,
DirectXPrimitiveTopology_LineStrip = 3,
DirectXPrimitiveTopology_TriangleList = 4,
DirectXPrimitiveTopology_TriangleStrip = 5,
} C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirectXPrimitiveTopology);
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x80000
#endif // defined(__cplusplus)
#pragma pop_macro("MIDL_CONST_ID")
#pragma pop_macro("C_IID")
#pragma pop_macro("ABI_CONCAT")
#pragma pop_macro("ABI_PARAMETER")
#pragma pop_macro("ABI_NAMESPACE_BEGIN")
#pragma pop_macro("ABI_NAMESPACE_END")
#endif // __winrtdirectxcommon_p_h__
#endif // __winrtdirectxcommon_h__

299
vendor/include/xamlom.winui.h vendored Normal file
View File

@ -0,0 +1,299 @@
/* this ALWAYS GENERATED file contains the definitions for the interfaces */
/* File created by MIDL compiler version 8.01.0628 */
/* @@MIDL_FILE_HEADING( ) */
/* verify that the <rpcndr.h> version is high enough to compile this file*/
#ifndef __REQUIRED_RPCNDR_H_VERSION__
#define __REQUIRED_RPCNDR_H_VERSION__ 500
#endif
/* verify that the <rpcsal.h> version is high enough to compile this file*/
#ifndef __REQUIRED_RPCSAL_H_VERSION__
#define __REQUIRED_RPCSAL_H_VERSION__ 100
#endif
#include "rpc.h"
#include "rpcndr.h"
#ifndef __RPCNDR_H_VERSION__
#error this stub requires an updated version of <rpcndr.h>
#endif /* __RPCNDR_H_VERSION__ */
#ifndef COM_NO_WINDOWS_H
#include "windows.h"
#include "ole2.h"
#endif /*COM_NO_WINDOWS_H*/
#ifndef __xamlom2Ewinui_h__
#define __xamlom2Ewinui_h__
#if defined(_MSC_VER) && (_MSC_VER >= 1020)
#pragma once
#endif
#ifndef DECLSPEC_XFGVIRT
#if defined(_CONTROL_FLOW_GUARD_XFG)
#define DECLSPEC_XFGVIRT(base, func) __declspec(xfg_virtual(base, func))
#else
#define DECLSPEC_XFGVIRT(base, func)
#endif
#endif
/* Forward Declarations */
#ifndef __IVisualTreeServiceCallback3_FWD_DEFINED__
#define __IVisualTreeServiceCallback3_FWD_DEFINED__
typedef interface IVisualTreeServiceCallback3 IVisualTreeServiceCallback3;
#endif /* __IVisualTreeServiceCallback3_FWD_DEFINED__ */
#ifndef __IXamlDiagnostics2_FWD_DEFINED__
#define __IXamlDiagnostics2_FWD_DEFINED__
typedef interface IXamlDiagnostics2 IXamlDiagnostics2;
#endif /* __IXamlDiagnostics2_FWD_DEFINED__ */
/* header files for imported files */
#include "XamlOM.h"
#ifdef __cplusplus
extern "C"{
#endif
/* interface __MIDL_itf_XamlOM2EWinUI_0000_0000 */
/* [local] */
#pragma region Application Family
#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP)
#pragma warning(push)
#pragma warning(disable:4668)
#pragma warning(disable:4001)
#pragma once
#pragma warning(pop)
// Win32 API definitions
#define E_NOTFOUND HRESULT_FROM_WIN32(ERROR_NOT_FOUND)
#define E_UNKNOWNTYPE MAKE_HRESULT(SEVERITY_ERROR, FACILITY_XAML, 40L)
extern RPC_IF_HANDLE __MIDL_itf_XamlOM2EWinUI_0000_0000_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_XamlOM2EWinUI_0000_0000_v0_0_s_ifspec;
#ifndef __IVisualTreeServiceCallback3_INTERFACE_DEFINED__
#define __IVisualTreeServiceCallback3_INTERFACE_DEFINED__
/* interface IVisualTreeServiceCallback3 */
/* [unique][uuid][object] */
EXTERN_C const IID IID_IVisualTreeServiceCallback3;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("765DF10A-08C8-46B0-82C9-297CFC4CEAD7")
IVisualTreeServiceCallback3 : public IUnknown
{
public:
virtual HRESULT STDMETHODCALLTYPE OnXamlRootChange(
/* [in] */ InstanceHandle root,
/* [in] */ VisualMutationType mutationType) = 0;
};
#else /* C style interface */
typedef struct IVisualTreeServiceCallback3Vtbl
{
BEGIN_INTERFACE
DECLSPEC_XFGVIRT(IUnknown, QueryInterface)
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in IVisualTreeServiceCallback3 * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
DECLSPEC_XFGVIRT(IUnknown, AddRef)
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in IVisualTreeServiceCallback3 * This);
DECLSPEC_XFGVIRT(IUnknown, Release)
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in IVisualTreeServiceCallback3 * This);
DECLSPEC_XFGVIRT(IVisualTreeServiceCallback3, OnXamlRootChange)
HRESULT ( STDMETHODCALLTYPE *OnXamlRootChange )(
__RPC__in IVisualTreeServiceCallback3 * This,
/* [in] */ InstanceHandle root,
/* [in] */ VisualMutationType mutationType);
END_INTERFACE
} IVisualTreeServiceCallback3Vtbl;
interface IVisualTreeServiceCallback3
{
CONST_VTBL struct IVisualTreeServiceCallback3Vtbl *lpVtbl;
};
#ifdef COBJMACROS
#define IVisualTreeServiceCallback3_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define IVisualTreeServiceCallback3_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define IVisualTreeServiceCallback3_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define IVisualTreeServiceCallback3_OnXamlRootChange(This,root,mutationType) \
( (This)->lpVtbl -> OnXamlRootChange(This,root,mutationType) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* __IVisualTreeServiceCallback3_INTERFACE_DEFINED__ */
#ifndef __IXamlDiagnostics2_INTERFACE_DEFINED__
#define __IXamlDiagnostics2_INTERFACE_DEFINED__
/* interface IXamlDiagnostics2 */
/* [unique][uuid][object] */
EXTERN_C const IID IID_IXamlDiagnostics2;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("523A35EE-EB38-4AE6-A3E1-5B7D0D547BD0")
IXamlDiagnostics2 : public IUnknown
{
public:
virtual HRESULT STDMETHODCALLTYPE GetUiLayerForXamlRoot(
/* [in] */ InstanceHandle instanceHandle,
/* [retval][out] */ __RPC__deref_out_opt IInspectable **ppLayer) = 0;
virtual HRESULT STDMETHODCALLTYPE HitTestForXamlRoot(
/* [in] */ InstanceHandle instanceHandle,
/* [in] */ RECT rect,
/* [out] */ __RPC__out unsigned int *pCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*pCount) InstanceHandle **ppInstanceHandles) = 0;
};
#else /* C style interface */
typedef struct IXamlDiagnostics2Vtbl
{
BEGIN_INTERFACE
DECLSPEC_XFGVIRT(IUnknown, QueryInterface)
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in IXamlDiagnostics2 * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
DECLSPEC_XFGVIRT(IUnknown, AddRef)
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in IXamlDiagnostics2 * This);
DECLSPEC_XFGVIRT(IUnknown, Release)
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in IXamlDiagnostics2 * This);
DECLSPEC_XFGVIRT(IXamlDiagnostics2, GetUiLayerForXamlRoot)
HRESULT ( STDMETHODCALLTYPE *GetUiLayerForXamlRoot )(
__RPC__in IXamlDiagnostics2 * This,
/* [in] */ InstanceHandle instanceHandle,
/* [retval][out] */ __RPC__deref_out_opt IInspectable **ppLayer);
DECLSPEC_XFGVIRT(IXamlDiagnostics2, HitTestForXamlRoot)
HRESULT ( STDMETHODCALLTYPE *HitTestForXamlRoot )(
__RPC__in IXamlDiagnostics2 * This,
/* [in] */ InstanceHandle instanceHandle,
/* [in] */ RECT rect,
/* [out] */ __RPC__out unsigned int *pCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*pCount) InstanceHandle **ppInstanceHandles);
END_INTERFACE
} IXamlDiagnostics2Vtbl;
interface IXamlDiagnostics2
{
CONST_VTBL struct IXamlDiagnostics2Vtbl *lpVtbl;
};
#ifdef COBJMACROS
#define IXamlDiagnostics2_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define IXamlDiagnostics2_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define IXamlDiagnostics2_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define IXamlDiagnostics2_GetUiLayerForXamlRoot(This,instanceHandle,ppLayer) \
( (This)->lpVtbl -> GetUiLayerForXamlRoot(This,instanceHandle,ppLayer) )
#define IXamlDiagnostics2_HitTestForXamlRoot(This,instanceHandle,rect,pCount,ppInstanceHandles) \
( (This)->lpVtbl -> HitTestForXamlRoot(This,instanceHandle,rect,pCount,ppInstanceHandles) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* __IXamlDiagnostics2_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_XamlOM2EWinUI_0000_0002 */
/* [local] */
#endif /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP) */
#pragma endregion
extern RPC_IF_HANDLE __MIDL_itf_XamlOM2EWinUI_0000_0002_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_XamlOM2EWinUI_0000_0002_v0_0_s_ifspec;
/* Additional Prototypes for ALL interfaces */
/* end of Additional Prototypes */
#ifdef __cplusplus
}
#endif
#endif

BIN
vendor/lib/DWriteCore.lib vendored Normal file

Binary file not shown.

BIN
vendor/lib/MRM.lib vendored Normal file

Binary file not shown.

Binary file not shown.

Binary file not shown.