From 6f5454e8dd79083772671e91f4b1a3204aa031ec Mon Sep 17 00:00:00 2001 From: "prompt.ac/@jeffrey" Date: Fri, 24 Apr 2026 13:38:34 -0700 Subject: [PATCH] cap: portrait-native camera stream + drawn mic glyph + outlined button MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - bios: stop swapping getUserMedia width/height to force a landscape request on mobile portrait. Modern iOS Safari and Android Chrome already auto-rotate the stream to match device orientation; forcing landscape was what made iPhone caps record sideways (90° right). The process() rotation fallback stays, with the rotation direction now picked per facing mode so desktop/front webcams and Android rear cams both land upright if the browser ever hands us raw landscape pixels. - cap: replace the 🎤 / ⏳ / ✓ emoji row in the top-left with a small drawn mic glyph and pixel status indicator. The default typeface has no emoji glyphs, so those characters were rendering as "??". - cap-ui: CaptureButton gets a two-tone outline (dark rim + crisp white ring) and a subtle highlight inside the red fill for a cleaner button look. --- system/public/aesthetic.computer/bios.mjs | 63 ++++++++++++------- .../public/aesthetic.computer/disks/cap.mjs | 34 ++++++++-- .../disks/common/cap-ui.mjs | 22 ++++--- 3 files changed, 82 insertions(+), 37 deletions(-) diff --git a/system/public/aesthetic.computer/bios.mjs b/system/public/aesthetic.computer/bios.mjs index 9f1ddc5658..ba809e6c69 100644 --- a/system/public/aesthetic.computer/bios.mjs +++ b/system/public/aesthetic.computer/bios.mjs @@ -19862,7 +19862,7 @@ async function boot(parsed, bpm = 60, resolution, debug) { async function getDevice(facingModeChoice) { // Use local copies so we don't mutate the outer cWidth/cHeight // across repeated calls (camera swap, resize, etc.). - let reqWidth = cWidth, + const reqWidth = cWidth, reqHeight = cHeight; const constraints = { @@ -19870,25 +19870,16 @@ async function boot(parsed, bpm = 60, resolution, debug) { frameRate: { ideal: 30 }, }; - // Swap width/height on mobile in portrait — camera sensors are - // natively landscape, so request landscape constraints. - if ( - (iOS || Android) && - window.matchMedia("(orientation: portrait)").matches && - (facingModeChoice === "environment" || facingModeChoice === "user") - ) { - const temp = reqWidth; - reqWidth = reqHeight; - reqHeight = temp; - } - - // Calculate target aspect ratio AFTER the swap so it matches - // the width/height we actually request. - const targetAR = reqWidth / reqHeight; - + // Ask for what we actually want. On mobile portrait, iOS Safari + // and modern Android Chrome already present the stream oriented + // to match the device (auto-rotated for the