Add initial ID2D1DrawTransformMapper support and APIs
このコミットが含まれているのは:
1 親
a67237370a
コミット
a36bae8e5a
6ファイル変更
+338
-44
検索条件に一致するファイルはありません
@@ -0,0 +1,22 @@
|
||||
using System.Drawing;
|
||||
using System.Runtime.CompilerServices;
|
||||
using TerraFX.Interop.Windows;
|
||||
|
||||
namespace ComputeSharp.D2D1.Extensions;
|
||||
|
||||
/// <summary>
|
||||
/// Helper methods for <see cref="RECT"/>.
|
||||
/// </summary>
|
||||
internal static class RECTExtensions
|
||||
{
|
||||
/// <summary>
|
||||
/// Creates a <see cref="Rectangle"/> from a <see cref="RECT"/> value.
|
||||
/// </summary>
|
||||
/// <param name="rect">The input <see cref="RECT"/> value.</param>
|
||||
/// <returns>The resulting <see cref="Rectangle"/> value.</returns>
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
public static Rectangle ToRectangle(this in RECT rect)
|
||||
{
|
||||
return Rectangle.FromLTRB(rect.left, rect.top, rect.right, rect.bottom);
|
||||
}
|
||||
}
|
||||
新しいイシューから参照
ユーザーをブロックする