mirror of
https://github.com/amerkoleci/Vortice.Win32.git
synced 2026-01-14 08:06:02 +08:00
Improve more bindings and new Direct3D11on12 support.
This commit is contained in:
@@ -11,7 +11,7 @@
|
||||
<VersionSuffix Condition="'$(VersionSuffix)' == ''"></VersionSuffix>
|
||||
|
||||
<GenerateDocumentationFile>true</GenerateDocumentationFile>
|
||||
<NoWarn>CS1591;CS1701</NoWarn>
|
||||
<NoWarn>CS1591;CS1701;CA2252;</NoWarn>
|
||||
<UseSharedCompilation>true</UseSharedCompilation>
|
||||
</PropertyGroup>
|
||||
|
||||
@@ -44,7 +44,7 @@
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
|
||||
</PackageReference>
|
||||
|
||||
<PackageReference Include="Microsoft.Net.Compilers.Toolset" Version="4.4.0-2.final">
|
||||
<PackageReference Include="Microsoft.Net.Compilers.Toolset" Version="4.5.0-1.22479.14">
|
||||
<PrivateAssets>all</PrivateAssets>
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
|
||||
</PackageReference>
|
||||
|
||||
@@ -26,6 +26,8 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Vortice.Win32.Direct3D12",
|
||||
EndProject
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Vortice.Win32.Direct3D11", "src\Vortice.Win32.Direct3D11\Vortice.Win32.Direct3D11.csproj", "{32CE7567-8C9E-43AD-9543-1F0A8CA1CA76}"
|
||||
EndProject
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Vortice.Win32.Direct3D11on12", "src\Vortice.Win32.Direct3D11on12\Vortice.Win32.Direct3D11on12.csproj", "{978D804A-9F52-4ED4-95D9-BBED341E48A6}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Any CPU = Debug|Any CPU
|
||||
@@ -52,6 +54,10 @@ Global
|
||||
{32CE7567-8C9E-43AD-9543-1F0A8CA1CA76}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{32CE7567-8C9E-43AD-9543-1F0A8CA1CA76}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{32CE7567-8C9E-43AD-9543-1F0A8CA1CA76}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{978D804A-9F52-4ED4-95D9-BBED341E48A6}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{978D804A-9F52-4ED4-95D9-BBED341E48A6}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{978D804A-9F52-4ED4-95D9-BBED341E48A6}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{978D804A-9F52-4ED4-95D9-BBED341E48A6}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
|
||||
@@ -16,6 +16,7 @@ public static class Program
|
||||
"Graphics.Direct3D.json",
|
||||
"Graphics.Direct3D11.json",
|
||||
"Graphics.Direct3D12.json",
|
||||
"Graphics.Direct3D11on12.json",
|
||||
"Graphics.Direct3D.Dxc.json",
|
||||
"Graphics.Direct3D.Fxc.json",
|
||||
"Graphics.Direct2D.Common.json",
|
||||
@@ -1597,7 +1598,7 @@ public static class Program
|
||||
|
||||
if (!autoGenerated)
|
||||
{
|
||||
writer.WriteLine($"/// <include file='../{writer.DocFileName}.xml' path='doc/member[@name=\"{enumType.Name}\"]/*' />");
|
||||
writer.WriteLine($"/// <include file='{writer.DocFileName}.xml' path='doc/member[@name=\"{enumType.Name}\"]/*' />");
|
||||
}
|
||||
|
||||
if (s_generateUnmanagedDocs)
|
||||
@@ -2127,6 +2128,11 @@ public static class Program
|
||||
out string parameterType,
|
||||
out string parameterName);
|
||||
|
||||
if (method.Name == "CreateWrappedResource")
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
argumentBuilder
|
||||
.Append(parameterType)
|
||||
.Append(' ')
|
||||
|
||||
520
src/Generator/win32json/api/Graphics.DXCore.json
Normal file
520
src/Generator/win32json/api/Graphics.DXCore.json
Normal file
@@ -0,0 +1,520 @@
|
||||
{
|
||||
|
||||
"Constants":[
|
||||
{
|
||||
"Name":"_FACDXCORE"
|
||||
,"Type":{"Kind":"Native","Name":"UInt32"}
|
||||
,"ValueType":"UInt32"
|
||||
,"Value":2176
|
||||
,"Attrs":[]
|
||||
}
|
||||
,{
|
||||
"Name":"DXCORE_ADAPTER_ATTRIBUTE_D3D11_GRAPHICS"
|
||||
,"Type":{"Kind":"Native","Name":"Guid"}
|
||||
,"ValueType":"String"
|
||||
,"Value":"8c47866b-7583-450d-f0f0-6bada895af4b"
|
||||
,"Attrs":[]
|
||||
}
|
||||
,{
|
||||
"Name":"DXCORE_ADAPTER_ATTRIBUTE_D3D12_GRAPHICS"
|
||||
,"Type":{"Kind":"Native","Name":"Guid"}
|
||||
,"ValueType":"String"
|
||||
,"Value":"0c9ece4d-2f6e-4f01-8c96-e89e331b47b1"
|
||||
,"Attrs":[]
|
||||
}
|
||||
,{
|
||||
"Name":"DXCORE_ADAPTER_ATTRIBUTE_D3D12_CORE_COMPUTE"
|
||||
,"Type":{"Kind":"Native","Name":"Guid"}
|
||||
,"ValueType":"String"
|
||||
,"Value":"248e2800-a793-4724-abaa-23a6de1be090"
|
||||
,"Attrs":[]
|
||||
}
|
||||
]
|
||||
|
||||
,"Types":[
|
||||
{
|
||||
"Name":"DXCoreAdapterProperty"
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Kind":"Enum"
|
||||
,"Flags":false
|
||||
,"Scoped":false
|
||||
,"Values":[
|
||||
{"Name":"InstanceLuid","Value":0}
|
||||
,{"Name":"DriverVersion","Value":1}
|
||||
,{"Name":"DriverDescription","Value":2}
|
||||
,{"Name":"HardwareID","Value":3}
|
||||
,{"Name":"KmdModelVersion","Value":4}
|
||||
,{"Name":"ComputePreemptionGranularity","Value":5}
|
||||
,{"Name":"GraphicsPreemptionGranularity","Value":6}
|
||||
,{"Name":"DedicatedAdapterMemory","Value":7}
|
||||
,{"Name":"DedicatedSystemMemory","Value":8}
|
||||
,{"Name":"SharedSystemMemory","Value":9}
|
||||
,{"Name":"AcgCompatible","Value":10}
|
||||
,{"Name":"IsHardware","Value":11}
|
||||
,{"Name":"IsIntegrated","Value":12}
|
||||
,{"Name":"IsDetachable","Value":13}
|
||||
,{"Name":"HardwareIDParts","Value":14}
|
||||
]
|
||||
,"IntegerBase":"UInt32"
|
||||
}
|
||||
,{
|
||||
"Name":"DXCoreAdapterState"
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Kind":"Enum"
|
||||
,"Flags":false
|
||||
,"Scoped":false
|
||||
,"Values":[
|
||||
{"Name":"IsDriverUpdateInProgress","Value":0}
|
||||
,{"Name":"AdapterMemoryBudget","Value":1}
|
||||
]
|
||||
,"IntegerBase":"UInt32"
|
||||
}
|
||||
,{
|
||||
"Name":"DXCoreSegmentGroup"
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Kind":"Enum"
|
||||
,"Flags":false
|
||||
,"Scoped":false
|
||||
,"Values":[
|
||||
{"Name":"Local","Value":0}
|
||||
,{"Name":"NonLocal","Value":1}
|
||||
]
|
||||
,"IntegerBase":"UInt32"
|
||||
}
|
||||
,{
|
||||
"Name":"DXCoreNotificationType"
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Kind":"Enum"
|
||||
,"Flags":false
|
||||
,"Scoped":false
|
||||
,"Values":[
|
||||
{"Name":"AdapterListStale","Value":0}
|
||||
,{"Name":"AdapterNoLongerValid","Value":1}
|
||||
,{"Name":"AdapterBudgetChange","Value":2}
|
||||
,{"Name":"AdapterHardwareContentProtectionTeardown","Value":3}
|
||||
]
|
||||
,"IntegerBase":"UInt32"
|
||||
}
|
||||
,{
|
||||
"Name":"DXCoreAdapterPreference"
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Kind":"Enum"
|
||||
,"Flags":false
|
||||
,"Scoped":false
|
||||
,"Values":[
|
||||
{"Name":"Hardware","Value":0}
|
||||
,{"Name":"MinimumPower","Value":1}
|
||||
,{"Name":"HighPerformance","Value":2}
|
||||
]
|
||||
,"IntegerBase":"UInt32"
|
||||
}
|
||||
,{
|
||||
"Name":"DXCoreHardwareID"
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Kind":"Struct"
|
||||
,"Size":0
|
||||
,"PackingSize":0
|
||||
,"Fields":[
|
||||
{"Name":"vendorID","Type":{"Kind":"Native","Name":"UInt32"},"Attrs":[]}
|
||||
,{"Name":"deviceID","Type":{"Kind":"Native","Name":"UInt32"},"Attrs":[]}
|
||||
,{"Name":"subSysID","Type":{"Kind":"Native","Name":"UInt32"},"Attrs":[]}
|
||||
,{"Name":"revision","Type":{"Kind":"Native","Name":"UInt32"},"Attrs":[]}
|
||||
]
|
||||
,"NestedTypes":[
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"DXCoreHardwareIDParts"
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Kind":"Struct"
|
||||
,"Size":0
|
||||
,"PackingSize":0
|
||||
,"Fields":[
|
||||
{"Name":"vendorID","Type":{"Kind":"Native","Name":"UInt32"},"Attrs":[]}
|
||||
,{"Name":"deviceID","Type":{"Kind":"Native","Name":"UInt32"},"Attrs":[]}
|
||||
,{"Name":"subSystemID","Type":{"Kind":"Native","Name":"UInt32"},"Attrs":[]}
|
||||
,{"Name":"subVendorID","Type":{"Kind":"Native","Name":"UInt32"},"Attrs":[]}
|
||||
,{"Name":"revisionID","Type":{"Kind":"Native","Name":"UInt32"},"Attrs":[]}
|
||||
]
|
||||
,"NestedTypes":[
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"DXCoreAdapterMemoryBudgetNodeSegmentGroup"
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Kind":"Struct"
|
||||
,"Size":0
|
||||
,"PackingSize":0
|
||||
,"Fields":[
|
||||
{"Name":"nodeIndex","Type":{"Kind":"Native","Name":"UInt32"},"Attrs":[]}
|
||||
,{"Name":"segmentGroup","Type":{"Kind":"ApiRef","Name":"DXCoreSegmentGroup","TargetKind":"Default","Api":"Graphics.DXCore","Parents":[]},"Attrs":[]}
|
||||
]
|
||||
,"NestedTypes":[
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"DXCoreAdapterMemoryBudget"
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Kind":"Struct"
|
||||
,"Size":0
|
||||
,"PackingSize":0
|
||||
,"Fields":[
|
||||
{"Name":"budget","Type":{"Kind":"Native","Name":"UInt64"},"Attrs":[]}
|
||||
,{"Name":"currentUsage","Type":{"Kind":"Native","Name":"UInt64"},"Attrs":[]}
|
||||
,{"Name":"availableForReservation","Type":{"Kind":"Native","Name":"UInt64"},"Attrs":[]}
|
||||
,{"Name":"currentReservation","Type":{"Kind":"Native","Name":"UInt64"},"Attrs":[]}
|
||||
]
|
||||
,"NestedTypes":[
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"PFN_DXCORE_NOTIFICATION_CALLBACK"
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Kind":"FunctionPointer"
|
||||
,"SetLastError":false
|
||||
,"ReturnType":{"Kind":"Native","Name":"Void"}
|
||||
,"ReturnAttrs":[]
|
||||
,"Attrs":[]
|
||||
,"Params":[
|
||||
{"Name":"notificationType","Type":{"Kind":"ApiRef","Name":"DXCoreNotificationType","TargetKind":"Default","Api":"Graphics.DXCore","Parents":[]},"Attrs":["In"]}
|
||||
,{"Name":"object","Type":{"Kind":"ApiRef","Name":"IUnknown","TargetKind":"Com","Api":"System.Com","Parents":[]},"Attrs":["In"]}
|
||||
,{"Name":"context","Type":{"Kind":"PointerTo","Child":{"Kind":"Native","Name":"Void"}},"Attrs":["In","Optional"]}
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"IDXCoreAdapter"
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Kind":"Com"
|
||||
,"Guid":"f0db4c7f-fe5a-42a2-bd62-f2a6cf6fc83e"
|
||||
,"Interface":{"Kind":"ApiRef","Name":"IUnknown","TargetKind":"Com","Api":"System.Com","Parents":[]}
|
||||
,"Methods":[
|
||||
{
|
||||
"Name":"IsValid"
|
||||
,"SetLastError":false
|
||||
,"ReturnType":{"Kind":"Native","Name":"Boolean"}
|
||||
,"ReturnAttrs":[]
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Attrs":[]
|
||||
,"Params":[
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"IsAttributeSupported"
|
||||
,"SetLastError":false
|
||||
,"ReturnType":{"Kind":"Native","Name":"Boolean"}
|
||||
,"ReturnAttrs":[]
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Attrs":[]
|
||||
,"Params":[
|
||||
{"Name":"attributeGUID","Type":{"Kind":"PointerTo","Child":{"Kind":"Native","Name":"Guid"}},"Attrs":["In","Const"]}
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"IsPropertySupported"
|
||||
,"SetLastError":false
|
||||
,"ReturnType":{"Kind":"Native","Name":"Boolean"}
|
||||
,"ReturnAttrs":[]
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Attrs":[]
|
||||
,"Params":[
|
||||
{"Name":"property","Type":{"Kind":"ApiRef","Name":"DXCoreAdapterProperty","TargetKind":"Default","Api":"Graphics.DXCore","Parents":[]},"Attrs":["In"]}
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"GetProperty"
|
||||
,"SetLastError":false
|
||||
,"ReturnType":{"Kind":"ApiRef","Name":"HRESULT","TargetKind":"Default","Api":"Foundation","Parents":[]}
|
||||
,"ReturnAttrs":[]
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Attrs":[]
|
||||
,"Params":[
|
||||
{"Name":"property","Type":{"Kind":"ApiRef","Name":"DXCoreAdapterProperty","TargetKind":"Default","Api":"Graphics.DXCore","Parents":[]},"Attrs":["In"]}
|
||||
,{"Name":"bufferSize","Type":{"Kind":"Native","Name":"UIntPtr"},"Attrs":["In"]}
|
||||
,{"Name":"propertyData","Type":{"Kind":"PointerTo","Child":{"Kind":"Native","Name":"Void"}},"Attrs":["Out",{"Kind":"MemorySize","BytesParamIndex":1}]}
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"GetPropertySize"
|
||||
,"SetLastError":false
|
||||
,"ReturnType":{"Kind":"ApiRef","Name":"HRESULT","TargetKind":"Default","Api":"Foundation","Parents":[]}
|
||||
,"ReturnAttrs":[]
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Attrs":[]
|
||||
,"Params":[
|
||||
{"Name":"property","Type":{"Kind":"ApiRef","Name":"DXCoreAdapterProperty","TargetKind":"Default","Api":"Graphics.DXCore","Parents":[]},"Attrs":["In"]}
|
||||
,{"Name":"bufferSize","Type":{"Kind":"PointerTo","Child":{"Kind":"Native","Name":"UIntPtr"}},"Attrs":["Out"]}
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"IsQueryStateSupported"
|
||||
,"SetLastError":false
|
||||
,"ReturnType":{"Kind":"Native","Name":"Boolean"}
|
||||
,"ReturnAttrs":[]
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Attrs":[]
|
||||
,"Params":[
|
||||
{"Name":"property","Type":{"Kind":"ApiRef","Name":"DXCoreAdapterState","TargetKind":"Default","Api":"Graphics.DXCore","Parents":[]},"Attrs":["In"]}
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"QueryState"
|
||||
,"SetLastError":false
|
||||
,"ReturnType":{"Kind":"ApiRef","Name":"HRESULT","TargetKind":"Default","Api":"Foundation","Parents":[]}
|
||||
,"ReturnAttrs":[]
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Attrs":[]
|
||||
,"Params":[
|
||||
{"Name":"state","Type":{"Kind":"ApiRef","Name":"DXCoreAdapterState","TargetKind":"Default","Api":"Graphics.DXCore","Parents":[]},"Attrs":["In"]}
|
||||
,{"Name":"inputStateDetailsSize","Type":{"Kind":"Native","Name":"UIntPtr"},"Attrs":["In"]}
|
||||
,{"Name":"inputStateDetails","Type":{"Kind":"PointerTo","Child":{"Kind":"Native","Name":"Void"}},"Attrs":["In",{"Kind":"MemorySize","BytesParamIndex":1},"Optional","Const"]}
|
||||
,{"Name":"outputBufferSize","Type":{"Kind":"Native","Name":"UIntPtr"},"Attrs":["In"]}
|
||||
,{"Name":"outputBuffer","Type":{"Kind":"PointerTo","Child":{"Kind":"Native","Name":"Void"}},"Attrs":["Out",{"Kind":"MemorySize","BytesParamIndex":3}]}
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"IsSetStateSupported"
|
||||
,"SetLastError":false
|
||||
,"ReturnType":{"Kind":"Native","Name":"Boolean"}
|
||||
,"ReturnAttrs":[]
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Attrs":[]
|
||||
,"Params":[
|
||||
{"Name":"property","Type":{"Kind":"ApiRef","Name":"DXCoreAdapterState","TargetKind":"Default","Api":"Graphics.DXCore","Parents":[]},"Attrs":["In"]}
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"SetState"
|
||||
,"SetLastError":false
|
||||
,"ReturnType":{"Kind":"ApiRef","Name":"HRESULT","TargetKind":"Default","Api":"Foundation","Parents":[]}
|
||||
,"ReturnAttrs":[]
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Attrs":[]
|
||||
,"Params":[
|
||||
{"Name":"state","Type":{"Kind":"ApiRef","Name":"DXCoreAdapterState","TargetKind":"Default","Api":"Graphics.DXCore","Parents":[]},"Attrs":["In"]}
|
||||
,{"Name":"inputStateDetailsSize","Type":{"Kind":"Native","Name":"UIntPtr"},"Attrs":["In"]}
|
||||
,{"Name":"inputStateDetails","Type":{"Kind":"PointerTo","Child":{"Kind":"Native","Name":"Void"}},"Attrs":["In",{"Kind":"MemorySize","BytesParamIndex":1},"Optional","Const"]}
|
||||
,{"Name":"inputDataSize","Type":{"Kind":"Native","Name":"UIntPtr"},"Attrs":["In"]}
|
||||
,{"Name":"inputData","Type":{"Kind":"PointerTo","Child":{"Kind":"Native","Name":"Void"}},"Attrs":["In",{"Kind":"MemorySize","BytesParamIndex":3},"Const"]}
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"GetFactory"
|
||||
,"SetLastError":false
|
||||
,"ReturnType":{"Kind":"ApiRef","Name":"HRESULT","TargetKind":"Default","Api":"Foundation","Parents":[]}
|
||||
,"ReturnAttrs":[]
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Attrs":[]
|
||||
,"Params":[
|
||||
{"Name":"riid","Type":{"Kind":"PointerTo","Child":{"Kind":"Native","Name":"Guid"}},"Attrs":["In","Const"]}
|
||||
,{"Name":"ppvFactory","Type":{"Kind":"PointerTo","Child":{"Kind":"PointerTo","Child":{"Kind":"Native","Name":"Void"}}},"Attrs":["Out","ComOutPtr"]}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"IDXCoreAdapterList"
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Kind":"Com"
|
||||
,"Guid":"526c7776-40e9-459b-b711-f32ad76dfc28"
|
||||
,"Interface":{"Kind":"ApiRef","Name":"IUnknown","TargetKind":"Com","Api":"System.Com","Parents":[]}
|
||||
,"Methods":[
|
||||
{
|
||||
"Name":"GetAdapter"
|
||||
,"SetLastError":false
|
||||
,"ReturnType":{"Kind":"ApiRef","Name":"HRESULT","TargetKind":"Default","Api":"Foundation","Parents":[]}
|
||||
,"ReturnAttrs":[]
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Attrs":[]
|
||||
,"Params":[
|
||||
{"Name":"index","Type":{"Kind":"Native","Name":"UInt32"},"Attrs":["In"]}
|
||||
,{"Name":"riid","Type":{"Kind":"PointerTo","Child":{"Kind":"Native","Name":"Guid"}},"Attrs":["In","Const"]}
|
||||
,{"Name":"ppvAdapter","Type":{"Kind":"PointerTo","Child":{"Kind":"PointerTo","Child":{"Kind":"Native","Name":"Void"}}},"Attrs":["Out","ComOutPtr"]}
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"GetAdapterCount"
|
||||
,"SetLastError":false
|
||||
,"ReturnType":{"Kind":"Native","Name":"UInt32"}
|
||||
,"ReturnAttrs":[]
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Attrs":[]
|
||||
,"Params":[
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"IsStale"
|
||||
,"SetLastError":false
|
||||
,"ReturnType":{"Kind":"Native","Name":"Boolean"}
|
||||
,"ReturnAttrs":[]
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Attrs":[]
|
||||
,"Params":[
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"GetFactory"
|
||||
,"SetLastError":false
|
||||
,"ReturnType":{"Kind":"ApiRef","Name":"HRESULT","TargetKind":"Default","Api":"Foundation","Parents":[]}
|
||||
,"ReturnAttrs":[]
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Attrs":[]
|
||||
,"Params":[
|
||||
{"Name":"riid","Type":{"Kind":"PointerTo","Child":{"Kind":"Native","Name":"Guid"}},"Attrs":["In","Const"]}
|
||||
,{"Name":"ppvFactory","Type":{"Kind":"PointerTo","Child":{"Kind":"PointerTo","Child":{"Kind":"Native","Name":"Void"}}},"Attrs":["Out","ComOutPtr"]}
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"Sort"
|
||||
,"SetLastError":false
|
||||
,"ReturnType":{"Kind":"ApiRef","Name":"HRESULT","TargetKind":"Default","Api":"Foundation","Parents":[]}
|
||||
,"ReturnAttrs":[]
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Attrs":[]
|
||||
,"Params":[
|
||||
{"Name":"numPreferences","Type":{"Kind":"Native","Name":"UInt32"},"Attrs":["In"]}
|
||||
,{"Name":"preferences","Type":{"Kind":"LPArray","NullNullTerm":false,"CountConst":-1,"CountParamIndex":0,"Child":{"Kind":"ApiRef","Name":"DXCoreAdapterPreference","TargetKind":"Default","Api":"Graphics.DXCore","Parents":[]}},"Attrs":["In","Const"]}
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"IsAdapterPreferenceSupported"
|
||||
,"SetLastError":false
|
||||
,"ReturnType":{"Kind":"Native","Name":"Boolean"}
|
||||
,"ReturnAttrs":[]
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Attrs":[]
|
||||
,"Params":[
|
||||
{"Name":"preference","Type":{"Kind":"ApiRef","Name":"DXCoreAdapterPreference","TargetKind":"Default","Api":"Graphics.DXCore","Parents":[]},"Attrs":["In"]}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"IDXCoreAdapterFactory"
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Kind":"Com"
|
||||
,"Guid":"78ee5945-c36e-4b13-a669-005dd11c0f06"
|
||||
,"Interface":{"Kind":"ApiRef","Name":"IUnknown","TargetKind":"Com","Api":"System.Com","Parents":[]}
|
||||
,"Methods":[
|
||||
{
|
||||
"Name":"CreateAdapterList"
|
||||
,"SetLastError":false
|
||||
,"ReturnType":{"Kind":"ApiRef","Name":"HRESULT","TargetKind":"Default","Api":"Foundation","Parents":[]}
|
||||
,"ReturnAttrs":[]
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Attrs":[]
|
||||
,"Params":[
|
||||
{"Name":"numAttributes","Type":{"Kind":"Native","Name":"UInt32"},"Attrs":["In"]}
|
||||
,{"Name":"filterAttributes","Type":{"Kind":"LPArray","NullNullTerm":false,"CountConst":-1,"CountParamIndex":0,"Child":{"Kind":"Native","Name":"Guid"}},"Attrs":["In","Const"]}
|
||||
,{"Name":"riid","Type":{"Kind":"PointerTo","Child":{"Kind":"Native","Name":"Guid"}},"Attrs":["In","Const"]}
|
||||
,{"Name":"ppvAdapterList","Type":{"Kind":"PointerTo","Child":{"Kind":"PointerTo","Child":{"Kind":"Native","Name":"Void"}}},"Attrs":["Out","ComOutPtr"]}
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"GetAdapterByLuid"
|
||||
,"SetLastError":false
|
||||
,"ReturnType":{"Kind":"ApiRef","Name":"HRESULT","TargetKind":"Default","Api":"Foundation","Parents":[]}
|
||||
,"ReturnAttrs":[]
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Attrs":[]
|
||||
,"Params":[
|
||||
{"Name":"adapterLUID","Type":{"Kind":"PointerTo","Child":{"Kind":"ApiRef","Name":"LUID","TargetKind":"Default","Api":"Foundation","Parents":[]}},"Attrs":["In","Const"]}
|
||||
,{"Name":"riid","Type":{"Kind":"PointerTo","Child":{"Kind":"Native","Name":"Guid"}},"Attrs":["In","Const"]}
|
||||
,{"Name":"ppvAdapter","Type":{"Kind":"PointerTo","Child":{"Kind":"PointerTo","Child":{"Kind":"Native","Name":"Void"}}},"Attrs":["Out","ComOutPtr"]}
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"IsNotificationTypeSupported"
|
||||
,"SetLastError":false
|
||||
,"ReturnType":{"Kind":"Native","Name":"Boolean"}
|
||||
,"ReturnAttrs":[]
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Attrs":[]
|
||||
,"Params":[
|
||||
{"Name":"notificationType","Type":{"Kind":"ApiRef","Name":"DXCoreNotificationType","TargetKind":"Default","Api":"Graphics.DXCore","Parents":[]},"Attrs":["In"]}
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"RegisterEventNotification"
|
||||
,"SetLastError":false
|
||||
,"ReturnType":{"Kind":"ApiRef","Name":"HRESULT","TargetKind":"Default","Api":"Foundation","Parents":[]}
|
||||
,"ReturnAttrs":[]
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Attrs":[]
|
||||
,"Params":[
|
||||
{"Name":"dxCoreObject","Type":{"Kind":"ApiRef","Name":"IUnknown","TargetKind":"Com","Api":"System.Com","Parents":[]},"Attrs":["In"]}
|
||||
,{"Name":"notificationType","Type":{"Kind":"ApiRef","Name":"DXCoreNotificationType","TargetKind":"Default","Api":"Graphics.DXCore","Parents":[]},"Attrs":["In"]}
|
||||
,{"Name":"callbackFunction","Type":{"Kind":"ApiRef","Name":"PFN_DXCORE_NOTIFICATION_CALLBACK","TargetKind":"FunctionPointer","Api":"Graphics.DXCore","Parents":[]},"Attrs":["In"]}
|
||||
,{"Name":"callbackContext","Type":{"Kind":"PointerTo","Child":{"Kind":"Native","Name":"Void"}},"Attrs":["In","Optional"]}
|
||||
,{"Name":"eventCookie","Type":{"Kind":"PointerTo","Child":{"Kind":"Native","Name":"UInt32"}},"Attrs":["Out"]}
|
||||
]
|
||||
}
|
||||
,{
|
||||
"Name":"UnregisterEventNotification"
|
||||
,"SetLastError":false
|
||||
,"ReturnType":{"Kind":"ApiRef","Name":"HRESULT","TargetKind":"Default","Api":"Foundation","Parents":[]}
|
||||
,"ReturnAttrs":[]
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Attrs":[]
|
||||
,"Params":[
|
||||
{"Name":"eventCookie","Type":{"Kind":"Native","Name":"UInt32"},"Attrs":["In"]}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
|
||||
,"Functions":[
|
||||
{
|
||||
"Name":"DXCoreCreateAdapterFactory"
|
||||
,"SetLastError":false
|
||||
,"DllImport":"DXCORE.dll"
|
||||
,"ReturnType":{"Kind":"ApiRef","Name":"HRESULT","TargetKind":"Default","Api":"Foundation","Parents":[]}
|
||||
,"ReturnAttrs":[]
|
||||
,"Architectures":[]
|
||||
,"Platform":null
|
||||
,"Attrs":[]
|
||||
,"Params":[
|
||||
{"Name":"riid","Type":{"Kind":"PointerTo","Child":{"Kind":"Native","Name":"Guid"}},"Attrs":["In","Const"]}
|
||||
,{"Name":"ppvFactory","Type":{"Kind":"PointerTo","Child":{"Kind":"PointerTo","Child":{"Kind":"Native","Name":"Void"}}},"Attrs":["Out","ComOutPtr"]}
|
||||
]
|
||||
}
|
||||
]
|
||||
|
||||
,"UnicodeAliases":[
|
||||
]
|
||||
|
||||
}
|
||||
@@ -1769,7 +1769,7 @@
|
||||
"Name":"D3D10_REGKEY_PATH"
|
||||
,"Type":{"Kind":"Native","Name":"String"}
|
||||
,"ValueType":"String"
|
||||
,"Value":"Software\Microsoft\Direct3D"
|
||||
,"Value":"Software\\Microsoft\\Direct3D"
|
||||
,"Attrs":[]
|
||||
}
|
||||
,{
|
||||
|
||||
4598
src/Generator/win32json/api/Graphics.DirectComposition.json
Normal file
4598
src/Generator/win32json/api/Graphics.DirectComposition.json
Normal file
File diff suppressed because it is too large
Load Diff
1525
src/Generator/win32json/api/Graphics.DirectManipulation.json
Normal file
1525
src/Generator/win32json/api/Graphics.DirectManipulation.json
Normal file
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -2,15 +2,13 @@
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFrameworks>netstandard2.0;net6.0;net7.0</TargetFrameworks>
|
||||
<Description>Direct3D11 API low level bindings.</Description>
|
||||
<Description>Direct3D11 bindings.</Description>
|
||||
|
||||
<GenerateDocumentationFile>true</GenerateDocumentationFile>
|
||||
<NoWarn>0419;$(NoWarn)</NoWarn>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<None Include="..\..\LICENSE" PackagePath="" Pack="true" />
|
||||
|
||||
<Using Include="System.Numerics" />
|
||||
<Using Include="System.Diagnostics" />
|
||||
<Using Include="System.Runtime.CompilerServices" />
|
||||
|
||||
12
src/Vortice.Win32.Direct3D11on12/Apis.cs
Normal file
12
src/Vortice.Win32.Direct3D11on12/Apis.cs
Normal file
@@ -0,0 +1,12 @@
|
||||
// Copyright © Amer Koleci and Contributors.
|
||||
// Licensed under the MIT License (MIT). See LICENSE in the repository root for more information.
|
||||
|
||||
using Win32.Graphics.Direct3D;
|
||||
using Win32.Graphics.Dxgi;
|
||||
|
||||
namespace Win32.Graphics.Direct3D11on12;
|
||||
|
||||
public static unsafe partial class Apis
|
||||
{
|
||||
|
||||
}
|
||||
45
src/Vortice.Win32.Direct3D11on12/Generated/Direct3D11on12.cs
Normal file
45
src/Vortice.Win32.Direct3D11on12/Generated/Direct3D11on12.cs
Normal file
@@ -0,0 +1,45 @@
|
||||
// ------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
// ------------------------------------------------------------------------------
|
||||
|
||||
namespace Win32.Graphics.Direct3D11on12;
|
||||
|
||||
public static partial class Apis
|
||||
{
|
||||
}
|
||||
|
||||
#region Structs
|
||||
|
||||
/// <include file='Direct3D11on12.xml' path='doc/member[@name="D3D11_RESOURCE_FLAGS"]/*' />
|
||||
/// <unmanaged>D3D11_RESOURCE_FLAGS</unmanaged>
|
||||
public partial struct ResourceFlags
|
||||
{
|
||||
/// <include file='Direct3D11on12.xml' path='doc/member[@name="D3D11_RESOURCE_FLAGS::BindFlags"]/*' />
|
||||
public Win32.Graphics.Direct3D11.BindFlags BindFlags;
|
||||
|
||||
/// <include file='Direct3D11on12.xml' path='doc/member[@name="D3D11_RESOURCE_FLAGS::MiscFlags"]/*' />
|
||||
public Win32.Graphics.Direct3D11.ResourceMiscFlags MiscFlags;
|
||||
|
||||
/// <include file='Direct3D11on12.xml' path='doc/member[@name="D3D11_RESOURCE_FLAGS::CPUAccessFlags"]/*' />
|
||||
public Win32.Graphics.Direct3D11.CpuAccessFlags CPUAccessFlags;
|
||||
|
||||
/// <include file='Direct3D11on12.xml' path='doc/member[@name="D3D11_RESOURCE_FLAGS::StructureByteStride"]/*' />
|
||||
public uint StructureByteStride;
|
||||
}
|
||||
#endregion Structs
|
||||
|
||||
#region COM Types
|
||||
#endregion Com Types
|
||||
|
||||
#region Functions
|
||||
public static unsafe partial class Apis
|
||||
{
|
||||
[DllImport("d3d11.dll", ExactSpelling = true)]
|
||||
public static extern HResult D3D11On12CreateDevice(IUnknown* pDevice, uint Flags, Graphics.Direct3D.FeatureLevel* pFeatureLevels, uint FeatureLevels, IUnknown** ppCommandQueues, uint NumQueues, uint NodeMask, Graphics.Direct3D11.ID3D11Device** ppDevice, Graphics.Direct3D11.ID3D11DeviceContext** ppImmediateContext, Graphics.Direct3D.FeatureLevel* pChosenFeatureLevel);
|
||||
}
|
||||
#endregion Functions
|
||||
@@ -0,0 +1,97 @@
|
||||
// ------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
// ------------------------------------------------------------------------------
|
||||
|
||||
namespace Win32.Graphics.Direct3D11on12;
|
||||
|
||||
/// <include file='../../Direct3D11on12.xml' path='doc/member[@name="ID3D11On12Device"]/*' />
|
||||
/// <unmanaged>ID3D11On12Device</unmanaged>
|
||||
[Guid("85611e73-70a9-490e-9614-a9e302777904")]
|
||||
[NativeTypeName("struct ID3D11On12Device : IUnknown")]
|
||||
[NativeInheritance("IUnknown")]
|
||||
public unsafe partial struct ID3D11On12Device
|
||||
{
|
||||
public static ref readonly Guid IID_ID3D11On12Device
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
get
|
||||
{
|
||||
ReadOnlySpan<byte> data = new byte[] {
|
||||
0x73, 0x1E, 0x61, 0x85,
|
||||
0xA9, 0x70,
|
||||
0x0E, 0x49,
|
||||
0x96,
|
||||
0x14,
|
||||
0xA9,
|
||||
0xE3,
|
||||
0x02,
|
||||
0x77,
|
||||
0x79,
|
||||
0x04
|
||||
};
|
||||
|
||||
Debug.Assert(data.Length == Unsafe.SizeOf<Guid>());
|
||||
return ref Unsafe.As<byte, Guid>(ref MemoryMarshal.GetReference(data));
|
||||
}
|
||||
}
|
||||
|
||||
public static Guid* NativeGuid => (Guid*)Unsafe.AsPointer(ref Unsafe.AsRef(in IID_ID3D11On12Device));
|
||||
|
||||
public void** lpVtbl;
|
||||
|
||||
/// <inheritdoc cref="IUnknown.QueryInterface" />
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
[VtblIndex(0)]
|
||||
public HResult QueryInterface([NativeTypeName("const IID &")] Guid* riid, void** ppvObject)
|
||||
{
|
||||
return ((delegate* unmanaged[Stdcall]<IUnknown*, Guid*, void**, int>)(lpVtbl[0]))((IUnknown*)Unsafe.AsPointer(ref this), riid, ppvObject);
|
||||
}
|
||||
|
||||
/// <inheritdoc cref="IUnknown.AddRef" />
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
[VtblIndex(1)]
|
||||
[return: NativeTypeName("ULONG")]
|
||||
public uint AddRef()
|
||||
{
|
||||
return ((delegate* unmanaged[Stdcall]<IUnknown*, uint>)(lpVtbl[1]))((IUnknown*)Unsafe.AsPointer(ref this));
|
||||
}
|
||||
|
||||
/// <inheritdoc cref="IUnknown.Release" />
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
[VtblIndex(2)]
|
||||
[return: NativeTypeName("ULONG")]
|
||||
public uint Release()
|
||||
{
|
||||
return ((delegate* unmanaged[Stdcall]<IUnknown*, uint>)(lpVtbl[2]))((IUnknown*)Unsafe.AsPointer(ref this));
|
||||
}
|
||||
|
||||
/// <include file='../../Direct3D11on12.xml' path='doc/member[@name="ID3D11On12Device::CreateWrappedResource"]/*' />
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
[VtblIndex(3)]
|
||||
public HResult CreateWrappedResource(IUnknown* pResource12, ResourceFlags* pFlags11, Graphics.Direct3D12.ResourceStates InState, Graphics.Direct3D12.ResourceStates OutState, Guid* riid, void** ppResource11)
|
||||
{
|
||||
return ((delegate* unmanaged[Stdcall]<ID3D11On12Device*, IUnknown*, ResourceFlags*, Graphics.Direct3D12.ResourceStates, Graphics.Direct3D12.ResourceStates, Guid*, void**, int>)(lpVtbl[3]))((ID3D11On12Device*)Unsafe.AsPointer(ref this), pResource12, pFlags11, InState, OutState, riid, ppResource11);
|
||||
}
|
||||
|
||||
/// <include file='../../Direct3D11on12.xml' path='doc/member[@name="ID3D11On12Device::ReleaseWrappedResources"]/*' />
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
[VtblIndex(4)]
|
||||
public void ReleaseWrappedResources(Graphics.Direct3D11.ID3D11Resource** ppResources, uint NumResources)
|
||||
{
|
||||
((delegate* unmanaged[Stdcall]<ID3D11On12Device*, Graphics.Direct3D11.ID3D11Resource**, uint, void>)(lpVtbl[4]))((ID3D11On12Device*)Unsafe.AsPointer(ref this), ppResources, NumResources);
|
||||
}
|
||||
|
||||
/// <include file='../../Direct3D11on12.xml' path='doc/member[@name="ID3D11On12Device::AcquireWrappedResources"]/*' />
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
[VtblIndex(5)]
|
||||
public void AcquireWrappedResources(Graphics.Direct3D11.ID3D11Resource** ppResources, uint NumResources)
|
||||
{
|
||||
((delegate* unmanaged[Stdcall]<ID3D11On12Device*, Graphics.Direct3D11.ID3D11Resource**, uint, void>)(lpVtbl[5]))((ID3D11On12Device*)Unsafe.AsPointer(ref this), ppResources, NumResources);
|
||||
}
|
||||
}
|
||||
|
||||
105
src/Vortice.Win32.Direct3D11on12/Generated/ID3D11On12Device1.cs
Normal file
105
src/Vortice.Win32.Direct3D11on12/Generated/ID3D11On12Device1.cs
Normal file
@@ -0,0 +1,105 @@
|
||||
// ------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
// ------------------------------------------------------------------------------
|
||||
|
||||
namespace Win32.Graphics.Direct3D11on12;
|
||||
|
||||
/// <include file='../../Direct3D11on12.xml' path='doc/member[@name="ID3D11On12Device1"]/*' />
|
||||
/// <unmanaged>ID3D11On12Device1</unmanaged>
|
||||
[Guid("bdb64df4-ea2f-4c70-b861-aaab1258bb5d")]
|
||||
[NativeTypeName("struct ID3D11On12Device1 : ID3D11On12Device")]
|
||||
[NativeInheritance("ID3D11On12Device")]
|
||||
public unsafe partial struct ID3D11On12Device1
|
||||
{
|
||||
public static ref readonly Guid IID_ID3D11On12Device1
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
get
|
||||
{
|
||||
ReadOnlySpan<byte> data = new byte[] {
|
||||
0xF4, 0x4D, 0xB6, 0xBD,
|
||||
0x2F, 0xEA,
|
||||
0x70, 0x4C,
|
||||
0xB8,
|
||||
0x61,
|
||||
0xAA,
|
||||
0xAB,
|
||||
0x12,
|
||||
0x58,
|
||||
0xBB,
|
||||
0x5D
|
||||
};
|
||||
|
||||
Debug.Assert(data.Length == Unsafe.SizeOf<Guid>());
|
||||
return ref Unsafe.As<byte, Guid>(ref MemoryMarshal.GetReference(data));
|
||||
}
|
||||
}
|
||||
|
||||
public static Guid* NativeGuid => (Guid*)Unsafe.AsPointer(ref Unsafe.AsRef(in IID_ID3D11On12Device1));
|
||||
|
||||
public void** lpVtbl;
|
||||
|
||||
/// <inheritdoc cref="IUnknown.QueryInterface" />
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
[VtblIndex(0)]
|
||||
public HResult QueryInterface([NativeTypeName("const IID &")] Guid* riid, void** ppvObject)
|
||||
{
|
||||
return ((delegate* unmanaged[Stdcall]<IUnknown*, Guid*, void**, int>)(lpVtbl[0]))((IUnknown*)Unsafe.AsPointer(ref this), riid, ppvObject);
|
||||
}
|
||||
|
||||
/// <inheritdoc cref="IUnknown.AddRef" />
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
[VtblIndex(1)]
|
||||
[return: NativeTypeName("ULONG")]
|
||||
public uint AddRef()
|
||||
{
|
||||
return ((delegate* unmanaged[Stdcall]<IUnknown*, uint>)(lpVtbl[1]))((IUnknown*)Unsafe.AsPointer(ref this));
|
||||
}
|
||||
|
||||
/// <inheritdoc cref="IUnknown.Release" />
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
[VtblIndex(2)]
|
||||
[return: NativeTypeName("ULONG")]
|
||||
public uint Release()
|
||||
{
|
||||
return ((delegate* unmanaged[Stdcall]<IUnknown*, uint>)(lpVtbl[2]))((IUnknown*)Unsafe.AsPointer(ref this));
|
||||
}
|
||||
|
||||
/// <inheritdoc cref="ID3D11On12Device.CreateWrappedResource" />
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
[VtblIndex(3)]
|
||||
public HResult CreateWrappedResource(IUnknown* pResource12, ResourceFlags* pFlags11, Graphics.Direct3D12.ResourceStates InState, Graphics.Direct3D12.ResourceStates OutState, Guid* riid, void** ppResource11)
|
||||
{
|
||||
return ((delegate* unmanaged[Stdcall]<ID3D11On12Device1*, IUnknown*, ResourceFlags*, Graphics.Direct3D12.ResourceStates, Graphics.Direct3D12.ResourceStates, Guid*, void**, int>)(lpVtbl[3]))((ID3D11On12Device1*)Unsafe.AsPointer(ref this), pResource12, pFlags11, InState, OutState, riid, ppResource11);
|
||||
}
|
||||
|
||||
/// <inheritdoc cref="ID3D11On12Device.ReleaseWrappedResources" />
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
[VtblIndex(4)]
|
||||
public void ReleaseWrappedResources(Graphics.Direct3D11.ID3D11Resource** ppResources, uint NumResources)
|
||||
{
|
||||
((delegate* unmanaged[Stdcall]<ID3D11On12Device1*, Graphics.Direct3D11.ID3D11Resource**, uint, void>)(lpVtbl[4]))((ID3D11On12Device1*)Unsafe.AsPointer(ref this), ppResources, NumResources);
|
||||
}
|
||||
|
||||
/// <inheritdoc cref="ID3D11On12Device.AcquireWrappedResources" />
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
[VtblIndex(5)]
|
||||
public void AcquireWrappedResources(Graphics.Direct3D11.ID3D11Resource** ppResources, uint NumResources)
|
||||
{
|
||||
((delegate* unmanaged[Stdcall]<ID3D11On12Device1*, Graphics.Direct3D11.ID3D11Resource**, uint, void>)(lpVtbl[5]))((ID3D11On12Device1*)Unsafe.AsPointer(ref this), ppResources, NumResources);
|
||||
}
|
||||
|
||||
/// <include file='../../Direct3D11on12.xml' path='doc/member[@name="ID3D11On12Device1::GetD3D12Device"]/*' />
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
[VtblIndex(6)]
|
||||
public HResult GetD3D12Device(Guid* riid, void** ppvDevice)
|
||||
{
|
||||
return ((delegate* unmanaged[Stdcall]<ID3D11On12Device1*, Guid*, void**, int>)(lpVtbl[6]))((ID3D11On12Device1*)Unsafe.AsPointer(ref this), riid, ppvDevice);
|
||||
}
|
||||
}
|
||||
|
||||
121
src/Vortice.Win32.Direct3D11on12/Generated/ID3D11On12Device2.cs
Normal file
121
src/Vortice.Win32.Direct3D11on12/Generated/ID3D11On12Device2.cs
Normal file
@@ -0,0 +1,121 @@
|
||||
// ------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
// ------------------------------------------------------------------------------
|
||||
|
||||
namespace Win32.Graphics.Direct3D11on12;
|
||||
|
||||
/// <include file='../../Direct3D11on12.xml' path='doc/member[@name="ID3D11On12Device2"]/*' />
|
||||
/// <unmanaged>ID3D11On12Device2</unmanaged>
|
||||
[Guid("dc90f331-4740-43fa-866e-67f12cb58223")]
|
||||
[NativeTypeName("struct ID3D11On12Device2 : ID3D11On12Device1")]
|
||||
[NativeInheritance("ID3D11On12Device1")]
|
||||
public unsafe partial struct ID3D11On12Device2
|
||||
{
|
||||
public static ref readonly Guid IID_ID3D11On12Device2
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
get
|
||||
{
|
||||
ReadOnlySpan<byte> data = new byte[] {
|
||||
0x31, 0xF3, 0x90, 0xDC,
|
||||
0x40, 0x47,
|
||||
0xFA, 0x43,
|
||||
0x86,
|
||||
0x6E,
|
||||
0x67,
|
||||
0xF1,
|
||||
0x2C,
|
||||
0xB5,
|
||||
0x82,
|
||||
0x23
|
||||
};
|
||||
|
||||
Debug.Assert(data.Length == Unsafe.SizeOf<Guid>());
|
||||
return ref Unsafe.As<byte, Guid>(ref MemoryMarshal.GetReference(data));
|
||||
}
|
||||
}
|
||||
|
||||
public static Guid* NativeGuid => (Guid*)Unsafe.AsPointer(ref Unsafe.AsRef(in IID_ID3D11On12Device2));
|
||||
|
||||
public void** lpVtbl;
|
||||
|
||||
/// <inheritdoc cref="IUnknown.QueryInterface" />
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
[VtblIndex(0)]
|
||||
public HResult QueryInterface([NativeTypeName("const IID &")] Guid* riid, void** ppvObject)
|
||||
{
|
||||
return ((delegate* unmanaged[Stdcall]<IUnknown*, Guid*, void**, int>)(lpVtbl[0]))((IUnknown*)Unsafe.AsPointer(ref this), riid, ppvObject);
|
||||
}
|
||||
|
||||
/// <inheritdoc cref="IUnknown.AddRef" />
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
[VtblIndex(1)]
|
||||
[return: NativeTypeName("ULONG")]
|
||||
public uint AddRef()
|
||||
{
|
||||
return ((delegate* unmanaged[Stdcall]<IUnknown*, uint>)(lpVtbl[1]))((IUnknown*)Unsafe.AsPointer(ref this));
|
||||
}
|
||||
|
||||
/// <inheritdoc cref="IUnknown.Release" />
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
[VtblIndex(2)]
|
||||
[return: NativeTypeName("ULONG")]
|
||||
public uint Release()
|
||||
{
|
||||
return ((delegate* unmanaged[Stdcall]<IUnknown*, uint>)(lpVtbl[2]))((IUnknown*)Unsafe.AsPointer(ref this));
|
||||
}
|
||||
|
||||
/// <inheritdoc cref="ID3D11On12Device.CreateWrappedResource" />
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
[VtblIndex(3)]
|
||||
public HResult CreateWrappedResource(IUnknown* pResource12, ResourceFlags* pFlags11, Graphics.Direct3D12.ResourceStates InState, Graphics.Direct3D12.ResourceStates OutState, Guid* riid, void** ppResource11)
|
||||
{
|
||||
return ((delegate* unmanaged[Stdcall]<ID3D11On12Device2*, IUnknown*, ResourceFlags*, Graphics.Direct3D12.ResourceStates, Graphics.Direct3D12.ResourceStates, Guid*, void**, int>)(lpVtbl[3]))((ID3D11On12Device2*)Unsafe.AsPointer(ref this), pResource12, pFlags11, InState, OutState, riid, ppResource11);
|
||||
}
|
||||
|
||||
/// <inheritdoc cref="ID3D11On12Device.ReleaseWrappedResources" />
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
[VtblIndex(4)]
|
||||
public void ReleaseWrappedResources(Graphics.Direct3D11.ID3D11Resource** ppResources, uint NumResources)
|
||||
{
|
||||
((delegate* unmanaged[Stdcall]<ID3D11On12Device2*, Graphics.Direct3D11.ID3D11Resource**, uint, void>)(lpVtbl[4]))((ID3D11On12Device2*)Unsafe.AsPointer(ref this), ppResources, NumResources);
|
||||
}
|
||||
|
||||
/// <inheritdoc cref="ID3D11On12Device.AcquireWrappedResources" />
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
[VtblIndex(5)]
|
||||
public void AcquireWrappedResources(Graphics.Direct3D11.ID3D11Resource** ppResources, uint NumResources)
|
||||
{
|
||||
((delegate* unmanaged[Stdcall]<ID3D11On12Device2*, Graphics.Direct3D11.ID3D11Resource**, uint, void>)(lpVtbl[5]))((ID3D11On12Device2*)Unsafe.AsPointer(ref this), ppResources, NumResources);
|
||||
}
|
||||
|
||||
/// <inheritdoc cref="ID3D11On12Device1.GetD3D12Device" />
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
[VtblIndex(6)]
|
||||
public HResult GetD3D12Device(Guid* riid, void** ppvDevice)
|
||||
{
|
||||
return ((delegate* unmanaged[Stdcall]<ID3D11On12Device2*, Guid*, void**, int>)(lpVtbl[6]))((ID3D11On12Device2*)Unsafe.AsPointer(ref this), riid, ppvDevice);
|
||||
}
|
||||
|
||||
/// <include file='../../Direct3D11on12.xml' path='doc/member[@name="ID3D11On12Device2::UnwrapUnderlyingResource"]/*' />
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
[VtblIndex(7)]
|
||||
public HResult UnwrapUnderlyingResource(Graphics.Direct3D11.ID3D11Resource* pResource11, Graphics.Direct3D12.ID3D12CommandQueue* pCommandQueue, Guid* riid, void** ppvResource12)
|
||||
{
|
||||
return ((delegate* unmanaged[Stdcall]<ID3D11On12Device2*, Graphics.Direct3D11.ID3D11Resource*, Graphics.Direct3D12.ID3D12CommandQueue*, Guid*, void**, int>)(lpVtbl[7]))((ID3D11On12Device2*)Unsafe.AsPointer(ref this), pResource11, pCommandQueue, riid, ppvResource12);
|
||||
}
|
||||
|
||||
/// <include file='../../Direct3D11on12.xml' path='doc/member[@name="ID3D11On12Device2::ReturnUnderlyingResource"]/*' />
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
[VtblIndex(8)]
|
||||
public HResult ReturnUnderlyingResource(Graphics.Direct3D11.ID3D11Resource* pResource11, uint NumSync, ulong* pSignalValues, Graphics.Direct3D12.ID3D12Fence** ppFences)
|
||||
{
|
||||
return ((delegate* unmanaged[Stdcall]<ID3D11On12Device2*, Graphics.Direct3D11.ID3D11Resource*, uint, ulong*, Graphics.Direct3D12.ID3D12Fence**, int>)(lpVtbl[8]))((ID3D11On12Device2*)Unsafe.AsPointer(ref this), pResource11, NumSync, pSignalValues, ppFences);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,25 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFrameworks>netstandard2.0;net6.0;net7.0</TargetFrameworks>
|
||||
<Description>Direct3D11on12 bindings.</Description>
|
||||
|
||||
<GenerateDocumentationFile>true</GenerateDocumentationFile>
|
||||
<NoWarn>0419;$(NoWarn)</NoWarn>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Using Include="System.Numerics" />
|
||||
<Using Include="System.Diagnostics" />
|
||||
<Using Include="System.Runtime.CompilerServices" />
|
||||
<Using Include="System.Runtime.InteropServices" />
|
||||
<Using Include="System.Diagnostics.CodeAnalysis" />
|
||||
<Using Include="Win32.Numerics" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\Vortice.Win32.Direct3D11\Vortice.Win32.Direct3D11.csproj" />
|
||||
<ProjectReference Include="..\Vortice.Win32.Direct3D12\Vortice.Win32.Direct3D12.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
@@ -1,16 +1,14 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFrameworks>netstandard2.0;net6.0;net7.0</TargetFrameworks>
|
||||
<Description>Direct3D12 API low level bindings.</Description>
|
||||
<Description>Direct3D12 bindings.</Description>
|
||||
|
||||
<GenerateDocumentationFile>true</GenerateDocumentationFile>
|
||||
<NoWarn>0419;$(NoWarn)</NoWarn>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<None Include="..\..\LICENSE" PackagePath="" Pack="true" />
|
||||
|
||||
<Using Include="System.Numerics" />
|
||||
<Using Include="System.Diagnostics" />
|
||||
<Using Include="System.Runtime.CompilerServices" />
|
||||
|
||||
@@ -28,7 +28,7 @@ public partial struct SwapChainDescription1
|
||||
/// </param>
|
||||
/// <param name="swapEffect">
|
||||
/// A <see cref="Dxgi.SwapEffect"/> value that describes the presentation model that is used by the swap chain and options for handling the contents of the presentation buffer after presenting a surface.
|
||||
/// You must specify the <see cref="SwapEffect.FlipSequential"/> value when you call the <see cref="IDXGIFactory2.CreateSwapChainForComposition(SharpGen.Runtime.IUnknown, SwapChainDescription1, IDXGIOutput?)"/> method because this method supports only flip presentation model.
|
||||
/// You must specify the <see cref="SwapEffect.FlipSequential"/> value when you call the <see cref="IDXGIFactory2.CreateSwapChainForComposition(IUnknown*, SwapChainDescription1*, IDXGIOutput*, IDXGISwapChain1**)"/> method because this method supports only flip presentation model.
|
||||
/// </param>
|
||||
/// <param name="alphaMode">
|
||||
/// A <see cref="Dxgi.Common.AlphaMode"/> value that identifies the transparency behavior of the swap-chain back buffer.
|
||||
|
||||
@@ -6,6 +6,6 @@ namespace Win32;
|
||||
public interface INativeGuid
|
||||
{
|
||||
#if NET6_0_OR_GREATER
|
||||
protected unsafe internal static Guid* NativeGuid { get; }
|
||||
protected internal unsafe static abstract Guid* NativeGuid { get; }
|
||||
#endif
|
||||
}
|
||||
|
||||
@@ -30,7 +30,7 @@ public unsafe partial struct IUnknown : INativeGuid
|
||||
}
|
||||
|
||||
#if NET6_0_OR_GREATER
|
||||
internal static Guid* NativeGuid => (Guid*)Unsafe.AsPointer(ref Unsafe.AsRef(in IID_IUnknown));
|
||||
static Guid* INativeGuid.NativeGuid => (Guid*)Unsafe.AsPointer(ref Unsafe.AsRef(in IID_IUnknown));
|
||||
#else
|
||||
public static Guid* NativeGuid => (Guid*)Unsafe.AsPointer(ref Unsafe.AsRef(in IID_IUnknown));
|
||||
#endif
|
||||
|
||||
@@ -38,6 +38,10 @@
|
||||
<AssemblyAttribute Include="System.Runtime.CompilerServices.InternalsVisibleToAttribute">
|
||||
<_Parameter1>Vortice.Win32.Direct3D12</_Parameter1>
|
||||
</AssemblyAttribute>
|
||||
|
||||
<AssemblyAttribute Include="System.Runtime.CompilerServices.InternalsVisibleToAttribute">
|
||||
<_Parameter1>Vortice.Win32.Direct3D11on12</_Parameter1>
|
||||
</AssemblyAttribute>
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
||||
Reference in New Issue
Block a user