I have 3d points in file.I read them :
def points_to_array(pathIn):
pointArray = []
point = []
in_file = open(pathIn, 'r')
for line in in_file.readlines():
split_line = line.strip('\n').split(' ')
for i in range(0, 3):
point.append(float(split_line[i]))
pointArray.append(point)
point = []
return pointArray
And display them this way
import pyvista as pv
plotter = pv.Plotter(window_size=(1600, 1100))
points = points_to_array("C:\points.txt")
npPointArray = np.array(points)
plotter.add_points(npPointArray, color = 'r')
I want to add a line between some points (i.e from point to point as they appear in the file) Can I do this? how?