How to create point cloud with colour

조회 수: 13 (최근 30일)
Ryan
Ryan 2014년 3월 7일
댓글: Anirban Roy 2015년 8월 28일
Hello,
I am trying to export a pointcloud as a .ply or .wrl to view in another program such as Meshlab. I have two arrays of equal size (vertices and colors(RGB)) . I can create a mesh using the vertices array, but when viewing the pointcloud it is monochrome. So, my question is how do I add the colour values to the vertices, to end up with a color appropriate pointcloud? I've looked into texture mapping, but I have not been successful with the surf and mesh functions. Any help is appreciated.
  댓글 수: 1
Anirban Roy
Anirban Roy 2015년 8월 28일
Try
1. " pointCloud": This makes a point cloud from 3D points and texture
ptCloud = pointCloud(xyzPoints, 'Color', alignedColorImage); % 3D colored point cloud
Then use
2. " pcwrite": This exports the point cloud as a PLY file with color informatoion
pcwrite(ptCloud,'Ply_file_name','PLYFormat','binary'); % Convert to .PLY format
Hope this helps
Anirban

댓글을 달려면 로그인하십시오.

답변 (1개)

Walter Roberson
Walter Roberson 2014년 3월 7일
patch() allows you to assign vertex color.
Or, more directly, scatter3(x, y, z, pointsize, color)
  댓글 수: 2
Ryan
Ryan 2014년 3월 7일
Walter, thanks for the quick reply, I ended up using fscatter3 to add colour to the pointcloud, the values get saved as a 1x256 matrix. But now, how can I export it as a .wrl, .ply, or even .stl for use in another program?
Alvaro
Alvaro 2014년 9월 16일
Hi Ryan, do you find a way to export as ply/wrl the colored mesh ? VBR

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Point Cloud Processing에 대해 자세히 알아보기

태그

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by