暂停并等待用户在一个网格上选取一个点。
rhinoscriptsyntax.GetPointOnMesh (mesh_id, message=None)
rhinoscript.userinterface.GetPointOnMesh (mesh_id, message=None)
mesh_id |
必须参数。字符串或 Guid。物件的 ID 。 |
message |
可选参数。字符串。提示信息。 |
Point3d 点 |
用户选取的 3-D 点。 |
None |
如果执行不成功或出错,返回空值。 |
import rhinoscriptsyntax as rs
mesh = rs.GetObject("Pick a mesh", rs.filter.mesh)
if mesh:
point = rs.GetPointOnMesh(mesh, "Point on mesh")
if point: rs.AddPoint( point )