generative modeling for Rhino
Tags:
Permalink Reply by Evan Chakroff on July 23, 2012 at 9:42pm Anyone have an answer for this? It would be great to be able to reference the current or named CPlanes in GH....

What do you need this for Evan? There's more than one CPlane active if you have more than one viewport and they change all the time without any event being raised to denote these changes.
--
David Rutten
david@mcneel.com
Poprad, Slovakia
Permalink Reply by Evan Chakroff on July 24, 2012 at 2:04am Just realized that... that the active CPlane changes whenever you switch views...
Basically, I was hoping to reference one of my custom Named CPlane, not the CPlane from the active viewport... (Specifically, I have a large masterplan file, several different buildings which use different base grids, but GH def I'm building is treating all buildings as part of one system... (and my working model needs to remain rotated Y-axis = north).
I did find a way to reference the *active* CPlane, after some digging through rhino.common... in a VB component:
Dim cplane As Rhino.DocObjects.ConstructionPlane =
RhinoDoc.ActiveDoc.Views.ActiveView.MainViewport.GetConstructionPlane()A = cplane.Plane
So there's the answer the Robin's 2-year-old question.... but I would still like to find a way to reference the CPlanes saved under "Named CPlanes"...
wow... almost forgot about that.
thx anyway...
By that time I was projecting "text" view based to some room corners.
I solved the problem by using control - planes instead.
robin
Permalink Reply by Andrew Heumann on July 24, 2012 at 8:03am Try this:
int CPindex = doc.NamedConstructionPlanes.Find("CPlane Name to search for");
A = doc.NamedConstructionPlanes[CPindex].Plane;
© 2013 Created by Scott Davidson.
Powered by