点群の高さデータによって、グリットシートの1マスごとに色を付ける方法がわかりません。2000*1800のグリッドシートとXYZ座標のある点群データがあります。(色を付ける際に、一マスに二点以上存在する場合一番高い点を対象としたいです。色の配分は適当でかまいません。)添付した画像のグリットシートは200*180です。
Afficher commentaires plus anciens

clear;
load('sample.mat')
xsize=200
ysize=180
Xsize = xsize*10;
Ysize = ysize*10;
line = [1:Xsize];
code = [1:Ysize];
[X,Y] = meshgrid(line,code);
[X1,X2] = ndgrid(line,code);
figure()
[X1_ndgrid,X2_ndgrid] = ndgrid(1:Xsize,1:Ysize);
Z = zeros(Xsize,Ysize);
mesh(X1_ndgrid,X2_ndgrid,Z,'EdgeColor','black')
axis equal;
% Set the axis labeling and title
h1 = gca;
h1.XTick = [1:Xsize];
h1.YTick = [1:Ysize];
xlabel('ndgrid Output')
axis([1 200 1 180]);
hold on
pcshow(sample)
az=0
el=90
view(az,el);
end
4 commentaires
投稿していただいたサンプルコードはデータが無いと実行できません。また、そのコードが何をしているか、何をできるようにしたいのか、もう少し具体的に教えて下さい。
Jiro Doke
le 17 Jan 2017
tetunari sogabe
le 18 Jan 2017
Modifié(e) : tetunari sogabe
le 18 Jan 2017
Jiro Doke
le 19 Jan 2017
前のコメントにもありますが、別の質問に回答があるようです。
Réponse acceptée
Plus de réponses (0)
Catégories
En savoir plus sur Introduction to Installation and Licensing dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!

