(Python) Script to draw camera object as closed brep

Is there some script that draws Rhino’s camera object as closed brep? (The 4 triangles and the single rectangle joined)

@MarcusStrube,

Note that you might have to add some checks to the example below.

If the camera or its lens length is getting very small, the brep may get invalid depending on the tolerances.

CameraToBrep.py (1.4 KB)

c.

2 Likes

Great script Clement!

1 Like

Thank you @djordje, i am not even sure if this is the most efficient way to do it :wink:

c.

1 Like

Moving CameraFrame to CameraTarget and intersecting lines from CameraLocation to FarRect’s points with that frame might be more efficient.

But your way is absolutely :muscle:. Thank you, Clement!