フィルターのクリア

Cropping 3D LAS file

2 ビュー (過去 30 日間)
stav marzuk
stav marzuk 2021 年 11 月 1 日
コメント済み: stav marzuk 2021 年 11 月 4 日
Hello,
I'm working with a very large LAS file and because of its size I need to crop him to process piece by piece.
When i try to load him as 3D without cropping I get this:
I've tried using a bunch of LAS packages but can't seem to find any useful tool for that.
I've developed a 2D cropping tool for my previous project but I'm having trouble using it on 3D files..
Is there a way to crop LAS files effectivley, if so please let me know i'm desperate!
Thanks.

採用された回答

Walter Roberson
Walter Roberson 2021 年 11 月 1 日
%assuming cropping to a cuboid aligned with the axes
%Min_x, Max_x, Min_y, Max_y, Min_z, Max_z should be set appropriately
loc = ptCloud.Location;
x = loc(:,1);
y = loc(:,2);
z = loc(:,3);
mask = Min_x <= x & x <= Max_x & Min_y <= y & y <= Max_y & Min_z <= z & z <= Max_z;
cropped_points = loc(mask,:);
cropped_color = colorData(mask,:);
cropped_ptCloud = pointCloud(cropped_points, 'Color', cropped_color);
  1 件のコメント
stav marzuk
stav marzuk 2021 年 11 月 4 日
Thank you for the answer!
Do you know if there's a way to use the function drawpolygon to trim LAS files?
Also, is there a way to see the LAS file i uploaded (in the picture above) properly?
it's all white and i can't see the z values either.
Any help is really appreciated.

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File Exchange2-D and 3-D Plots についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by