Repository navigation
Melody, nature sounds, moon phase, seasons and low-power mode - #8
Merged
Merged
Conversation
The sky starts drawing raindrops and ground ripples at 0.05 mm/h, but the label only switched from the cloud description to LIGHT RAIN at 0.1 mm/h, so drizzle showed rain in the sky while the card said OVERCAST.
- New lead voice: a soft triangle tone that swells in, with light vibrato, a low-pass, and a dotted-eighth echo into the reverb. - Phrases come from a pure, tested generator (audio/melody.ts): 3 to 6 notes over one chord that rise then fall, mostly by step with the odd leap, starting and ending on chord tones, never repeating a note back to back, and leaving space at the end of the two bars. - A phrase is sung on some chord changes: more often when the arp is busy (you're active, or it's daytime), half as often in focus mode. Pitched around middle C in the current key, whatever octave the mix is in. Melody notes also make the stars flare. - New "Melody" mixer channel (saved mixes without it keep their levels).
- lib/moon.ts (tested against known 2024 new and full moons): phase from the mean synodic month, illumination, phase names, and an SVG path for the lit part (lit limb plus a terminator ellipse that follows the phase; waxing lit on the right, waning on the left). - The moon is drawn lit by that amount over a faint earthshine disc, and its glow scales with how much of it is lit. - On clear nights a full moon lifts the brightness a touch and a new moon darkens it; cloud and daylight remove the effect. - Studio readout shows the phase, e.g. "Waxing gibbous · 78% lit".
- audio/NatureVoices.ts, all synthesized: wind gusts (filtered noise that swells and sweeps, plus a light bed of air when it's windy), crickets (high chirps in threes, panned), birdsong (calls of 2 to 5 pitch-swept tweets), and snow shimmer (sparse high bell tones from the current chord, into the reverb). - Mapping (tested): crickets on warm, dry nights; birds around dawn and a few at dusk, fewer in rain and none in hard frost; shimmer while it snows; gusts follow wind speed. New optional params so older presets and share links still load. - A slow, wide chord swells when the sun rises (home chord) or sets (current chord) while playing, including when Simulate's hour is dragged across the horizon. - New "Nature" mixer channel; the Studio readout lists what's active.
…lier - lib/seasons.ts (tested): a smooth "winterness" curve (1 midwinter, 0 midsummer), flipped for the southern hemisphere and fading toward neutral near the equator, plus season names. - The weather location's latitude is now passed through to the client so the hemisphere is right; unknown latitude assumes northern. - Mapping: winter is a few BPM slower, a little darker, more reverberant and slightly sparser; summer the opposite. Neutral at the equinoxes. - The sky gets a faint cool tint in winter and a warm one in summer, and the Studio readout shows the season.
- Studio → Sound → Low-power visuals. Auto turns it on when the browser's data saver is on, on very weak hardware (2 cores or 2 GB or less), or on modest hardware on both counts (4 cores and 4 GB or less); a 4-core laptop with plenty of memory keeps the full visuals. Remembered. - When on: solid panels instead of backdrop blur, no drifting particles or ripples, the sky's twinkle/aurora/fog/reflection animations stop, the sky no longer reacts to the music, the immersive aurora band is skipped, and the waveform draws at about 20 fps without glow. Audio is untouched. - Detection and persistence are pure functions with tests.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Music
Sky
Fixes and settings
Older presets, share links and saved mixer levels keep working.
Testing