Extracting point cloud from patch model
显示 更早的评论
Hi everyone, So I have a model I created using patch function and I need a point cloud of said model to play around with the depth information, so I was wondering if it is possible or not to extract a point cloud from a model and if yes how would I go about on doing so?
7 个评论
KSSV
2017-6-6
More details needed.....show us your model and what you expecting.
Walter Roberson
2017-6-6
If you are expecting that each of the cuboids would become a whole bunch of points inside the volume of the cuboid, then you would need to do interpolation of some sort, or volume rendering.
KSSV
2017-6-6
Is this model created in matlab?
Walter Roberson
2017-6-7
The patch object does not store the surface points, only the vertices.
KSSV
2017-6-8
If you have the vertices in hand..you can create the surface using meshgrid.
回答(1 个)
Walter Roberson
2017-6-6
0 个投票
There are two ways of constructing patch objects.
- For one of them, you can fetch the XData, YData, and ZData properties. Each column represents a face, so there are as many rows as the longest face; shorter faces have NaN to pad them out
- For the other, more efficient one, you can fetch the Vertices property to get a matrix in which each row defines a unique point. The Faces property gives information about how the vertices are connected.
类别
在 帮助中心 和 File Exchange 中查找有关 Polygons 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
