Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to adjust the Max faces of a particular child in "_toplevel", and what part of the code is used to modify the object detail level through Max faces? #322

Open
Chunxiao7 opened this issue Jan 7, 2025 · 7 comments
Assignees
Labels

Comments

@Chunxiao7
Copy link

How to adjust the Max faces of a particular child in "_toplevel", and what part of the code is used to modify the object detail level through Max faces?

@linev linev self-assigned this Jan 7, 2025
@linev linev added the question label Jan 7, 2025
@linev
Copy link
Member

linev commented Jan 7, 2025

Hi,

maxfaces limiting total number of faces (triangles) created for provided geometry.
Very often large geometry contains millions of individual volumes.
Trying to render all of them will lead to generation of many millions of faces - which does not work with WebGL in web browsers. Therefore selection algorithm is applied to render only most significant volumes - until given number of faces are produced.

maxfaces cannot be applied for specific volume. Each volume either selected for rendering with all its faces or refused completely.

@Chunxiao7
Copy link
Author

I actually want to raise Maxfaces in the highlighted areas of the diagram without affecting the other areas.
2b7e77ad-9184-4c97-bfb3-dac88b8f6fcb

@linev
Copy link
Member

linev commented Jan 7, 2025

It is not possible to change number of faces for some specific branch of geometry model.
Also it is not possible to change it for highlighted volumes.

But you can try drastically increase maxfaces parameter for geometry like you show here.
JSROOT uses now InstancedMesh which improves a lot rendering of geometries with large number of similar volumes.

@Chunxiao7
Copy link
Author

The problem now is that when I increase the overall geometric Maxfaces until the expected Maxfaces are highlighted as expected, it causes too many Maxfaces in other areas, which in turn causes the browser to consume too much memory.
f48b5826-1f60-466a-87a3-9602812e2a56

@linev
Copy link
Member

linev commented Jan 7, 2025

Can you switch off visibility of volumes which you do not like to see in rendering?

@Chunxiao7
Copy link
Author

I'm sorry if I don't understand, but why switch off visibility? The problem l understand now is to only adjust the Maxfaces of volumes, not the visibility.

@linev
Copy link
Member

linev commented Jan 7, 2025

In the geometry model you can switch off visibility of some volumes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants