Meshing Points (Tree Structure)

   3952   9   0
User Avatar
Member
101 posts
Joined: Dec. 2012
Offline
I have created a bunch of points scattered in a tree-structure, i would like to mesh those, into tubes, is there any good solution?

I have tried to create a VDB and tried to fill the spacing between the dots, but it didn't work clean.

File is attached, would be really nice giving some hints. I don't have the direction vectors as attributes, but if needed for any method, i can rerun my sim.

thanks!

Attachments:
spacecoloniazation.hipnc (175.5 KB)

User Avatar
Member
8592 posts
Joined: July 2007
Offline
your file doesn't contain the geometry
you need to load houdini geometry, then lock it
if you lock Alembic SOP in Alembic Delayed Load Primitives mode, all we see is one point/primitive with path to your alembic file, so not the geometry itself
Tomas Slancik
FX Supervisor
Method Studios, NY
User Avatar
Member
101 posts
Joined: Dec. 2012
Offline
You are completely right! I added the file unpacked. thank you for looking into the file!

Attachments:
spacecoloniazation_v02.hipnc (205.6 KB)

User Avatar
Member
8592 posts
Joined: July 2007
Offline
how did you create those points?

if those are trailing points of some particles and you have stored v attribute of the particle leaving them, then it should be pretty straightforward to join them in cvex

additionally if you have age/time attribute which represents time from beginning of your sim till the trail particle is created, that can help to get correct thickness on the branches

and once you have points connected and proper attribute for thickness, you can use polywire to create desired tubes

can you provide those attribs from your sim?
Tomas Slancik
FX Supervisor
Method Studios, NY
User Avatar
Member
8592 posts
Joined: July 2007
Offline
so until you provide those attribs here is the version from current geo
it's not completely perfect as that direction info would really help

Attachments:
ts_connectPoints.hipnc (229.3 KB)

Tomas Slancik
FX Supervisor
Method Studios, NY
User Avatar
Member
101 posts
Joined: Dec. 2012
Offline
Hey Tamte, thank you for the solution, that works great! I've integreated the Age value as well, i am creating the points based on a space colonialization algorithm described here:

http://algorithmicbotany.org/papers/colonization.egwnp2007.html [algorithmicbotany.org]

So i don't have a velocity attribute but a direction vector (so every created point as a direction from it's parent)

I could add branches as well in groups, but not there yet.

thanks!

Attachments:
spaceCol_age_velocity.hipnc (251.1 KB)

User Avatar
Member
8592 posts
Joined: July 2007
Offline
if I consider direction from root to tips
now your direction vector points to next point
it would be great if the direction vector can keep that direction from previous point so that root point will have empty direction vector as there was no previous one and tip points would still have direction which is from previous point

the point of all this is if you invert those vectors and scale to segment length they will reach more or less the previous point and that will work even for branching ones, so the pointcloud lookup can be much more precise and you can get perfect connections
Tomas Slancik
FX Supervisor
Method Studios, NY
User Avatar
Member
101 posts
Joined: Dec. 2012
Offline
Hey tamte, your idea sounds great but the algorithm is evolving iteratively, so i would have to determine, that a new branch has started (when a treeNode gets 2 childnodes), so i would have to traverse the tree and retrieve the normals by determining which Node is a branch.

well….i could do that… let me provide you a solution tomorrow, i like your idea.
User Avatar
Member
8592 posts
Joined: July 2007
Offline
not sure how that algorithm looks like
but if you are iterating from root to tips, you will know that direction as you first need to get that direction, then move the point, you you just need to remember direction in which the point was moved and not the direction in which you will move the next one as you have it now, shouldn't be any work at all, but depends on your setup
Tomas Slancik
FX Supervisor
Method Studios, NY
User Avatar
Member
101 posts
Joined: Dec. 2012
Offline
Hey Tamte, while creating it, i realized that i didn't really get your idea So, every Point (expect the root one) will have an Attribute, which points to it's previous node?
  • Quick Links