docs(visualizer): fix five inaccurate comments — sub-unity restitution, uniform heat boost, progressive push-out, scroll-speed cross-ref, eight-knob bar
This commit is contained in:
@@ -1426,9 +1426,9 @@ export function create(canvas: HTMLCanvasElement): MixVisualizerHandle {
|
||||
* toe) keeps the low end gentle so small dial moves near 0 don't suddenly erupt. */
|
||||
function heatScaleFromDial(dial: number): number {
|
||||
const d = Math.min(Math.max(dial, 0), 1);
|
||||
// Smoothstep toe (gentle at 0) scaled to reach 1.2 at dial 1 — Phase 10 §3.4: ~20% stronger
|
||||
// at the high end so full heat roils harder. The low/mid feel is unchanged (the toe dominates
|
||||
// there); only the top end gains the extra 20% drive into the floor-heating + buoyancy + turbulence.
|
||||
// Smoothstep toe (gentle at 0) scaled by 1.2 — Phase 10 §3.4: uniform +20% across the curve
|
||||
// (every non-zero dial position is raised by 20%; the shape of the toe is preserved but the
|
||||
// overall output is higher at every point).
|
||||
return d * d * (3 - 2 * d) * 1.2;
|
||||
}
|
||||
|
||||
@@ -1601,7 +1601,8 @@ export function create(canvas: HTMLCanvasElement): MixVisualizerHandle {
|
||||
b.vx += sideSign * WAVE_COLLIDE_SPRING * penetration * dt * (1 - collideHardness);
|
||||
|
||||
// Hard elastic reflection (hard end): bounce the inward velocity back out, scaled
|
||||
// by restitution × hardness (over-unity restitution at the top = the springy throw).
|
||||
// by restitution × hardness. Restitution is sub-unity (≤ 0.85) — bounded reflection,
|
||||
// no energy added.
|
||||
if (inwardSpeed > 0) {
|
||||
b.vx += sideSign * inwardSpeed * (1 + waveRest) * collideHardness;
|
||||
}
|
||||
@@ -1613,9 +1614,9 @@ export function create(canvas: HTMLCanvasElement): MixVisualizerHandle {
|
||||
const throwUp = Math.min(WAVE_THROW_UP * penetration * dt * collideHardness, WAVE_THROW_UP_MAX);
|
||||
b.vy -= throwUp;
|
||||
|
||||
// Positional push-out: always eject the wax fully out of the ribbon along the normal so
|
||||
// it can never lodge inside (Daniel "gets stuck"). The soft end eases it out gently
|
||||
// (mushy), the hard end snaps it clean — but both clear the boundary, so no stuck wax.
|
||||
// Positional push-out: ejects the wax progressively out of the ribbon along the normal
|
||||
// (converges across substeps, so no stuck wax). The soft end eases it out gently
|
||||
// (mushy), the hard end snaps it clean.
|
||||
b.x += sideSign * penetration * (0.5 + 0.5 * collideHardness);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user