AsAttributeBuffer to mesh dx11(set vertex data)

Hi everyone,

I try to get vertex data of particule sytem to create a mesh.
The attribute can be generate a good mesh. My mesh is not complete and disorder.
Can you give me a good solution to get the good mesh?Any ideas?
geometry_to_particule6.v4p (37.5 KB)

Thank you

this is about winding order. the sequence, in which your vertices get connected to a triangle, determines its culling.
image

use the “cull mode” node to show meshes with front- or back culling. set it to “none” to see all meshes.

Thank you for your answer.
it seems better when I use the"cull mode"but it’s not perfect.
Meshes is always in disorder.

Well it’s obviously not going to be perfect because, if you can see from the picture with culling, geometry has topology, and vertices should be ordered by topology:
If you have Triangle List you should order your points as:
vertex1 vertex2 vertex3 to get triangle so some vertices will share some other vertices

Are you sure you provide it in correct order? I’m totally not…
If you want to trial and error way i would start with GeometryBuffer, and then would move to playing around with readback and particles, so you can list understand what is wrong

geometry_to_help.v4p (5.0 KB)

P.S. There is two major approaches when generating geometry from points:

  1. To draw some 3d primitive from point or points in geometry shader (eg. box between two points)
  2. To use some code that does sorting for you
1 Like

Thank you Antokhio for your answer.
It’s better to use code. Can you show me direction to find documentation or example of code to realize that. Thank you

Well, this is not a beginner theme usually this stuff studied in workshops during node festival…

If you somehow describe the effect you want to achieve, maybe I can find some examples or explain you what to do…

The problem is such effects are called pipelines and usually this is a composition of shaders made specially to achieve some special kind of thing…

ok, thank you.
it’s more complex than I thought :)
My target in the beginning is to create meshes from buffer.

The goal is apply particule effect to my mesh (turbulence,force,ParticleModifier,…).
I transform Mesh in buffer and I apply particule modifier. After, i use buffer position to create my native mesh.
But it seems very difficult to realize that.
Can you show me an example of shader to realize that?

Thanks

Well the problem with this approach that particles are not exactly suited to make meshes out of it…
Just for the info, have you heard about raymartching? Do you know that there is Fuse package for vvvv-gamma that suppose to cover like 99% of your request, but using volumes instead of meshes?

So short story long, meshing particles, regular way would be meatball, not sure i have it for compute…
With CPU version here you can try that:
geometry_to_particule_metaball.v4p (39.1 KB)

This one for generating lines between points:
ConnectAll.zip (55.0 KB)

you can check there is also some examples in packs\dx11\girlpower\

Thank you Antokhio

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.