mirror of
https://github.com/bkaradzic/bgfx.git
synced 2026-02-17 20:52:36 +01:00
Added variable rate shading.
This commit is contained in:
@@ -1142,25 +1142,30 @@ public static class bgfx
|
||||
/// </summary>
|
||||
TransparentBackbuffer = 0x0000000004000000,
|
||||
|
||||
/// <summary>
|
||||
/// Variable Rate Shading
|
||||
/// </summary>
|
||||
VariableRateShading = 0x0000000008000000,
|
||||
|
||||
/// <summary>
|
||||
/// Vertex attribute half-float is supported.
|
||||
/// </summary>
|
||||
VertexAttribHalf = 0x0000000008000000,
|
||||
VertexAttribHalf = 0x0000000010000000,
|
||||
|
||||
/// <summary>
|
||||
/// Vertex attribute 10_10_10_2 is supported.
|
||||
/// </summary>
|
||||
VertexAttribUint10 = 0x0000000010000000,
|
||||
VertexAttribUint10 = 0x0000000020000000,
|
||||
|
||||
/// <summary>
|
||||
/// Rendering with VertexID only is supported.
|
||||
/// </summary>
|
||||
VertexId = 0x0000000020000000,
|
||||
VertexId = 0x0000000040000000,
|
||||
|
||||
/// <summary>
|
||||
/// Viewport layer is available in vertex shader.
|
||||
/// </summary>
|
||||
ViewportLayerArray = 0x0000000040000000,
|
||||
ViewportLayerArray = 0x0000000080000000,
|
||||
|
||||
/// <summary>
|
||||
/// All texture compare modes are supported.
|
||||
@@ -2006,6 +2011,20 @@ public static class bgfx
|
||||
Count
|
||||
}
|
||||
|
||||
[AllowDuplicates]
|
||||
public enum ShadingRate : uint32
|
||||
{
|
||||
Rate1x1,
|
||||
Rate1x2,
|
||||
Rate2x1,
|
||||
Rate2x2,
|
||||
Rate2x4,
|
||||
Rate4x2,
|
||||
Rate4x4,
|
||||
|
||||
Count
|
||||
}
|
||||
|
||||
[AllowDuplicates]
|
||||
public enum NativeWindowHandleType : uint32
|
||||
{
|
||||
@@ -3630,6 +3649,17 @@ public static class bgfx
|
||||
[LinkName("bgfx_set_view_order")]
|
||||
public static extern void set_view_order(ViewId _id, uint16 _num, ViewId* _order);
|
||||
|
||||
/// <summary>
|
||||
/// Set view shading rate.
|
||||
/// @attention Availability depends on: `BGFX_CAPS_VARIABLE_RATE_SHADING`.
|
||||
/// </summary>
|
||||
///
|
||||
/// <param name="_id">View id.</param>
|
||||
/// <param name="_shadingRate">Shading rate.</param>
|
||||
///
|
||||
[LinkName("bgfx_set_view_shading_rate")]
|
||||
public static extern void set_view_shading_rate(ViewId _id, ShadingRate _shadingRate);
|
||||
|
||||
/// <summary>
|
||||
/// Reset all view settings to default.
|
||||
/// </summary>
|
||||
|
||||
Reference in New Issue
Block a user