Generator: Improve struct return types in other cases (ID2D1Bitmap::GetPixelSize)

This commit is contained in:
Amer Koleci
2022-09-20 14:35:31 +02:00
parent 1309d11476
commit 2fcf8a7e94
30 changed files with 144 additions and 46 deletions

View File

@@ -1985,8 +1985,9 @@ public static class Program
if (returnType != "void" &&
method.ReturnType.TargetKind != "Com" &&
method.ReturnType.Kind == "ApiRef" &&
!IsPrimitive(method.ReturnType) &&
!IsEnum(method.ReturnType))
!IsEnum(method.ReturnType) &&
IsStructAsReturnMarshal(method.ReturnType)
)
{
useReturnAsParameter = true;
}
@@ -2699,6 +2700,59 @@ public static class Program
return IsPrimitive(typeName);
}
private static bool IsStructAsReturnMarshal(ApiDataType dataType)
{
if (dataType.Kind != "ApiRef")
{
throw new InvalidOperationException();
}
string apiRefType = GetTypeName($"{dataType.Api}.{dataType.Name}");
if (apiRefType.EndsWith("*"))
{
apiRefType = apiRefType.Substring(0, apiRefType.Length - 1);
}
switch (apiRefType)
{
case "void":
case "bool":
case "byte":
case "sbyte":
case "int":
case "uint":
case "short":
case "ushort":
case "long":
case "ulong":
case "float":
case "double":
return false;
case "nint":
case "nuint":
case "IntPtr":
case "UIntPtr":
case "Guid":
return false;
case "Bool32":
case "HResult":
return false;
case "LargeInteger":
case "ULargeInteger":
return true;
case "Luid":
return true;
default:
return true;
}
}
private static bool IsEnum(ApiDataType dataType)
{
if (dataType.Kind == "ApiRef")

View File

@@ -88,7 +88,8 @@ public unsafe partial struct ID2D1Bitmap
[VtblIndex(4)]
public System.Drawing.SizeF GetSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1Bitmap*, System.Drawing.SizeF>)(lpVtbl[4]))((ID2D1Bitmap*)Unsafe.AsPointer(ref this));
System.Drawing.SizeF result;
return *((delegate* unmanaged[Stdcall]<ID2D1Bitmap*, System.Drawing.SizeF*, System.Drawing.SizeF*>)(lpVtbl[4]))((ID2D1Bitmap*)Unsafe.AsPointer(ref this), &result);
}
/// <include file='../../Direct2D.xml' path='doc/member[@name="ID2D1Bitmap::GetPixelSize"]/*' />
@@ -96,7 +97,8 @@ public unsafe partial struct ID2D1Bitmap
[VtblIndex(5)]
public System.Drawing.Size GetPixelSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1Bitmap*, System.Drawing.Size>)(lpVtbl[5]))((ID2D1Bitmap*)Unsafe.AsPointer(ref this));
System.Drawing.Size result;
return *((delegate* unmanaged[Stdcall]<ID2D1Bitmap*, System.Drawing.Size*, System.Drawing.Size*>)(lpVtbl[5]))((ID2D1Bitmap*)Unsafe.AsPointer(ref this), &result);
}
/// <include file='../../Direct2D.xml' path='doc/member[@name="ID2D1Bitmap::GetPixelFormat"]/*' />

View File

@@ -88,7 +88,8 @@ public unsafe partial struct ID2D1Bitmap1
[VtblIndex(4)]
public System.Drawing.SizeF GetSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1Bitmap1*, System.Drawing.SizeF>)(lpVtbl[4]))((ID2D1Bitmap1*)Unsafe.AsPointer(ref this));
System.Drawing.SizeF result;
return *((delegate* unmanaged[Stdcall]<ID2D1Bitmap1*, System.Drawing.SizeF*, System.Drawing.SizeF*>)(lpVtbl[4]))((ID2D1Bitmap1*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID2D1Bitmap.GetPixelSize" />
@@ -96,7 +97,8 @@ public unsafe partial struct ID2D1Bitmap1
[VtblIndex(5)]
public System.Drawing.Size GetPixelSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1Bitmap1*, System.Drawing.Size>)(lpVtbl[5]))((ID2D1Bitmap1*)Unsafe.AsPointer(ref this));
System.Drawing.Size result;
return *((delegate* unmanaged[Stdcall]<ID2D1Bitmap1*, System.Drawing.Size*, System.Drawing.Size*>)(lpVtbl[5]))((ID2D1Bitmap1*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID2D1Bitmap.GetPixelFormat" />

View File

@@ -481,7 +481,8 @@ public unsafe partial struct ID2D1BitmapRenderTarget
[VtblIndex(53)]
public System.Drawing.SizeF GetSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1BitmapRenderTarget*, System.Drawing.SizeF>)(lpVtbl[53]))((ID2D1BitmapRenderTarget*)Unsafe.AsPointer(ref this));
System.Drawing.SizeF result;
return *((delegate* unmanaged[Stdcall]<ID2D1BitmapRenderTarget*, System.Drawing.SizeF*, System.Drawing.SizeF*>)(lpVtbl[53]))((ID2D1BitmapRenderTarget*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID2D1RenderTarget.GetPixelSize" />
@@ -489,7 +490,8 @@ public unsafe partial struct ID2D1BitmapRenderTarget
[VtblIndex(54)]
public System.Drawing.Size GetPixelSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1BitmapRenderTarget*, System.Drawing.Size>)(lpVtbl[54]))((ID2D1BitmapRenderTarget*)Unsafe.AsPointer(ref this));
System.Drawing.Size result;
return *((delegate* unmanaged[Stdcall]<ID2D1BitmapRenderTarget*, System.Drawing.Size*, System.Drawing.Size*>)(lpVtbl[54]))((ID2D1BitmapRenderTarget*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID2D1RenderTarget.GetMaximumBitmapSize" />

View File

@@ -481,7 +481,8 @@ public unsafe partial struct ID2D1DCRenderTarget
[VtblIndex(53)]
public System.Drawing.SizeF GetSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1DCRenderTarget*, System.Drawing.SizeF>)(lpVtbl[53]))((ID2D1DCRenderTarget*)Unsafe.AsPointer(ref this));
System.Drawing.SizeF result;
return *((delegate* unmanaged[Stdcall]<ID2D1DCRenderTarget*, System.Drawing.SizeF*, System.Drawing.SizeF*>)(lpVtbl[53]))((ID2D1DCRenderTarget*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID2D1RenderTarget.GetPixelSize" />
@@ -489,7 +490,8 @@ public unsafe partial struct ID2D1DCRenderTarget
[VtblIndex(54)]
public System.Drawing.Size GetPixelSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1DCRenderTarget*, System.Drawing.Size>)(lpVtbl[54]))((ID2D1DCRenderTarget*)Unsafe.AsPointer(ref this));
System.Drawing.Size result;
return *((delegate* unmanaged[Stdcall]<ID2D1DCRenderTarget*, System.Drawing.Size*, System.Drawing.Size*>)(lpVtbl[54]))((ID2D1DCRenderTarget*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID2D1RenderTarget.GetMaximumBitmapSize" />

View File

@@ -481,7 +481,8 @@ public unsafe partial struct ID2D1DeviceContext
[VtblIndex(53)]
public System.Drawing.SizeF GetSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1DeviceContext*, System.Drawing.SizeF>)(lpVtbl[53]))((ID2D1DeviceContext*)Unsafe.AsPointer(ref this));
System.Drawing.SizeF result;
return *((delegate* unmanaged[Stdcall]<ID2D1DeviceContext*, System.Drawing.SizeF*, System.Drawing.SizeF*>)(lpVtbl[53]))((ID2D1DeviceContext*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID2D1RenderTarget.GetPixelSize" />
@@ -489,7 +490,8 @@ public unsafe partial struct ID2D1DeviceContext
[VtblIndex(54)]
public System.Drawing.Size GetPixelSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1DeviceContext*, System.Drawing.Size>)(lpVtbl[54]))((ID2D1DeviceContext*)Unsafe.AsPointer(ref this));
System.Drawing.Size result;
return *((delegate* unmanaged[Stdcall]<ID2D1DeviceContext*, System.Drawing.Size*, System.Drawing.Size*>)(lpVtbl[54]))((ID2D1DeviceContext*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID2D1RenderTarget.GetMaximumBitmapSize" />

View File

@@ -481,7 +481,8 @@ public unsafe partial struct ID2D1DeviceContext1
[VtblIndex(53)]
public System.Drawing.SizeF GetSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1DeviceContext1*, System.Drawing.SizeF>)(lpVtbl[53]))((ID2D1DeviceContext1*)Unsafe.AsPointer(ref this));
System.Drawing.SizeF result;
return *((delegate* unmanaged[Stdcall]<ID2D1DeviceContext1*, System.Drawing.SizeF*, System.Drawing.SizeF*>)(lpVtbl[53]))((ID2D1DeviceContext1*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID2D1RenderTarget.GetPixelSize" />
@@ -489,7 +490,8 @@ public unsafe partial struct ID2D1DeviceContext1
[VtblIndex(54)]
public System.Drawing.Size GetPixelSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1DeviceContext1*, System.Drawing.Size>)(lpVtbl[54]))((ID2D1DeviceContext1*)Unsafe.AsPointer(ref this));
System.Drawing.Size result;
return *((delegate* unmanaged[Stdcall]<ID2D1DeviceContext1*, System.Drawing.Size*, System.Drawing.Size*>)(lpVtbl[54]))((ID2D1DeviceContext1*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID2D1RenderTarget.GetMaximumBitmapSize" />

View File

@@ -481,7 +481,8 @@ public unsafe partial struct ID2D1DeviceContext2
[VtblIndex(53)]
public System.Drawing.SizeF GetSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1DeviceContext2*, System.Drawing.SizeF>)(lpVtbl[53]))((ID2D1DeviceContext2*)Unsafe.AsPointer(ref this));
System.Drawing.SizeF result;
return *((delegate* unmanaged[Stdcall]<ID2D1DeviceContext2*, System.Drawing.SizeF*, System.Drawing.SizeF*>)(lpVtbl[53]))((ID2D1DeviceContext2*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID2D1RenderTarget.GetPixelSize" />
@@ -489,7 +490,8 @@ public unsafe partial struct ID2D1DeviceContext2
[VtblIndex(54)]
public System.Drawing.Size GetPixelSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1DeviceContext2*, System.Drawing.Size>)(lpVtbl[54]))((ID2D1DeviceContext2*)Unsafe.AsPointer(ref this));
System.Drawing.Size result;
return *((delegate* unmanaged[Stdcall]<ID2D1DeviceContext2*, System.Drawing.Size*, System.Drawing.Size*>)(lpVtbl[54]))((ID2D1DeviceContext2*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID2D1RenderTarget.GetMaximumBitmapSize" />

View File

@@ -481,7 +481,8 @@ public unsafe partial struct ID2D1DeviceContext3
[VtblIndex(53)]
public System.Drawing.SizeF GetSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1DeviceContext3*, System.Drawing.SizeF>)(lpVtbl[53]))((ID2D1DeviceContext3*)Unsafe.AsPointer(ref this));
System.Drawing.SizeF result;
return *((delegate* unmanaged[Stdcall]<ID2D1DeviceContext3*, System.Drawing.SizeF*, System.Drawing.SizeF*>)(lpVtbl[53]))((ID2D1DeviceContext3*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID2D1RenderTarget.GetPixelSize" />
@@ -489,7 +490,8 @@ public unsafe partial struct ID2D1DeviceContext3
[VtblIndex(54)]
public System.Drawing.Size GetPixelSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1DeviceContext3*, System.Drawing.Size>)(lpVtbl[54]))((ID2D1DeviceContext3*)Unsafe.AsPointer(ref this));
System.Drawing.Size result;
return *((delegate* unmanaged[Stdcall]<ID2D1DeviceContext3*, System.Drawing.Size*, System.Drawing.Size*>)(lpVtbl[54]))((ID2D1DeviceContext3*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID2D1RenderTarget.GetMaximumBitmapSize" />

View File

@@ -481,7 +481,8 @@ public unsafe partial struct ID2D1DeviceContext4
[VtblIndex(53)]
public System.Drawing.SizeF GetSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1DeviceContext4*, System.Drawing.SizeF>)(lpVtbl[53]))((ID2D1DeviceContext4*)Unsafe.AsPointer(ref this));
System.Drawing.SizeF result;
return *((delegate* unmanaged[Stdcall]<ID2D1DeviceContext4*, System.Drawing.SizeF*, System.Drawing.SizeF*>)(lpVtbl[53]))((ID2D1DeviceContext4*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID2D1RenderTarget.GetPixelSize" />
@@ -489,7 +490,8 @@ public unsafe partial struct ID2D1DeviceContext4
[VtblIndex(54)]
public System.Drawing.Size GetPixelSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1DeviceContext4*, System.Drawing.Size>)(lpVtbl[54]))((ID2D1DeviceContext4*)Unsafe.AsPointer(ref this));
System.Drawing.Size result;
return *((delegate* unmanaged[Stdcall]<ID2D1DeviceContext4*, System.Drawing.Size*, System.Drawing.Size*>)(lpVtbl[54]))((ID2D1DeviceContext4*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID2D1RenderTarget.GetMaximumBitmapSize" />

View File

@@ -481,7 +481,8 @@ public unsafe partial struct ID2D1DeviceContext5
[VtblIndex(53)]
public System.Drawing.SizeF GetSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1DeviceContext5*, System.Drawing.SizeF>)(lpVtbl[53]))((ID2D1DeviceContext5*)Unsafe.AsPointer(ref this));
System.Drawing.SizeF result;
return *((delegate* unmanaged[Stdcall]<ID2D1DeviceContext5*, System.Drawing.SizeF*, System.Drawing.SizeF*>)(lpVtbl[53]))((ID2D1DeviceContext5*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID2D1RenderTarget.GetPixelSize" />
@@ -489,7 +490,8 @@ public unsafe partial struct ID2D1DeviceContext5
[VtblIndex(54)]
public System.Drawing.Size GetPixelSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1DeviceContext5*, System.Drawing.Size>)(lpVtbl[54]))((ID2D1DeviceContext5*)Unsafe.AsPointer(ref this));
System.Drawing.Size result;
return *((delegate* unmanaged[Stdcall]<ID2D1DeviceContext5*, System.Drawing.Size*, System.Drawing.Size*>)(lpVtbl[54]))((ID2D1DeviceContext5*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID2D1RenderTarget.GetMaximumBitmapSize" />

View File

@@ -481,7 +481,8 @@ public unsafe partial struct ID2D1DeviceContext6
[VtblIndex(53)]
public System.Drawing.SizeF GetSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1DeviceContext6*, System.Drawing.SizeF>)(lpVtbl[53]))((ID2D1DeviceContext6*)Unsafe.AsPointer(ref this));
System.Drawing.SizeF result;
return *((delegate* unmanaged[Stdcall]<ID2D1DeviceContext6*, System.Drawing.SizeF*, System.Drawing.SizeF*>)(lpVtbl[53]))((ID2D1DeviceContext6*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID2D1RenderTarget.GetPixelSize" />
@@ -489,7 +490,8 @@ public unsafe partial struct ID2D1DeviceContext6
[VtblIndex(54)]
public System.Drawing.Size GetPixelSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1DeviceContext6*, System.Drawing.Size>)(lpVtbl[54]))((ID2D1DeviceContext6*)Unsafe.AsPointer(ref this));
System.Drawing.Size result;
return *((delegate* unmanaged[Stdcall]<ID2D1DeviceContext6*, System.Drawing.Size*, System.Drawing.Size*>)(lpVtbl[54]))((ID2D1DeviceContext6*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID2D1RenderTarget.GetMaximumBitmapSize" />

View File

@@ -481,7 +481,8 @@ public unsafe partial struct ID2D1HwndRenderTarget
[VtblIndex(53)]
public System.Drawing.SizeF GetSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1HwndRenderTarget*, System.Drawing.SizeF>)(lpVtbl[53]))((ID2D1HwndRenderTarget*)Unsafe.AsPointer(ref this));
System.Drawing.SizeF result;
return *((delegate* unmanaged[Stdcall]<ID2D1HwndRenderTarget*, System.Drawing.SizeF*, System.Drawing.SizeF*>)(lpVtbl[53]))((ID2D1HwndRenderTarget*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID2D1RenderTarget.GetPixelSize" />
@@ -489,7 +490,8 @@ public unsafe partial struct ID2D1HwndRenderTarget
[VtblIndex(54)]
public System.Drawing.Size GetPixelSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1HwndRenderTarget*, System.Drawing.Size>)(lpVtbl[54]))((ID2D1HwndRenderTarget*)Unsafe.AsPointer(ref this));
System.Drawing.Size result;
return *((delegate* unmanaged[Stdcall]<ID2D1HwndRenderTarget*, System.Drawing.Size*, System.Drawing.Size*>)(lpVtbl[54]))((ID2D1HwndRenderTarget*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID2D1RenderTarget.GetMaximumBitmapSize" />

View File

@@ -88,7 +88,8 @@ public unsafe partial struct ID2D1Layer
[VtblIndex(4)]
public System.Drawing.SizeF GetSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1Layer*, System.Drawing.SizeF>)(lpVtbl[4]))((ID2D1Layer*)Unsafe.AsPointer(ref this));
System.Drawing.SizeF result;
return *((delegate* unmanaged[Stdcall]<ID2D1Layer*, System.Drawing.SizeF*, System.Drawing.SizeF*>)(lpVtbl[4]))((ID2D1Layer*)Unsafe.AsPointer(ref this), &result);
}
}

View File

@@ -136,7 +136,8 @@ public unsafe partial struct ID2D1LinearGradientBrush
[VtblIndex(10)]
public System.Drawing.PointF GetStartPoint()
{
return ((delegate* unmanaged[Stdcall]<ID2D1LinearGradientBrush*, System.Drawing.PointF>)(lpVtbl[10]))((ID2D1LinearGradientBrush*)Unsafe.AsPointer(ref this));
System.Drawing.PointF result;
return *((delegate* unmanaged[Stdcall]<ID2D1LinearGradientBrush*, System.Drawing.PointF*, System.Drawing.PointF*>)(lpVtbl[10]))((ID2D1LinearGradientBrush*)Unsafe.AsPointer(ref this), &result);
}
/// <include file='../../Direct2D.xml' path='doc/member[@name="ID2D1LinearGradientBrush::GetEndPoint"]/*' />
@@ -144,7 +145,8 @@ public unsafe partial struct ID2D1LinearGradientBrush
[VtblIndex(11)]
public System.Drawing.PointF GetEndPoint()
{
return ((delegate* unmanaged[Stdcall]<ID2D1LinearGradientBrush*, System.Drawing.PointF>)(lpVtbl[11]))((ID2D1LinearGradientBrush*)Unsafe.AsPointer(ref this));
System.Drawing.PointF result;
return *((delegate* unmanaged[Stdcall]<ID2D1LinearGradientBrush*, System.Drawing.PointF*, System.Drawing.PointF*>)(lpVtbl[11]))((ID2D1LinearGradientBrush*)Unsafe.AsPointer(ref this), &result);
}
/// <include file='../../Direct2D.xml' path='doc/member[@name="ID2D1LinearGradientBrush::GetGradientStopCollection"]/*' />

View File

@@ -96,7 +96,8 @@ public unsafe partial struct ID2D1OffsetTransform
[VtblIndex(5)]
public System.Drawing.Point GetOffset()
{
return ((delegate* unmanaged[Stdcall]<ID2D1OffsetTransform*, System.Drawing.Point>)(lpVtbl[5]))((ID2D1OffsetTransform*)Unsafe.AsPointer(ref this));
System.Drawing.Point result;
return *((delegate* unmanaged[Stdcall]<ID2D1OffsetTransform*, System.Drawing.Point*, System.Drawing.Point*>)(lpVtbl[5]))((ID2D1OffsetTransform*)Unsafe.AsPointer(ref this), &result);
}
}

View File

@@ -152,7 +152,8 @@ public unsafe partial struct ID2D1RadialGradientBrush
[VtblIndex(12)]
public System.Drawing.PointF GetCenter()
{
return ((delegate* unmanaged[Stdcall]<ID2D1RadialGradientBrush*, System.Drawing.PointF>)(lpVtbl[12]))((ID2D1RadialGradientBrush*)Unsafe.AsPointer(ref this));
System.Drawing.PointF result;
return *((delegate* unmanaged[Stdcall]<ID2D1RadialGradientBrush*, System.Drawing.PointF*, System.Drawing.PointF*>)(lpVtbl[12]))((ID2D1RadialGradientBrush*)Unsafe.AsPointer(ref this), &result);
}
/// <include file='../../Direct2D.xml' path='doc/member[@name="ID2D1RadialGradientBrush::GetGradientOriginOffset"]/*' />
@@ -160,7 +161,8 @@ public unsafe partial struct ID2D1RadialGradientBrush
[VtblIndex(13)]
public System.Drawing.PointF GetGradientOriginOffset()
{
return ((delegate* unmanaged[Stdcall]<ID2D1RadialGradientBrush*, System.Drawing.PointF>)(lpVtbl[13]))((ID2D1RadialGradientBrush*)Unsafe.AsPointer(ref this));
System.Drawing.PointF result;
return *((delegate* unmanaged[Stdcall]<ID2D1RadialGradientBrush*, System.Drawing.PointF*, System.Drawing.PointF*>)(lpVtbl[13]))((ID2D1RadialGradientBrush*)Unsafe.AsPointer(ref this), &result);
}
/// <include file='../../Direct2D.xml' path='doc/member[@name="ID2D1RadialGradientBrush::GetRadiusX"]/*' />

View File

@@ -481,7 +481,8 @@ public unsafe partial struct ID2D1RenderTarget
[VtblIndex(53)]
public System.Drawing.SizeF GetSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1RenderTarget*, System.Drawing.SizeF>)(lpVtbl[53]))((ID2D1RenderTarget*)Unsafe.AsPointer(ref this));
System.Drawing.SizeF result;
return *((delegate* unmanaged[Stdcall]<ID2D1RenderTarget*, System.Drawing.SizeF*, System.Drawing.SizeF*>)(lpVtbl[53]))((ID2D1RenderTarget*)Unsafe.AsPointer(ref this), &result);
}
/// <include file='../../Direct2D.xml' path='doc/member[@name="ID2D1RenderTarget::GetPixelSize"]/*' />
@@ -489,7 +490,8 @@ public unsafe partial struct ID2D1RenderTarget
[VtblIndex(54)]
public System.Drawing.Size GetPixelSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1RenderTarget*, System.Drawing.Size>)(lpVtbl[54]))((ID2D1RenderTarget*)Unsafe.AsPointer(ref this));
System.Drawing.Size result;
return *((delegate* unmanaged[Stdcall]<ID2D1RenderTarget*, System.Drawing.Size*, System.Drawing.Size*>)(lpVtbl[54]))((ID2D1RenderTarget*)Unsafe.AsPointer(ref this), &result);
}
/// <include file='../../Direct2D.xml' path='doc/member[@name="ID2D1RenderTarget::GetMaximumBitmapSize"]/*' />

View File

@@ -96,7 +96,8 @@ public unsafe partial struct ID2D1SvgDocument
[VtblIndex(5)]
public System.Drawing.SizeF GetViewportSize()
{
return ((delegate* unmanaged[Stdcall]<ID2D1SvgDocument*, System.Drawing.SizeF>)(lpVtbl[5]))((ID2D1SvgDocument*)Unsafe.AsPointer(ref this));
System.Drawing.SizeF result;
return *((delegate* unmanaged[Stdcall]<ID2D1SvgDocument*, System.Drawing.SizeF*, System.Drawing.SizeF*>)(lpVtbl[5]))((ID2D1SvgDocument*)Unsafe.AsPointer(ref this), &result);
}
/// <include file='../../Direct2D.xml' path='doc/member[@name="ID2D1SvgDocument::SetRoot"]/*' />

View File

@@ -402,7 +402,8 @@ public unsafe partial struct ID3D12Device
[VtblIndex(43)]
public Luid GetAdapterLuid()
{
return ((delegate* unmanaged[Stdcall]<ID3D12Device*, Luid>)(lpVtbl[43]))((ID3D12Device*)Unsafe.AsPointer(ref this));
Luid result;
return *((delegate* unmanaged[Stdcall]<ID3D12Device*, Luid*, Luid*>)(lpVtbl[43]))((ID3D12Device*)Unsafe.AsPointer(ref this), &result);
}
}

View File

@@ -402,7 +402,8 @@ public unsafe partial struct ID3D12Device1
[VtblIndex(43)]
public Luid GetAdapterLuid()
{
return ((delegate* unmanaged[Stdcall]<ID3D12Device1*, Luid>)(lpVtbl[43]))((ID3D12Device1*)Unsafe.AsPointer(ref this));
Luid result;
return *((delegate* unmanaged[Stdcall]<ID3D12Device1*, Luid*, Luid*>)(lpVtbl[43]))((ID3D12Device1*)Unsafe.AsPointer(ref this), &result);
}
/// <include file='../../Direct3D12.xml' path='doc/member[@name="ID3D12Device1::CreatePipelineLibrary"]/*' />

View File

@@ -402,7 +402,8 @@ public unsafe partial struct ID3D12Device2
[VtblIndex(43)]
public Luid GetAdapterLuid()
{
return ((delegate* unmanaged[Stdcall]<ID3D12Device2*, Luid>)(lpVtbl[43]))((ID3D12Device2*)Unsafe.AsPointer(ref this));
Luid result;
return *((delegate* unmanaged[Stdcall]<ID3D12Device2*, Luid*, Luid*>)(lpVtbl[43]))((ID3D12Device2*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID3D12Device1.CreatePipelineLibrary" />

View File

@@ -402,7 +402,8 @@ public unsafe partial struct ID3D12Device3
[VtblIndex(43)]
public Luid GetAdapterLuid()
{
return ((delegate* unmanaged[Stdcall]<ID3D12Device3*, Luid>)(lpVtbl[43]))((ID3D12Device3*)Unsafe.AsPointer(ref this));
Luid result;
return *((delegate* unmanaged[Stdcall]<ID3D12Device3*, Luid*, Luid*>)(lpVtbl[43]))((ID3D12Device3*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID3D12Device1.CreatePipelineLibrary" />

View File

@@ -402,7 +402,8 @@ public unsafe partial struct ID3D12Device4
[VtblIndex(43)]
public Luid GetAdapterLuid()
{
return ((delegate* unmanaged[Stdcall]<ID3D12Device4*, Luid>)(lpVtbl[43]))((ID3D12Device4*)Unsafe.AsPointer(ref this));
Luid result;
return *((delegate* unmanaged[Stdcall]<ID3D12Device4*, Luid*, Luid*>)(lpVtbl[43]))((ID3D12Device4*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID3D12Device1.CreatePipelineLibrary" />

View File

@@ -402,7 +402,8 @@ public unsafe partial struct ID3D12Device5
[VtblIndex(43)]
public Luid GetAdapterLuid()
{
return ((delegate* unmanaged[Stdcall]<ID3D12Device5*, Luid>)(lpVtbl[43]))((ID3D12Device5*)Unsafe.AsPointer(ref this));
Luid result;
return *((delegate* unmanaged[Stdcall]<ID3D12Device5*, Luid*, Luid*>)(lpVtbl[43]))((ID3D12Device5*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID3D12Device1.CreatePipelineLibrary" />

View File

@@ -402,7 +402,8 @@ public unsafe partial struct ID3D12Device6
[VtblIndex(43)]
public Luid GetAdapterLuid()
{
return ((delegate* unmanaged[Stdcall]<ID3D12Device6*, Luid>)(lpVtbl[43]))((ID3D12Device6*)Unsafe.AsPointer(ref this));
Luid result;
return *((delegate* unmanaged[Stdcall]<ID3D12Device6*, Luid*, Luid*>)(lpVtbl[43]))((ID3D12Device6*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID3D12Device1.CreatePipelineLibrary" />

View File

@@ -402,7 +402,8 @@ public unsafe partial struct ID3D12Device7
[VtblIndex(43)]
public Luid GetAdapterLuid()
{
return ((delegate* unmanaged[Stdcall]<ID3D12Device7*, Luid>)(lpVtbl[43]))((ID3D12Device7*)Unsafe.AsPointer(ref this));
Luid result;
return *((delegate* unmanaged[Stdcall]<ID3D12Device7*, Luid*, Luid*>)(lpVtbl[43]))((ID3D12Device7*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID3D12Device1.CreatePipelineLibrary" />

View File

@@ -402,7 +402,8 @@ public unsafe partial struct ID3D12Device8
[VtblIndex(43)]
public Luid GetAdapterLuid()
{
return ((delegate* unmanaged[Stdcall]<ID3D12Device8*, Luid>)(lpVtbl[43]))((ID3D12Device8*)Unsafe.AsPointer(ref this));
Luid result;
return *((delegate* unmanaged[Stdcall]<ID3D12Device8*, Luid*, Luid*>)(lpVtbl[43]))((ID3D12Device8*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID3D12Device1.CreatePipelineLibrary" />

View File

@@ -402,7 +402,8 @@ public unsafe partial struct ID3D12Device9
[VtblIndex(43)]
public Luid GetAdapterLuid()
{
return ((delegate* unmanaged[Stdcall]<ID3D12Device9*, Luid>)(lpVtbl[43]))((ID3D12Device9*)Unsafe.AsPointer(ref this));
Luid result;
return *((delegate* unmanaged[Stdcall]<ID3D12Device9*, Luid*, Luid*>)(lpVtbl[43]))((ID3D12Device9*)Unsafe.AsPointer(ref this), &result);
}
/// <inheritdoc cref="ID3D12Device1.CreatePipelineLibrary" />

View File

@@ -80,7 +80,8 @@ public unsafe partial struct ID3D12SwapChainAssistant
[VtblIndex(3)]
public Luid GetLUID()
{
return ((delegate* unmanaged[Stdcall]<ID3D12SwapChainAssistant*, Luid>)(lpVtbl[3]))((ID3D12SwapChainAssistant*)Unsafe.AsPointer(ref this));
Luid result;
return *((delegate* unmanaged[Stdcall]<ID3D12SwapChainAssistant*, Luid*, Luid*>)(lpVtbl[3]))((ID3D12SwapChainAssistant*)Unsafe.AsPointer(ref this), &result);
}
/// <include file='../../Direct3D12.xml' path='doc/member[@name="ID3D12SwapChainAssistant::GetSwapChainObject"]/*' />