[GPU] Accept stencil targets with or without HTile backing
This commit is contained in:
parent
4a417d8381
commit
7218f7281e
|
|
@ -58,9 +58,6 @@ public static partial class ImageRequestBuilders
|
|||
return Format.Undefined;
|
||||
}
|
||||
|
||||
private static bool HtileStencilCompatible(bool hasStencil, bool hasHtile, bool htileStencilDisabled) =>
|
||||
!hasStencil || htileStencilDisabled || hasHtile;
|
||||
|
||||
// Builds the request for the bound depth target. Null when no depth or stencil state is active.
|
||||
public static DepthTargetResolution? DepthTarget(in DepthTargetWords depthWords, IImageFormatSupport device) =>
|
||||
DepthTargetCore(in depthWords, device, copyMode: false, writeBuffer: false);
|
||||
|
|
@ -128,7 +125,7 @@ public static partial class ImageRequestBuilders
|
|||
|
||||
if (hasStencil)
|
||||
{
|
||||
if (depthWords.StencilFormat != GuestStencilFormat.Stencil8UInt || !HtileStencilCompatible(hasStencil, hasHtile, depthWords.HtileStencilDisabled) ||
|
||||
if (depthWords.StencilFormat != GuestStencilFormat.Stencil8UInt ||
|
||||
stencilAddress == 0 || (!copyMode && !depthWords.StencilWriteDisabled && depthWords.StencilWriteBase != depthWords.StencilReadBase) || (stencilAddress & 0xFFFF) != 0)
|
||||
{
|
||||
throw SubmissionScheduler.Fatal(
|
||||
|
|
|
|||
Loading…
Reference in New Issue