Commit 222713b
fix(editor): point compass needle at true north, not camera
The compass needle rotation was `-floorplanUserRotationDeg`, but the
2D-floorplan SVG and 3D camera projections both place true north at
`+floorplanUserRotationDeg` (= cameraAzimuth − 90°). The negated sign
made the needle rotate opposite to north as the camera orbits, so it
appeared to track the camera instead of pointing north.
The formula was written for the 2D floorplan and reused verbatim when
the compass was portaled into the 3D viewer; both instances had the
flipped sign. "Align to north" is unaffected (userRotation 0 → up).
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>1 parent 2e5a4ff commit 222713b
1 file changed
Lines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10316 | 10316 | | |
10317 | 10317 | | |
10318 | 10318 | | |
10319 | | - | |
| 10319 | + | |
10320 | 10320 | | |
10321 | 10321 | | |
10322 | 10322 | | |
10323 | 10323 | | |
10324 | 10324 | | |
10325 | 10325 | | |
10326 | | - | |
| 10326 | + | |
10327 | 10327 | | |
10328 | 10328 | | |
10329 | 10329 | | |
| |||
0 commit comments