OSMBuildings
OSMBuildings copied to clipboard
Rotation Point
Hello,
Thank you for open sourcing such excellent software! I have a few questions:
-
Is it possible to set the altitude of the camera? If the answer is no, can you please suggest how one might go about implementing this type of functionality? I imagine it might have something to do wtih
this.viewMatrix
: https://github.com/OSMBuildings/OSMBuildings/blob/55e22a6d09911550225625d1c87a87bf8260f6b9/src/view/index.js#L150 It looks likeGLX.Matrix
implementstranslateTo()
which takes az
parameter: https://github.com/OSMBuildings/OSMBuildings/blob/55e22a6d09911550225625d1c87a87bf8260f6b9/src/glx/Matrix.js#L81 Am I on the right track? -
Is it possible to set the rotation point of the camera somewhere other than the target point? I imagine one way to implement this might involve translating the target point to the rotation point, rotating, and then translating back. Is it possible to execute these operations without redrawing? If not, I imagine
View.renderFrame()
might be the right place to start implementing this: https://github.com/OSMBuildings/OSMBuildings/blob/55e22a6d09911550225625d1c87a87bf8260f6b9/src/view/index.js#L50
Any suggestions would be appreciated!
I'm looking for this too.