Export multiple point minimum distances from surface


#1

Have a surface and multiple points near the surface. All points have a unique name. Need a simple script to export (.csv, .txt, .xls, etc.) the point to surface distance data. At minimum the export needs to include point name and distance from the surface.

Process would be:

select and run the script
select surface(s) /enter
select point(s) /enter
input file name and location to store file /enter


(Dale Fugier) #2

Hi @Dave_Perry,

See if this gets you started.

TestDave.rvb (1.2 KB)

– Dale


#3

Primitive python code. open it in rhino python editor and run it. not much error catching but should get the job done if you provide the surface, the points, a file path and a file name.

forum - points distance to srf csv.py (634 Bytes)


(Dale Fugier) #4

Hi @Will_Wang,

Nice example - thanks for contributing.

When I hear someone wanting to measure the distance to the surface, as described above, they usually want to know the distance of points pulled back to the surface, which is not the same as the “closest point.” But we’ll let the user decide.

Thanks,

– Dale


#5

thanks for the quick response, both give results looking for.


#6

what would be an occasion where the pulled distance isn’t the shortest distance?