From c6143d7d13bd7e187966c49c3e4bc7759fed0049 Mon Sep 17 00:00:00 2001 From: oimwiodev Date: Sat, 16 May 2026 18:52:38 +0100 Subject: [PATCH] Tune 3D model responsive scale --- components/GlassesModelSection.tsx | 3 +++ 1 file changed, 3 insertions(+) diff --git a/components/GlassesModelSection.tsx b/components/GlassesModelSection.tsx index d1b3f6f..7973854 100644 --- a/components/GlassesModelSection.tsx +++ b/components/GlassesModelSection.tsx @@ -43,8 +43,11 @@ export default function GlassesModelSection({ t }: { t: Messages }) { const resize = () => { const { width, height } = wrap.getBoundingClientRect(); const pixelRatio = Math.min(window.devicePixelRatio || 1, 1.7); + const scale = width < 640 ? 0.5 : width < 1024 ? 0.68 : 0.9; renderer.setPixelRatio(pixelRatio); renderer.setSize(width, height, false); + group.scale.setScalar(scale); + group.position.y = width < 640 ? -0.44 : -0.34; camera.aspect = width / Math.max(height, 1); camera.updateProjectionMatrix(); };