Thu, 12/05/2024 - 08:51
How to accelerate the triangular mesh speed of OCCT is mainly used for visualization. like mesh LOD?
I have browsed the document. Now, in my test environment, I have encountered a slow grid generation. I saw this sentence in the document.
[wiki-mesh](https://github.com/Open-Cascade-SAS/OCCT/wiki/mesh)
An additional example of a different data model is the case when it is not required to create a mesh with discrete polygons synchronized between adjacent faces, i.e. in case of necessity to speed up creation of a rough per-face tessellation used for visualization or quick computation only (the approach used in XDEDRAW_Props).
`the approach used in XDEDRAW_Props`
I looked up the relevant codes and found nothing. Could someone help me? Or give me some other ideas
Thu, 12/05/2024 - 18:35
Hello.
I probably expect the idea about XDEDRAW related with Bounding box using to define more preferred quality.
For example:
Best regards, Dmitrii.
Fri, 12/06/2024 - 06:07
I may give only a couple of suggestions:
Fri, 12/06/2024 - 06:19
1. The first scheme (aka Group) you mentioned is also the means I am using now.
2. (Start meshing from rough quality to higher quality)This method is similar to LOD, but the code of grid generation algorithm is very complicated. I have probably read the documents and codes and have a little knowledge. If it can be combined with the visualization module (for example, using different mesh qualities in different viewports, this is also the practice of most CAD software)
Fri, 12/06/2024 - 06:24
[There are also some advanced options in algorithm, which might be tuned to avoid too long meshing on some problematic shapes]
Some advanced options is the parameter in this class`IMeshTools_Parameters `, and it would be great if it could help me.
Fri, 12/06/2024 - 06:05
Thank you for your reply.
I read your code. You mean to control the grid quality by controlling different linear deflection, so as to achieve the effect of LOD, right?
Fri, 12/06/2024 - 06:09
To generate triangulation of different visual quality (aka LODs), you may adjust deflection parameters of
BRepMesh
(both - angular and linear).Fri, 12/06/2024 - 06:22
My idea is to generate meshes with different qualities by controlling the parameters of linear deviation, and use different mesh qualities under different viewport conditions. But how to attach different mesh qualities to AIs_Shape?
Fri, 12/06/2024 - 06:27
PS:
On my machine, I tested the following code and found that' -algo default' takes 1 minute and 5 seconds, while' -algo delabella' takes 5 seconds. Why is there such a big gap?
```
psphere s 10
### Default Algo ###
incmesh s 0.0001 -algo default
### Delabella Algo ###
incmesh s 0.0001 -algo delabella
```
Fri, 12/06/2024 - 09:09
The second run of incmesh reused the existing mesh. Run 'tclean s' before second run to make it fare.
Fri, 12/06/2024 - 10:34
thanks