Fix slow random walk in Random8 Perlin/FBM styles#69
Open
quasor wants to merge 1 commit into
Open
Conversation
The Perlin and FBM walk styles advance a phase counter (positionX) by one step per trigger and sample 1D Perlin noise at the normalized position. The 16-bit VCV port mechanically replaced TWELVE_BIT_MAX with SIXTEEN_BIT_MAX throughout these cores. That is correct for the output scaling, but it also widened the phase period/normalization from 4095 to 65535. Since the counter still increments by one per trigger, each step through the noise lattice shrank ~16x, so the output barely changed between triggers. Restore the phase resolution to the hardware 12-bit range (TWELVE_BIT_MAX) while keeping the 16-bit output scaling, so the walk advances at the intended rate. Measured average per-trigger movement rises from ~370/65535 to ~6677/65535 while remaining smooth and correlated. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01XhmS8keJMsemMnAnASu1Gg
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.
The Perlin and FBM walk styles advance a phase counter (positionX) by one step per trigger and sample 1D Perlin noise at the normalized position. The 16-bit VCV port mechanically replaced TWELVE_BIT_MAX with SIXTEEN_BIT_MAX throughout these cores. That is correct for the output scaling, but it also widened the phase period/normalization from 4095 to 65535. Since the counter still increments by one per trigger, each step through the noise lattice shrank ~16x, so the output barely changed between triggers.
Restore the phase resolution to the hardware 12-bit range (TWELVE_BIT_MAX) while keeping the 16-bit output scaling, so the walk advances at the intended rate. Measured average per-trigger movement rises from ~370/65535 to ~6677/65535 while remaining smooth and correlated.
Claude-Session: https://claude.ai/code/session_01XhmS8keJMsemMnAnASu1Gg