-
Notifications
You must be signed in to change notification settings - Fork 43
Description
I can write a ply file of points by passing an array to the pipeline object:
import pdal
xyz = np.array([(0.0, 0.0, 0.0), (1.0, 0.0, 0.0),(1.0, 2.0, 0.0),(4.0, 1.0, 0.0)], dtype=[('X', '<f8'), ('Y', '<f8'), ('Z', '<f8')])
abc = np.array([(0, 1, 2), (2, 1, 3)], dtype=[('A', '<u4'), ('B', '<u4'), ('C', '<u4')])
pipeline = pdal.Writer.ply(filename="myply.ply", faces=True).pipeline(xyz)
pipeline.execute()
Is there anyway to pass an array of faces too (abc in my snippet above)?
Looking in Pipeline.__init__ there is only a spot for arrays.
Line 37 in 32328ac
| def __init__( |
Basically I'm reading a point cloud file, making a mesh (using poisson), removing some triangles and points from the mesh (this part not in pdal), and writing the resulting points from the mesh. After the mesh stage I also tried deleting rows from pipeline.meshes and pipeline.arrays but I believe they are read only. I tried using filters.crop on the meshed pointcloud - while points are deleted the entire mesh is destroyed. Is there anyway to pass meshes to filters along with arrays? and is it possible for crop etc filters to also crop the mesh?