Returns or modifies the location of all grips owned by an object. The locations of the grips are returned in an array of 3-D points with each position in the array corresponding to that grip's index. To modify the locations of grips, you must provide an array of 3-D points that contains the same number of points at grips.
rhinoscriptsyntax.ObjectGripLocations (object_id, points=None)
rhinoscript.grips.ObjectGripLocations (object_id, points=None)
object_id |
Required. String or Guid. The identifier of the object. |
points |
Optional. List . A list of 3-D points identifying the new locations of the grips. |
List |
If points is not specified, the current location of all grips if successful. |
List |
If points is specified, the previous location of all grips if successful. |
None |
If not successful, or on error. |
import rhinoscriptsyntax as rs
obj = rs.GetObject("Select curve", rs.filter.curve)
if obj:
rs.EnableObjectGrips( obj )
points = rs.ObjectGripLocations(obj)
for point in points: print point