Having an issue with Zoom Extents for orthographic detail view Rhinocommon C# Windows

If I call ZoomExtents in rhino on a detail with an orthographic view camera (front) it does zoom out/in to the appropriate camera position.

When I use detail.Viewport.ZoomExtents(), it returns true, but the camera does not zoom to fit the shown objects. detail.Viewport.ZoomExtents() does work when I have the camera set to Perspective instead of Front. Is there a different way to zoom extents for orthographic views?

Hi @jake1,

Can you post a sample 3dm file?


– Dale

Hi Dale, I unfortunately can’t post the .3dm.

I am pretty sure it was my mistake. Each time I would set the camera it was applying the modification to the previous detail. When I would call ZoomExtents, I think it was moving my perspective view and leaving the elevation, that I should have been modifying, untouched.

I am going back to that feature tomorrow to try to get it all working together. I will report back if zoom extents is having any issues with the orthographic view.

Right now, I have the orthographic detail disabled, so I am not sure if I have the problem resolved.

Looks like there is still an issue with detail.Viewport.ZoomExtents(). I just added back in the elevation details to check real quick.

I will try to setup an example.3dm and get a clean code snippet in the morning to post.