Skip to content

Fix editor focus for scaled targets#854

Merged
dmarcos merged 1 commit into
aframevr:masterfrom
vincentfretin:fix-focus
Apr 20, 2026
Merged

Fix editor focus for scaled targets#854
dmarcos merged 1 commit into
aframevr:masterfrom
vincentfretin:fix-focus

Conversation

@vincentfretin

Copy link
Copy Markdown
Contributor

EditorControls.focus used target.localToWorld to place the camera, which multiplied the world-space bbox-derived offset by the target's world scale. Focusing a model scaled by N ended up N times too far. Decompose matrixWorld instead and rotate the offset by the target's world rotation only.

EditorControls.focus used target.localToWorld to place the camera,
which multiplied the world-space bbox-derived offset by the target's
world scale. Focusing a model scaled by N ended up N times too far.
Decompose matrixWorld instead and rotate the offset by the target's
world rotation only.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@dmarcos

dmarcos commented Apr 20, 2026

Copy link
Copy Markdown
Member

thank you!

@dmarcos
dmarcos merged commit f1e13f2 into aframevr:master Apr 20, 2026
1 check passed
@vincentfretin
vincentfretin deleted the fix-focus branch April 21, 2026 07:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants