Jump to content

process on unpacking point primitives after a RBD sim ?


berniebernie

Recommended Posts

Hello

I'm doing a RBD (bullet) sim with custom concave geo (proxies) that I pack my self using assemble. I use a scatter and copy to points to set up my inital state, run the sim.

 

I use a dopimport, and I would like to fetch the hi rez geo. Tutorials show that if I had the high rez geo scattered the same way I could plug it and it would work straight away. However I would like, with only my points, to retrieve the high rez geo.

 

I thought I would use a foreach and apply primintrinsics or transformpieces or even a copytopoints as seen in some tutorials like here but nothign works, my scales and pivots don't seem to work.


 

zNrBihL.gif

 

To give you an idea of what my network looks like before the dopnet:


48bLam5.png

I cross posted on Sidefx forums but it wasn't published sorry for the crosspost.

If you have any info on this I'm very interested.

Link to comment
Share on other sites

I only have 3 hirez objects (that were never scattered, only their low rez representation was), so when I feed it to the transform pieces, I only get these 3 pieces with the wrong pivots:

 

EGXPvd0.gif

 

I understand that I need a foreach to grab the geo (and it's probably compilable so fast) but I don't understand why the pivots/rotation go to shit. I'll experiment today and get back if I find a solution. Thanks

Link to comment
Share on other sites

756a66b226b6d7e6793133410831ecd3.png
 

 

Turns out I was running a for loop on points and not primitives, and had a name problem where the Dopnet got rid of my name attribute. After a bit of object path wrangling now it works. I haven't tried the compiled blocks but it doesn't seem to be a bottleneck.

Keeping this here if I ever run into the problem again.
In the wrangle

 

@P = point(1,"P",@ptnum);
matrix3 t = primintrinsic(1,"transform",@primnum);
setprimintrinsic(0,"transform",@primnum,t,"set");
vector pivot = primintrinsic(1,"pivot",@primnum);
setprimintrinsic(0,"pivot",@primnum,pivot,"set");

 

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...