Error occurred while reading file header. See the pcread reference page in documentation for correct header format.
出错 pcread (第 99 行)
properties = visionPcdRead(filename,requiredProperties,optionalProperties);
可能是Matlab版本低了,换2018或2019b(编码格式变为utf-8了)以上的高版本,文件名里的中文(最好也不要带空格,有时候会出问题)去了试试,
或者去MATLAB社区里使用pointCloud()创建pcd文件,尝试用此函数:
pt=loadpcd('test1.pcd');
ptCloud=pointCloud(pt');
pcwrite(ptCloud,'test1.ply');%格式转换
PCD文件
VERSION 0.7
FIELDS x y z X Y Z intensity echo
SIZE 4 4 4 8 8 8 4 4
TYPE F F F F F F U U
COUNT 1 1 1 1 1 1 1 1
WIDTH 13386
HEIGHT 1
VIEWPOINT 0 0 0 1 0 0 0
POINTS 13386
DATA ascii
34.55846405 11.80257893 2.91749454 34.55846347 11.80257896 2.91749457 125 1
34.63780975 11.90638733 2.92516303 34.63780987 11.90638753 2.92516300 113 1
34.57014084 11.96068287 2.92044950 34.57014074 11.96068250 2.92044945 105 1
34.59886551 12.04765892 2.92382574 34.59886604 12.04765873 2.92382582 78 1
34.99071884 12.25979710 2.95787001 34.99071944 12.25979689 2.95787008 53 1
26.74266052 -0.35017836 2.18349767 26.74265974 -0.35017837 2.18349758 126 1
27.14208412 -0.30586454 2.21681023 27.14208323 -0.30586454 2.21681034 136 1