Archived post by squidbean

So there is a “trick” / non-obvious way to generate collision shapes for ragdolls now that does not require you to sit and click for hours manually

this thing is for kinefx (not crowds) but….

make sure you have a rest transform on the skeleton going in and unpacked geo in the 3rd input

you can add the shapes into the crowd setup as a new agent layer, like any other skin

call it collision, but don’t display it

and in your collision layer you reference “itself” basically the existing collision layer shapes

and because its generated from the skeleton, all the names etc match

that way, this is what the kinefx tool generates

and the agent collision layer adopts it nicely

saves you a few hours of raging at the terrible UI while you try to align pill shaped…. %$@!

Attachments in this post:
http://fx-td.com/houdiniandchill/wp-content/uploads/discord/20245904/12/24/CrowdVellum-v06.mp4
http://fx-td.com/houdiniandchill/wp-content/uploads/discord/20245904/12/24/image.png

Archived post by mattiasmalmer

For no real reason at all I have been spending waaaay too much time reverse engineering Nukes rotosplines so that I can copy them over to houdini. vex hell

Here is where Im at now with the nuke spline. Do not read my atrocious vex code or you might go blind.

still lots of edge cases and features to handle.

Attachments in this post:
http://fx-td.com/houdiniandchill/wp-content/uploads/discord/20241403/24/24/houdini_0mgxB8svew.mp4
http://fx-td.com/houdiniandchill/wp-content/uploads/discord/20241403/24/24/nukesplajn.hipnc

Archived post by mattiasmalmer

I have improved on that script since then. We use it at the office now and so far no ill effects.

you just put this in your /python3.10libs folder

it creates backup files every 5 minutes if the undostack has changed. it does it by saving a copy of your scene named Backup_scenename_0001.hip and keeps 20 files that it overwrites in a rotating fashion. you can easily adjust the script for your workflow. (longer intervals more files whatever.)

it has to be named ready.py so that houdini runs it at the correct time.

the benefit with this script is that you never overwrite your actual file. something that the autosave function built in does.

Attachments in this post:
http://fx-td.com/houdiniandchill/wp-content/uploads/discord/20242503/15/24/ready.py

Archived post by paqwak

Yup looks the version I did (based on @mestela initial work) is slightly faster, but you have to extend the voxel banding at lot on the vdb from polygon itself … after that it’s a single volume vop … it’s probably less clever but faster to execute. Otherwise yes Dom toolset is a way better approach, especially if you can only use SDF primitives.

Attachments in this post:
http://fx-td.com/houdiniandchill/wp-content/uploads/discord/20241103/11/24/sop_vdbsoftboolean.1.0.hda

Archived post by jefflmnt

@David Torno

with a bit of help about binary string lookup from a good friend of mine

it’ll spit out a CSV file with this

took a tad longer than I thought – but I think there might be a better way to do this lol

Attachments in this post:
http://fx-td.com/houdiniandchill/wp-content/uploads/discord/20245503/10/24/get_versions.hiplc
http://fx-td.com/houdiniandchill/wp-content/uploads/discord/20245503/10/24/image.png

Archived post by aswaab

Some code for the volume wrangle. Volume goes in input 1. Seed points in input 2. And then you need to construct the control interface.
`//controls int mirror = chi(“mirror”); int distanceMetric = chi(“distanceMetric”);
//init variables float currentdist = 1000000; //pick a super high starting value. In theory, it should be infinite… int closestpt = 0; //placeholder for seed point float dist = 0; //placeholder for distance to seed vector pos = v@P; //current voxel position
//mirror if(mirror == 1) pos.x = abs(pos.x); if(mirror == 2) pos.y = abs(pos.y); if(mirror == 3) pos.z = abs(pos.z);
//calculate distances int pts = npoints(1); for(int pt = 0; pt < pts; pt++){ vector ptpos = point(1, "P", pt); vector vdist = abs(pos - ptpos); //vector distances if(distanceMetric == 0) dist = length(vdist); //euclidian/voronoi distance if(distanceMetric == 1) dist = sum(vdist); //manhattan distance if(distanceMetric == 2) dist = max(vdist); //chebyshev distance if(dist <= currentdist){ closestpt = pt; currentdist = dist; } }`

Above code will give you a density field that stores the seed values. From there, you can parse it how you need.

(gemming my own code for posterity)

Archived post by _white_dog_

I have just published a new Cloud Solver 😀 drive.google.com/file/d/18RnoiX-Hvn4kM3_L09wT0INXRdRYFjxh/view?usp=drive_link
It is based on the SIGGRAPH Asia 2020 paper “Stormscapes: Simulating Cloud Dynamics in the Now”. It can simulate fog, stratus, stratocumulus, cumulus, cumulonimbus, Kelvin-Helmholtz instability, and more. computationalsciences.org/publications/haedrich-2020-stormscapes.html

Attachments in this post:
http://fx-td.com/houdiniandchill/wp-content/uploads/discord/20240502/23/24/cloud2.mp4

Archived post by waffleboytom

this works but I feel like it’s a hack

“`py node = hou.pwd() stage = node.editableStage()
prim = stage.GetPrimAtPath(‘/geo/points_0’)
ptsattrib = prim.GetAttribute(‘points’)
ptsarray = prim.GetAttribute(‘points’).Get()
ptsattrib.Set(ptsarray[::10]) “` weirdly enough the python version doesn’t seem to affect the HoudiniDataId while the vex version sets it to -1 which makes me go hmmmmm

“`py node = hou.pwd() stage = node.editableStage()
prim = stage.GetPrimAtPath(‘/geo/points_0’)
attribs = prim.GetAttributes()
for attrib in attribs:
interp = attrib.GetMetadata(“interpolation”)
if interp == “vertex”:
valarray = attrib.Get() attrib.Set(valarray[::10]) “` this makes more sense as if you have more primvars on your points you would wanna slice those arrays as well

the 10 here drives the percentage of points you want, setting it to 10 gives me 10 percent of my original pointcount

to get 5% you would do 20 because 100/20

“`py node = hou.pwd() stage = node.editableStage()
for prim in stage.Traverse():
if not prim.GetTypeName() == ‘Points’:
continue
attribs = prim.GetAttributes()
for attrib in attribs:
interp = attrib.GetMetadata(“interpolation”)
if interp == “vertex”:
valarray = attrib.Get() attrib.Set(valarray[::10]) “` here’s a version that will cull all your point clouds to keep only 10%. Might be slow if you have a large stage as I’m doing a stage traversal here

this won’t work for an animated pointcloud though

hold on

right, here’s a file with a static point cloud, animated(time dependent), animated(time samples)

Attachments in this post:
http://fx-td.com/houdiniandchill/wp-content/uploads/discord/20245502/17/24/image.png
http://fx-td.com/houdiniandchill/wp-content/uploads/discord/20245502/17/24/waffles_cull_points_solaris.hip