Replies: 2 comments
-
|
A quick thing you could try:
This should at least constrain the interaction to a subregion of interest. With a bit of luck, the performance will also be better, because most of the mesh is hidden out of view, so the fragment shader will not have to run for most triangles. I agree with Korijn that extracting a portion of the mesh is out of scope for PyGfx. Meshes can be tricky to work with, but its also not rocket science; a mesh is just vertices (i.e. an array of positions) and faces (each face is 3 indices into the array of vertices, which together form a triangle). So you could do:
|
Beta Was this translation helpful? Give feedback.
-
|
Multiple features come together to support this kind of problem (real time rendering of huge geometry).
Just dropping this for now so you have some leads to read up on. Regarding mesh subset selection functionality: that's not really a rendering problem! So I would say it is out of scope for pygfx (the interactive flow in the UI). Rendering only part of a mesh is possible already by filtering the indices you are rendering, and/or the draw range. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hello,
In my program, I am plotting a huge 2DM-Mesh (often more than 1 Million nodes and mesh elements (triangles and quads)) which represents a Digital Elevation Model and is the basis for simulating flow in river beds. Along with the mesh, I am plotting Lines and Points on the mesh using (Line Material and Point Material), which are the boundary conditions to the model.
Navigating along the river bed using Orbit/Fly Controller is not straight forward, #532. Commercial programs offer the ability to extract a portion of the mesh to view it, which first of, makes everything super responsive and fluid, and secondly makes navigation a lot easier.
Is it possible in Pygfx to achieve the same? Extract a small portion of the scene and navigate in this mini scene? Would it have positive consequences for GPU load?
Commercial software products (Aquaveo SMS) offer the ability to view and edit the mesh, and the steps are:
-select a portion of the mesh
-right click -> Edit Subset
-a subset of the selected mesh appears
-Edit the mesh
-commit subset (to apply changes) / revert subset (to ignore changes)
Apart from that, it would also be great to save the "views" and be able to load saved views, but I think thats probably possible outside pygfx.
Beta Was this translation helpful? Give feedback.
All reactions