diff --git a/lib/RefreshCS b/lib/RefreshCS
index 848db82..237c3ae 160000
--- a/lib/RefreshCS
+++ b/lib/RefreshCS
@@ -1 +1 @@
-Subproject commit 848db820a6de3437f44e8e45f4c274f40bbfae27
+Subproject commit 237c3aebb6cfe0ec11f6de6134a07bac4735ede8
diff --git a/src/Graphics/CommandBuffer.cs b/src/Graphics/CommandBuffer.cs
index cc0abe2..03e001c 100644
--- a/src/Graphics/CommandBuffer.cs
+++ b/src/Graphics/CommandBuffer.cs
@@ -541,44 +541,6 @@ namespace MoonWorks.Graphics
}
}
- ///
- /// Clears the render targets on the current framebuffer to a single color or depth/stencil value.
- /// NOTE: It is recommended that you clear when beginning render passes unless you have a good reason to clear mid-pass.
- ///
- /// The area of the framebuffer to clear.
- /// Whether to clear colors, depth, or stencil value, or multiple.
- /// The depth/stencil clear values. Will be ignored if color is not provided in ClearOptions.
- /// The color clear values. Must provide one per render target. Can be omitted if depth/stencil is not cleared.
- public unsafe void Clear(
- in Rect clearRect,
- ClearOptionsFlags clearOptions,
- in DepthStencilValue depthStencilClearValue,
- params Vector4[] clearColors
- )
- {
- Refresh.Vec4* colors = stackalloc Refresh.Vec4[clearColors.Length];
- for (var i = 0; i < clearColors.Length; i++)
- {
- colors[i] = new Refresh.Vec4
- {
- x = clearColors[i].X,
- y = clearColors[i].Y,
- z = clearColors[i].Z,
- w = clearColors[i].W
- };
- }
-
- Refresh.Refresh_Clear(
- Device.Handle,
- Handle,
- clearRect.ToRefresh(),
- (Refresh.ClearOptionsFlags) clearOptions,
- (IntPtr) colors,
- (uint) clearColors.Length,
- depthStencilClearValue.ToRefresh()
- );
- }
-
///
/// Draws using instanced rendering.
/// It is an error to call this method unless two vertex buffers have been bound.
@@ -687,7 +649,9 @@ namespace MoonWorks.Graphics
var texturePtr = Refresh.Refresh_AcquireSwapchainTexture(
Device.Handle,
Handle,
- window.Handle
+ window.Handle,
+ out var width,
+ out var height
);
if (texturePtr == IntPtr.Zero)
@@ -699,8 +663,8 @@ namespace MoonWorks.Graphics
Device,
texturePtr,
Device.GetSwapchainFormat(window),
- window.Width,
- window.Height
+ width,
+ height
);
}