Restrict specific Rotation and Position with RBD

   958   5   1
User Avatar
Member
6 posts
Joined: Sept. 2018
Offline
Hi! I'm working on a personal project where I need to make a medieval type Stone Wall.

I used the uv layout method to place the stones, now I'd like to do a simple rbd sim to de-intersect using the found_overlap trick.



I need the sim to not move on Z Position and Y Rotation. Using @P=0; on a Geometry Wrangle helps but it transforms the stones to the center (It needs to respect the pre-sim Z Position).



Thanks!
Edited by adro - May 1, 2024 03:57:39

Attachments:
Screenshot_20240501_093142.png (1.5 MB)
2024-05-01_09-18.png (1.8 MB)

User Avatar
Member
12 posts
Joined: May 2015
Offline
Hey

Could you not create a rest attrib at the sop level and then use that as the position that it set on the Geometry Wrangle?
User Avatar
Member
6 posts
Joined: Sept. 2018
Offline
Thanks for the reply Honza,

I haven't been able to reproduce your solution, I'm new to rbd and dops sorry

This is the code I tried for the geometry wrangle (connected to postsolve)
vector rest = point(0, "rest", 0);

@P[2] = rest[2];

# no idea on how to restrict the y rotation

As I mention on the start, this is part of a medieval wall. My objective with the rbd part is to give more variety to the uv-layout result and get something like this texture [quixel.com].

This is my progress so far, but a lot of stones still intersect. The stones are all packed primitives.




If you can provide an example it would be very helpful
Edited by adro - May 6, 2024 07:14:47

Attachments:
Screenshot_20240506_125757.png (2.5 MB)

User Avatar
Member
59 posts
Joined: April 2008
Offline
You could use v and w attributes to restrict Z Position and Y Rotation, I got this simple example.
Hope it helps.

Attachments:
rbd_restriction.hipnc (368.4 KB)

User Avatar
Member
9 posts
Joined: Sept. 2020
Offline
Alternatively, you could switch to Blender...
User Avatar
Member
6 posts
Joined: Sept. 2018
Offline
Benyee
You could use v and w attributes to restrict Z Position and Y Rotation, I got this simple example.
Hope it helps.

That definitely help, thanks a lot!
  • Quick Links