Valid name-value pair arguments for LiDAR datatip

조회 수: 3 (최근 30일)
Kartik Javali
Kartik Javali 2021년 2월 5일
댓글: Kartik Javali 2021년 2월 5일
Hello,
As shown in this article, I would like to display Intensity, Azimuth Angle, etc., properties for each data point.
I tried the following code:
cmatrix = [1 1 0]
ptCloud = pointCloud([1.2 1.8 -1.5], 'Color', cmatrix, 'Azimuth Angle', 0.15)
this gives error message saying 'Azimuth Angle' must be a string scalar...
Can someone suggest me how to specify the name-value pair for datatips

채택된 답변

Walter Roberson
Walter Roberson 2021년 2월 5일
There are no pointCloud properties that resemble 'Azimuth Angle'.
It is not possible to add arbitrary properties to objects using name/value pairs in order to have those displayed by datatips.
It is possible to add "dynamic properties" to some kinds of objects. However, pointcloud objects do not permit dynamic properties.
Many graphic objects have a "UserData" property that can be set to arbitrary values. However, pointcloud objects do not have that property. They do not have any fields (including hidden ones) that can be set to arbitrary values.
Therefore you cannot add information directly onto pointcloud objects. You will need to instead add the information to the datatip, For example, https://www.mathworks.com/help/matlab/ref/matlab.graphics.datatip.datatiptextrow.html
cmatrix = [1 1 0];
ptCloud = pointCloud([1.2 1.8 -1.5], 'Color', cmatrix);
pcsax = pcshow(ptCloud);
pcviewer = pcsax.Children;
r = dataTipTextRow('Azimuth Angle', 0.15);
pcviewer.DataTipTemplate.DataTipRows(end+1) = r;
  댓글 수: 1
Kartik Javali
Kartik Javali 2021년 2월 5일
It works! thanks for detailed explanation, that makes sense.

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

추가 답변 (0개)

카테고리

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