Skip to content
This repository has been archived by the owner on Apr 3, 2020. It is now read-only.

GUI: default camera if no cameras #182

Open
daose opened this issue Feb 17, 2020 · 2 comments
Open

GUI: default camera if no cameras #182

daose opened this issue Feb 17, 2020 · 2 comments
Labels
Area: User Interface Issues related to the spritec GUI
Projects

Comments

@daose
Copy link
Contributor

daose commented Feb 17, 2020

Similar to #44 this can actually be done on the GUI side

@sunjay sunjay added this to To do in Planning Feb 17, 2020
@sunjay sunjay added the Area: User Interface Issues related to the spritec GUI label Feb 17, 2020
@daose
Copy link
Contributor Author

daose commented Feb 26, 2020

From #206

Thanks for putting so much work into this Bill. To be honest, I don't think this is the way to go. It's much more intuitive to do something like what we're doing in the config right now. Setting a camera position and target position is easy to do from a 3D program whereas the position are rotation depend on a bunch of stuff including axis ordering, etc. Could you change the fields to better match the code in config? You can copy that stuff over since we're trying to keep the config separate enough to delete later.

I thought about using eye/target and would definitely prefer it, but I was having trouble figuring out how to extract that from glTF cameras (not sure if it's possible). With the current setup (can test with bigboi), the glTF cameras can be expressed as world position/rotation and tweaked immediately in the GUI.

I agree that pos/rot isn't the best UX (especially since we are not doing a game scene editor like Unity), but game developers should be familiar to this from Unity. Maybe with some camera pan and orbital rotation on the canvas itself (via mouse drags), this pos/rot would only be needed for minuscule tweaking of decimals

@sunjay
Copy link
Contributor

sunjay commented Feb 26, 2020

You can't extract that from glTF. There's a concept of a "lookat" matrix that we use in the config code to go from that info into the transformation matrix form.

I'll approve your PR for the timebeing so you can move forward, but it's something to think about.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Area: User Interface Issues related to the spritec GUI
Projects
Planning
  
To do
Development

No branches or pull requests

2 participants