FreeCAD / FreeCAD/FreeCAD

Points: Convert point cloud to vertices

Open
#21,869 5 comments 0 reactions 0 assignees View on GitHub
Good first issue Mod: Points Type: Feature
Dominant language
C++
Stars
33.6k
Forks
6k
Avg merge
3d 15h
Merged PRs (30d)
196

Description

### Is there an existing issue for this?

- [x] I have searched the existing issues

### Problem description

I have point cloud and i want to manualy create surface from it, but first i need to convert the point into vertices, so i can start filling the faces.

At https://forum.freecad.org/viewtopic.php?t=76268 i've found following script

```python
points = App.ActiveDocument.Points # this is the load point cloud. You may have to adjust this line to use the correct object
compound = Part.Compound([Part.Vertex(i) for i in points.Points.Points])
Part.show(compound)
```

I think that might be worth adding to Points workbench as a new icon (converting the other way is already available).

### Full version info

```shell
OS: Arch Linux (XFCE/Xfce Session/xcb)
Architecture: x86_64
Version: 1.0.1.39285 (Git)
Build type: Release
Branch: makepkg
Hash: 878f0b8c9c72c6f215833a99f2762bc3a3cf2abd
Python 3.13.3, Qt 6.9.0, Coin 4.0.3, Vtk 9.4.2, OCC 7.8.1
Locale: Czech/Czechia (cs_CZ)
Stylesheet/Theme/QtStyle: FreeCAD Dark.qss/FreeCAD Dark/
Installed mods:
* sheetmetal 0.7.22
* Curves 0.6.58
```

### Subproject(s) affected?

Other (specify in description)

### Anything else?

I don't have experience with FreeCAD codebase. At first this seemed to be easy adition into `Mod/Points/InitGui.py`, but i've tried it and realized the `Points tools` toolbar is actualy created in C++ code, which is not yet initialized when python method `PointsWorkbench.Initialize()` is run... Therefore i cannot add it to the toolbar from there...

### Code of Conduct

- [x] I agree to follow this project's Code of Conduct

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.