Autodesk Design Review
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic to the Top
- Bookmark
- Subscribe
- Printer Friendly Page
Programati cally move the camera to selected object?
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
I am able to programatically select 3D objects via the javascript API (see my previous post). I would now like to programatically move the camera such that the selected object is centred in the camera.
I have been able to do this with 2D objects by getting the objects Extents then setting the Section view. But this approach is not applicable with 3D.
Any help appreciated.
Cheers
Re: Programati cally move the camera to selected object?
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
The reply to the following post seems to suggest that programatically moving the camera to the selected object is possible:
http://forums.autodesk.com/t5/Autodesk-Design-Revi
The extents property has Front and Back properties in addition to Left, Right, Top, Bottom.
But the Camera position has X,Y,Z co-ordinates...
So how do you use the extents to set the camera position?
Re: Programati cally move the camera to selected object?
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
Another tantalizing post:
For 3D bojects:
2. Define your specify EModelCamera object base on the boundaries (IAdCube).
3. Set you specify 3D view to render objects via EModelSection.Camera property.
How do you "specifyEModelCamera object base on the boundaries" in Javascript?

