Thank you for the detailed response, for the "best fit" function, I'll look into how it could assist with edge detection.
Best regards,
Original Message:
Sent: 10-26-2024 04:52
From: Fernando Calvo
Subject: Assistance with Point Cloud Edge Detection and Clicking in TBC Macro Development
Hi Nayef,
as Ronny pointed, a simple coordinate picker will give you back the coordinates, however you need to pay attention to the object snap or leave it up to the user to have selected previously the correct object snap (point, if you want to pick points from the point cloud).
Regarding edge detection, it´s pretty tricky and I personally don´t like it, as I have tried and used many different software packages promising automatic detection etc, however a big percentage of false recognition happen with each single solution, so I needed much more to check all and correct the false recognition, than picking myself the correct points (i.e. the wall itself and not a furniture or a picture before the wall itself).
Having said that, I guess the "best fit" function included in TBC could help, however I didn´t try it yet from the programming side. Again, in my opinion, this is always very dangerous and also in the time that TBC needs to calculate the best fit for a selected point cloud rectangle, you can create several walls.
I use it i.e. for detecting lowest and highest points of a very small selected region of a room, i.e. 0.50 x 0.50 m, and even though it takes many seconds to give me back the lowest and highest points, so in that time, I can pick them from the cutting plane view, and I´m sure that the correct points were selected.
I hope this helps.
Regards,
Fernando
------------------------------
Fernando Calvo
calvo@calvo-geospatial.com
Original Message:
Sent: 10-25-2024 16:01
From: Ronny Schneider
Subject: Assistance with Point Cloud Edge Detection and Clicking in TBC Macro Development
1.
Assuming you have the appropriate snap mode enabled then a normal coordinate picker will give you the coordinate of the cloud point.
# in the XAML <Wpf:CoordinateEdit x:Name="coordCtl1" ShowElevationIf3D="True" AutoTab="True"/># in pythonp1_sel = self.coordCtl1.Coordinate
2.
can't help you with that, haven't looked into that yet
maybe @Fernando Calvo can, I believe he works quite a bit with point clouds
With my current knowledge I'd have to the user select/click points on either side of the edge.
Then retrieve cloud points from the database in the vicinity of those.
Use something like this https://community.trimble.com/discussion/whats-the-general-purpose-of-the-new-namespace-trimblerwcore-in-202400 to compute different planes and intersect those.
3.
Yes, there is, through the Visual Studio object browser. Check out my video in Post 2 here https://community.trimble.com/communities/community-homepage/digestviewer/viewthread?GroupId=415&MessageKey=4fa77769-d955-4525-80ff-daca0707c274&CommunityKey=8a262af4-a35e-4e9a-9dd3-191cc785899a
And that's basically all we have in terms of documentation. In meanwhile 6 years Trimble hasn't bothered to provide an SDK documentation as they have for the Access SDK for instance or other CAD programs do.
At the beginning we had Gary Lantaff, who wrote the TBC sample macros, to give us some advice here on the forum. But he retired a while back. Currently we have Bryce who occasionally posts something here and tries to help. Not sure what his position within Trimble is, but I had to work out quite a bit through trial and fail on own.
------------------------------
Ronny Schneider
Original Message:
Sent: 10-24-2024 23:18
From: nayef gmail.com
Subject: Assistance with Point Cloud Edge Detection and Clicking in TBC Macro Development
Hello,
I'm working on a Trimble Business Center (TBC) macro that performs tasks similar to the Buildings plugin, specifically for handling point cloud data from a scanner. My goal is to streamline edge detection by allowing users to click on a point within the point cloud, initiating automatic edge drawing. Here are a few questions I have:
-
Click Detection: Can a user click be detected on a specific point within the point cloud? If so, how can I retrieve the coordinates or identifier of the clicked point?
-
Automating Edge Drawing: Once a point is selected, what would be the best approach to detect and draw the edge automatically? Are there specific functions or methods within TBC that could assist with edge identification in point clouds?
-
Resources for Macro Development: I'm also looking for any advice on working with TBC macros in general. Is there a way to view all available variables and methods within TBC? Additionally, are there any resources or documentation that could provide guidance on how to effectively use these methods in macros?
Any insights, advice, or resources would be greatly appreciated. I appreciate any help you can provide.
------------------------------
nayef
------------------------------