Jump to content

storing points to file


kustaa

Recommended Posts

hi,

i want to split my points in sop context to multiple groups and store each group as a separate file.

my first try was with forEachSop. inside it i make a group of points, delete others and store the result with file node. this worked ok but it gets really slow when i have lots of points and many iterations on forEach. not very efficient approach.

i was hoping to write a vexsop that would split the points in groups and store them with pcwrite function. but it seems that pcwrite doesnt work on sop context(even though houdini manual says it would).

is there some other way to write on file in vex? or maybe theres a function in HOM that i could use for writing to .pc/.bgeo file?

cheers,

Kustaa

Link to comment
Share on other sites

hi,

i want to split my points in sop context to multiple groups and store each group as a separate file.

Try this one I made, have in mind that creating the point groups in VEX can be multithreaded, but creating them with expressions can´t.

To export the points you should look at the Geometry node on the ROP context.

Hope it helps

Pencha

Link to comment
Share on other sites

thanks for the reply Pencha!

on my foreach approach my main problem is the deleting of points before saving to file. lets say i have 200000 points and i want to split them in 20 files. i have to delete 190000 points to be able to save those 10000 points to file. and i have to repeat this twenty times. it would be nice to be able to save a point group to disk without needing to delete the rest of the points.

i hope HDK is not the only option.. any ideas?

cheers

Kustaa

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...