Implement new D3D12 state & state setting commands

This commit is contained in:
baldurk
2023-04-19 18:39:03 +01:00
parent 28dcc80892
commit 7de3fb54ee
20 changed files with 958 additions and 331 deletions
+3 -7
View File
@@ -683,7 +683,7 @@ struct RasterizerState
)");
bool frontCCW = false;
DOCUMENT("The fixed depth bias value to apply to z-values.");
int32_t depthBias = 0;
float depthBias = 0.0f;
DOCUMENT(R"(The clamp value for calculated depth bias from :data:`depthBias` and
:data:`slopeScaledDepthBias`
)");
@@ -692,12 +692,8 @@ struct RasterizerState
float slopeScaledDepthBias = 0.0f;
DOCUMENT("``True`` if pixels outside of the near and far depth planes should be clipped.");
bool depthClip = false;
DOCUMENT("``True`` if the quadrilateral MSAA algorithm should be used on MSAA targets.");
bool multisampleEnable = false;
DOCUMENT(
"``True`` if lines should be anti-aliased. Ignored if :data:`multisampleEnable` is "
"``False``.");
bool antialiasedLines = false;
DOCUMENT("The line rasterization mode.");
LineRaster lineRasterMode = LineRaster::Default;
DOCUMENT(R"(A sample count to force rasterization to when UAV rendering or rasterizing, or 0 to
not force any sample count.
)");
+1
View File
@@ -359,6 +359,7 @@ rdcstr DoStringise(const LineRaster &el)
STRINGISE_ENUM_CLASS(Rectangular);
STRINGISE_ENUM_CLASS(Bresenham);
STRINGISE_ENUM_CLASS(RectangularSmooth);
STRINGISE_ENUM_CLASS(RectangularD3D);
}
END_ENUM_STRINGISE();
}
+8 -1
View File
@@ -2999,7 +2999,13 @@ DOCUMENT(R"(The line rasterization mode.
.. data:: RectangularSmooth
Lines are rasterized as rectangles extruded from the line with coverage falloff.
Lines are rasterized as rectangles extruded from the line with coverage falloff being
implementation independent.
.. data:: RectangularD3D
Lines are rasterized as rectangles extruded from the line, but with a width of 1.4 according to
legacy D3D behaviour
)");
enum class LineRaster : uint32_t
{
@@ -3007,6 +3013,7 @@ enum class LineRaster : uint32_t
Rectangular,
Bresenham,
RectangularSmooth,
RectangularD3D,
};
DECLARE_REFLECTION_ENUM(LineRaster);