using System; using System.Collections.Generic; using GameCult.Caching; using MessagePack; #nullable enable namespace GameCult.Aetheria.State.Verse { public static class AetheriaRuntimeRenderSplatChannels { public const int Visibility = 0; public const int Gravity = 1; public const int GravityWave = 2; public const int Influence = 3; public const int Tint = 4; } public static class AetheriaRuntimeRenderSplatLayerKeys { public const string GravityHeight = "gravity.height"; public const string GravityWave = "gravity.wave"; public const string Visibility = "visibility.mask"; public const string FogSurfaceHeight = "fog.surface_height"; public const string FogPatchHeight = "fog.patch_height"; public const string FogPatch = "fog.patch"; public const string FogTint = "fog.tint"; public const string Influence = "influence.mask"; } public static class AetheriaRuntimeRenderSplatBlendModes { public const string Add = "add"; public const string Max = "max"; public const string Alpha = "alpha"; } public static class AetheriaRuntimeRenderSplatSourceKinds { public const int Constant = 0; public const int SimplexNoise = 1; public const int AnimatedSimplexNoise = 2; } public static class AetheriaRuntimeRenderSplatFalloffs { public const int Solid = 0; public const int Linear = 1; public const int Smooth = 2; public const int InverseSmooth = 3; } [CultDocument("gamecult.aetheria.render_splats_viewport", "gamecult.aetheria.render_splats_viewport.v1")] [MessagePackObject] public sealed class AetheriaRuntimeRenderSplatsViewportDocument { [Key(0)] public string Schema { get; set; } = AetheriaRuntimeDaemonSchemas.RenderSplatsViewport; [Key(1)] public long FrameId { get; set; } [Key(2)] public string PublishedAtUtc { get; set; } = ""; [Key(3)] public double SimulationTimeSeconds { get; set; } [Key(4)] public string RunId { get; set; } = ""; [Key(5)] public int ZoneIndex { get; set; } [Key(6)] public string ZoneName { get; set; } = ""; [Key(7)] public AetheriaRuntimeViewportBounds Viewport { get; set; } = new AetheriaRuntimeViewportBounds(); [Key(8)] public IReadOnlyList Layers { get; set; } = Array.Empty(); [Key(9)] public AetheriaRuntimeRenderSplatSoa Splats { get; set; } = new AetheriaRuntimeRenderSplatSoa(); } [MessagePackObject] public sealed class AetheriaRuntimeRenderSplatLayerDefinition { [Key(0)] public string LayerKey { get; set; } = ""; [Key(1)] public string DisplayName { get; set; } = ""; [Key(2)] public int Channel { get; set; } [Key(3)] public string BlendMode { get; set; } = AetheriaRuntimeRenderSplatBlendModes.Add; [Key(4)] public string GraphicsFormat { get; set; } = "R16_SFloat"; [Key(5)] public bool ClearBeforeDraw { get; set; } = true; [Key(6)] public double ClearR { get; set; } [Key(7)] public double ClearG { get; set; } [Key(8)] public double ClearB { get; set; } [Key(9)] public double ClearA { get; set; } } [MessagePackObject] public sealed class AetheriaRuntimeRenderSplatSoa { [Key(0)] public int Count { get; set; } [Key(1)] public IReadOnlyList CenterX { get; set; } = Array.Empty(); [Key(2)] public IReadOnlyList CenterY { get; set; } = Array.Empty(); [Key(3)] public IReadOnlyList HalfExtentX { get; set; } = Array.Empty(); [Key(4)] public IReadOnlyList HalfExtentY { get; set; } = Array.Empty(); [Key(5)] public IReadOnlyList RotationCos { get; set; } = Array.Empty(); [Key(6)] public IReadOnlyList RotationSin { get; set; } = Array.Empty(); [Key(7)] public IReadOnlyList Channel { get; set; } = Array.Empty(); [Key(8)] public IReadOnlyList Falloff { get; set; } = Array.Empty(); [Key(9)] public IReadOnlyList ValueR { get; set; } = Array.Empty(); [Key(10)] public IReadOnlyList ValueG { get; set; } = Array.Empty(); [Key(11)] public IReadOnlyList ValueB { get; set; } = Array.Empty(); [Key(12)] public IReadOnlyList ValueA { get; set; } = Array.Empty(); [Key(13)] public IReadOnlyList SourceKey { get; set; } = Array.Empty(); [Key(14)] public IReadOnlyList LayerIndex { get; set; } = Array.Empty(); [Key(15)] public IReadOnlyList SourceKind { get; set; } = Array.Empty(); [Key(16)] public IReadOnlyList FrequencyX { get; set; } = Array.Empty(); [Key(17)] public IReadOnlyList FrequencyY { get; set; } = Array.Empty(); [Key(18)] public IReadOnlyList PhaseX { get; set; } = Array.Empty(); [Key(19)] public IReadOnlyList PhaseY { get; set; } = Array.Empty(); [Key(20)] public IReadOnlyList AnimationSpeed { get; set; } = Array.Empty(); [Key(21)] public IReadOnlyList SourceFlags { get; set; } = Array.Empty(); } }