Grasshopper

algorithmic modeling for Rhino

hey,

how can i define a plane by x,y AND z axis? otherwise the z axis will show either up or down following probably the left handed coordinate system... but as i need mirrored coordinate systems (both right and left handed) with a predefinded z axis (which is existent already) a command to define all three axis would be very helpful. maybe i miss some command or logic?

thx!

Views: 3343

Replies to This Discussion

You can't define the z-axis of a plane on creation because Rhino itself does not allow for this. The z axis is automatically created from the cross product of the x and y vectors and reverses that vector (if needed) to create a right handed coordinate system as Rhino always wants to thing of planes as right handed.

The best you can do is manually flip the z vector of the plane within a scripting component. However, it seams as though Rhino does not like this. The attached definition has that scripting component and feeds that into a change basis transformation. With the default YZ plane GH seams to reorient the supplied point (representing the z direction) fine, however, with the "reversed" plane the change basis component seams to choke. I tried this with a more arbitrary plane, and the results were the same.
Attachments:
thx. anyways it wasnt that difficult to reverse the z vector of the planes. i explode the vector and cull the z vectors smaller than 0 which would work if there was some plane reparametrization - making it a 0,0,1 or 0,0,-1 in any case (like UCS) - which i would think a nice addition to gh anyways. if i go that way the problem is only the selection of the 'right' planes which i cant achieve at this point for the planes can take any position and the 'right' and 'wrong' z vectors will be positive and negative. i would have all perpendicular components in every part of the system to get the correct orientation in the first place so i hoped for a more direct way.

RSS

About

Translate

Search

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service