Active_view.camera.get_center2d & .get_scale2d
-
I can read center2d and scale2d of a page camera through C++ SDK.
Is there any chance I could get those values for active_view.camera?
The active camera in C++ SDK is not being updated when SU view is modified (inside SketchUp).If it is not possible, then I kindly request this feature in Ruby API.
Reading camera.field_of_view_is_height would be also good to have. -
Can't you just use:
Sketchup.active_model.active_view.vpwidthand.vheightto get the model window's pixel size, then take half of those to get the center point relative to top-left corner of the window ? -
get_center2d() and get_scale2d() C++ SDK functions return a camera shift and zoom-in factor for 2p perspective camera.
You reply gave me idea, that maybe I could calculate the shift/zoom using InputPoint.position... This may work.
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better đź’—
Register LoginAdvertisement