Add built-in blackbody ramp resource

This commit is contained in:
Meta Vens 2026-05-28 14:26:19 +01:00
commit ea127ec1ae
4 changed files with 26 additions and 0 deletions

View file

@ -0,0 +1,21 @@
namespace Aquarium.Engine.Render;
public static class AquariumBuiltInFieldResources
{
public const string BlackbodyRampResourceKey = "aquarium:resource:ramp:blackbody";
public const string BlackbodyRampRelativePath = "Assets/Textures/Gradients/blackbody.png";
public static string ResolveBlackbodyRampPath(string? baseDirectory = null) =>
System.IO.Path.Combine(
baseDirectory ?? System.AppContext.BaseDirectory,
"Assets",
"Textures",
"Gradients",
"blackbody.png");
public static AquariumFieldResourceDeclaration BlackbodyRamp(ulong version = 1, string? baseDirectory = null) =>
AquariumFieldResourceDeclaration.LocalTexture2D(
BlackbodyRampResourceKey,
ResolveBlackbodyRampPath(baseDirectory),
version: version);
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

View file

@ -267,3 +267,4 @@
{"lesson":"AquariumAudioDocument now carries profile-keyed AquariumStreamingAudioBlock input lanes. AquariumStreamingDspHost maps declared channel indices into the persistent Faust DSP input array, processes the block, and AquariumSynthHost can optionally monitor selected output lanes. Aquarium.Engine.Tests proves declared input blocks are processed through a controlled streaming Faust graph. This closes the samples-enter-DSP seam; durable stem routing/publication remains separate.","timestamp":"2026-05-27T20:18:14+01:00","files":["src/Aquarium.Engine.Contracts/Audio/AquariumAudio.cs","src/Aquarium.Engine/Audio/AquariumStreamingDspHost.cs","src/Aquarium.Engine/Audio/AquariumSynthHost.cs","tests/Aquarium.Engine.Tests/SynthPlaybackTests.cs","state/map.yaml"],"source":"streaming DSP input block contract","topic":"streaming-audio-blocks"}
{"lesson":"Processed streaming Faust DSP output lanes now become named AquariumAudioStemFrame records published through an engine-owned IAquariumAudioStemBus exposed by AquariumRuntimeServices. Streaming DSP programs may declare output stems; otherwise outputs receive deterministic outputN names. AquariumSynthHost publishes stem frames after processing and keeps optional monitor playback explicit. OBS-facing publication remains a separate host cut. Fensalir build, Aquarium.Engine.Tests, Mimir build, and Mimir --audio-actuator-bank-smoke passed.","timestamp":"2026-05-27T20:28:37+01:00","files":["src/Aquarium.Engine.Contracts/Audio/AquariumAudio.cs","src/Aquarium.Engine.Contracts/AquariumRuntimeServices.cs","src/Aquarium.Engine/Audio/AquariumAudioStemBus.cs","src/Aquarium.Engine/Audio/AquariumStreamingDspHost.cs","src/Aquarium.Engine/Audio/AquariumSynthHost.cs","src/Aquarium.Engine/AquariumHost.cs","tests/Aquarium.Engine.Tests/SynthPlaybackTests.cs","state/map.yaml"],"source":"streaming DSP stem publication cut","topic":"streaming-audio-stem-bus"}
{"lesson":"The named D3D12 program-output texture is an external publication surface, so Fensalir must not leave it in CopyDest after publishing. D3D12Renderer now transitions the shared program texture back to Common after copying the completed backbuffer, letting OBS/EVE/native readers transition it for GPU-side reads without inheriting stale internal producer state. Fensalir build passed; Mimir's Eve relay reader now transitions the shared texture Common -> CopySource -> Common before readback.","timestamp":"2026-05-27T21:25:38+01:00","files":["src/Aquarium.Engine/Render/D3D12Renderer.cs","state/map.yaml"],"source":"OBS direct program texture source cut","topic":"program-output-shared-texture-state"}
{"lesson":"Fensalir now owns the reusable blackbody ramp as a built-in local Texture2D field resource. The asset lives at Assets/Textures/Gradients/blackbody.png, is copied with engine texture assets, and AquariumBuiltInFieldResources exposes the stable resource key/path/declaration for clients so client render DSL does not depend on project-local absolute asset paths.","timestamp":"2026-05-28T00:00:00+01:00","files":["src/Aquarium.Engine.Contracts/Render/AquariumBuiltInFieldResources.cs","src/Aquarium.Engine/Assets/Textures/Gradients/blackbody.png","state/evidence.jsonl"],"source":"Mimir spectrum dashboard ramp promotion","topic":"built-in-blackbody-ramp-resource"}

View file

@ -15,6 +15,7 @@ current_model:
renderer: src/Aquarium.Engine/Render
shaders: src/Aquarium.Engine/Render/Shaders
assets: src/Aquarium.Engine/Assets
built_in_field_resources: src/Aquarium.Engine.Contracts/Render/AquariumBuiltInFieldResources.cs
scripts: scripts
fractal:
implementation: src/Aquarium.Engine.Fractal
@ -40,6 +41,9 @@ invariants:
Treating a pass as "just drawing pixels" violates the engine invariant
unless it is explicitly marked as a fallback/debug draw with no authority.
- Client repos own policy, role names, narrative semantics, app state, and client shaders.
- Fensalir may own reusable built-in field resources, such as the blackbody
ramp, when the resource is generic engine utility. Clients should reference
those through contracts instead of hardcoded project-local asset paths.
- Epiphany Aquarium depends on Fensalir; Fensalir must not depend on Epiphany.
- Demo projects inside this repo are allowed to exercise engine features but must not become hidden engine policy.
- Public `Aquarium.*` assembly names remain for continuity until a deliberate namespace/package migration.