triplex icon indicating copy to clipboard operation
triplex copied to clipboard

camera position prop bug and rotation desync

Open mommysgoodpuppy opened this issue 9 months ago • 2 comments

reproduction:

  • adding a perspective camera from drei, its position props wont show up until reopening triplex view
  • onload/reloading view, camera rotation is not respected/loaded correctly. until -> switch to editor view -> then tweak rotation prop, camera snaps to what it should be

mommysgoodpuppy avatar Mar 21 '25 12:03 mommysgoodpuppy

First one sounds similar to: https://github.com/trytriplex/triplex/issues/298

For the second one can you make a video showing what you mean?

itsdouges avatar Mar 21 '25 22:03 itsdouges

first one didnt seem to reproduce today.

second one still happens but not the exact same. now on reload, camera pose is correct but when switching to editor view it happens again https://github.com/user-attachments/assets/d0ad2943-a8a5-4010-94cb-3a3fa67e809b

mommysgoodpuppy avatar Mar 24 '25 15:03 mommysgoodpuppy

Is there a consistent way to reproduce this? Would love steps. And also to confirm this is a bug in Triplex not R3F.

itsdouges avatar Jul 23 '25 23:07 itsdouges

I can replicate this, will put up a fix.

TODO

  • [x] switching from default -> editor camera seems to bleed some state into the default camera (hence needing a reset to fix it)
  • [x] switching to editor camera doesn't seem to "fit to camera" correctly
  • [x] outline shouldn't appear in preview
  • [x] resetting reverts back to the default camera (even if you selected the editor camera)

itsdouges avatar Aug 04 '25 23:08 itsdouges