Files
XCEngine/managed/XCEngine.ScriptCore/Rendering/Core/DirectionalShadowExecutionContext.cs

49 lines
1.6 KiB
C#

namespace XCEngine.Rendering
{
// SRP v1 shadow hook only configures whether the native main directional
// shadow execution should run. It does not expose a custom managed shadow
// graph or scene backend.
public sealed class DirectionalShadowExecutionContext
{
private readonly ulong m_nativeHandle;
internal DirectionalShadowExecutionContext(
ulong nativeHandle)
{
m_nativeHandle = nativeHandle;
}
public bool hasPlannedMainDirectionalShadow =>
InternalCalls
.Rendering_DirectionalShadowExecutionContext_GetHasPlannedMainDirectionalShadow(
m_nativeHandle);
public int rendererIndex =>
InternalCalls
.Rendering_DirectionalShadowExecutionContext_GetRendererIndex(
m_nativeHandle);
public bool isConfigured =>
InternalCalls
.Rendering_DirectionalShadowExecutionContext_GetIsConfigured(
m_nativeHandle);
public bool UseDefaultMainDirectionalShadowExecution()
{
return InternalCalls
.Rendering_DirectionalShadowExecutionContext_UseDefaultMainDirectionalShadowExecution(
m_nativeHandle);
}
public void ClearDirectionalShadowExecution()
{
InternalCalls
.Rendering_DirectionalShadowExecutionContext_ClearDirectionalShadowExecution(
m_nativeHandle);
}
internal ulong nativeHandle =>
m_nativeHandle;
}
}