21 lines
693 B
C#
21 lines
693 B
C#
using AcDream.App.Streaming;
|
|
using AcDream.Core.World;
|
|
|
|
namespace AcDream.App.Rendering.Scene;
|
|
|
|
/// <summary>
|
|
/// Narrow derived adapter over <see cref="GpuWorldState"/>'s canonical spatial
|
|
/// traversal. It exposes no bucket mutation or gameplay lookup to the render
|
|
/// scene.
|
|
/// </summary>
|
|
internal sealed class GpuWorldRenderTraversalOrderSource(
|
|
GpuWorldState world) : IRenderTraversalOrderSource
|
|
{
|
|
private readonly GpuWorldState _world =
|
|
world ?? throw new ArgumentNullException(nameof(world));
|
|
|
|
public bool TryGetTraversalSortKey(
|
|
WorldEntity entity,
|
|
out RenderSortKey sortKey) =>
|
|
_world.TryGetRenderTraversalSortKey(entity, out sortKey);
|
|
}
|