From ea46af297a7c94953b3de9856b08c1695460e20a Mon Sep 17 00:00:00 2001 From: Jeffrey Alan Scudder Date: Mon, 23 Mar 2026 11:03:29 -0700 Subject: [PATCH] blank: fix reversed text, sinusoidal front-facing swivel MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Negate planeRight + origin from sTR to un-mirror text on inner face - Replace full 360 turntable with sin() swivel (~±34°), keeps screen visible Co-Authored-By: Claude Opus 4.6 (1M context) --- system/public/aesthetic.computer/disks/blank.mjs | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/system/public/aesthetic.computer/disks/blank.mjs b/system/public/aesthetic.computer/disks/blank.mjs index 96d97f8f8a..fdbefad834 100644 --- a/system/public/aesthetic.computer/disks/blank.mjs +++ b/system/public/aesthetic.computer/disks/blank.mjs @@ -117,8 +117,8 @@ function paint($) { const size = min(availW, availH); const fov = 260; - // Turntable rotation (slow steady swivel) - const ay = frame * 0.008; + // Sinusoidal front-facing swivel (stays mostly facing the viewer) + const ay = sin(frame * 0.01) * 0.6; // ±0.6 radians (~±34°) const ax = 0.3; // fixed downward tilt // Fixed open angle (~120 degrees) @@ -230,7 +230,8 @@ function paint($) { const bTL = hingeXform(bezelTL), bTR = hingeXform(bezelTR); const bBL = hingeXform(bezelBL), bBR = hingeXform(bezelBR); - const planeRight = [sTR[0] - sTL[0], sTR[1] - sTL[1], sTR[2] - sTL[2]]; + // Negate right vector — inner face mirrors x when viewed from front + const planeRight = [sTL[0] - sTR[0], sTL[1] - sTR[1], sTL[2] - sTR[2]]; const planeDown = [sBL[0] - sTL[0], sBL[1] - sTL[1], sBL[2] - sTL[2]]; // Screen-space normal check (is it facing the camera?) @@ -282,10 +283,11 @@ function paint($) { const offsetR = (planeW / glyphScale - textW) / 2; const offsetD = (planeH / glyphScale - textH) / 2; + // Origin from sTR (visual top-left when viewed from front) const textOrigin = [ - sTL[0] + offsetR * rn[0] + offsetD * dn[0], - sTL[1] + offsetR * rn[1] + offsetD * dn[1], - sTL[2] + offsetR * rn[2] + offsetD * dn[2], + sTR[0] + offsetR * rn[0] + offsetD * dn[0], + sTR[1] + offsetR * rn[1] + offsetD * dn[1], + sTR[2] + offsetR * rn[2] + offsetD * dn[2], ]; const titleColor = isDark ? [180, 220, 255] : [100, 180, 255]; -- 2.54.0