mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-05 02:44:02 +00:00
fix(anime): fade the Milky Way out instead of masking the sky by depth
The far-plane mask in the anime shader read the post-process depth, which cannot tell the sky from far geometry: with a layer that clamps the near plane to 0.1 m (satellites) the whole Earth lost its cel bands, keyless terrain above the ellipsoid horizon did too, and the atmosphere, Sun and Moon stopped banding. Restore the anime shader from main and fade the Milky Way glow with the style instead: VisualEffects sets skyBox.milkyWayVisibility to 1 - anime intensity. scripts/qa-anime-space-mask.mjs checks all three cases headless and that the anime sky shows no bands. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
1 parent
adeee12209
commit
e652e50d5c
6 files changed
+357
-7
No files matched your search
@@ -158,6 +158,27 @@ test('direct Cockpit intensity writes are reconciled before rendering', () => {
|
||||
f.effects.destroy();
|
||||
});
|
||||
|
||||
test('the anime stage fades the Milky Way out with its own intensity', () => {
|
||||
const f = fixture();
|
||||
const sky = { milkyWayVisibility: 1 };
|
||||
f.effects.viewer.scene.skyBox = sky;
|
||||
f.effects.initStyles();
|
||||
f.effects.setStageIntensity(f.effects.stages.thermal, 1);
|
||||
assert.equal(sky.milkyWayVisibility, 1, 'other styles keep the glow');
|
||||
f.effects.setStageIntensity(f.effects.stages.anime, 0.25);
|
||||
assert.equal(sky.milkyWayVisibility, 0.75);
|
||||
f.effects.setStageIntensity(f.effects.stages.anime, 1);
|
||||
assert.equal(sky.milkyWayVisibility, 0);
|
||||
f.effects.setStageIntensity(f.effects.stages.anime, 0);
|
||||
assert.equal(sky.milkyWayVisibility, 1);
|
||||
// A sky box without the knob (Cesium's own) is left alone.
|
||||
const plain = {};
|
||||
f.effects.viewer.scene.skyBox = plain;
|
||||
f.effects.setStageIntensity(f.effects.stages.anime, 1);
|
||||
assert.deepEqual(plain, {});
|
||||
f.effects.destroy();
|
||||
});
|
||||
|
||||
test('bloom retains its dead zone, normalized intensity and independent toggle', () => {
|
||||
const f = fixture();
|
||||
f.effects.initPostProcess();
|
||||
|
||||
Reference in new issue
Block a user