Jump to content


Popular Content

Showing most liked content on 07/20/2018 in all areas

  1. 2 points
    enable [x] tangent Attribute tangentu in node "resample2" You can store the cross product in @N if you want, but by doing @N / @tangentu / @tangentv , you have a normal, orthogonal frame for each point, which is a strong foundation for anything downstream IMO. Also see polyframe, which generates N, tangentu and tangentv. No need to do cross products by yourself
  2. 1 point
    I've recently started using Houdini coming from a Grasshopper/Rhinoceros + Architectural background and quickly I realized it's such a great tool for parametric & procedural design for modeling some geometrical shapes which sometimes GH is not good at. I'm planning to post tutorials for Houdini to following Facebook page and Youtube channel as my note how to make geometries I'm interested in. [Facebook Page] https://www.facebook.com/ParametricProceduralHoudini/ [Youtube Playlist (Fast ver.)] [Youtube Playlist (Slow ver.)]
  3. 1 point
    Hard to tell without more info, but usually : you can solve the « stairs » problem by increasing the substeps of your simulation. With small substeps, those stairs effect appear where the speed is high. I don’t what source you have used, but if it’s from particles or object, you can also increase the substeps, to smooth the emission and then avoid having those artifacts. The « boiling » : well, I think you’re talking about the smoke taking the form of a big smooth mushroom while getting high in the air ? You can limit this either by lowering the temperature of your your smoke, and/or decreasing the buoyancy of your pyro sim. The force that is applied to the smoke is buoyancy * (delta Temperature). A bit like an Archimede force but with difference of T between the fluid and its surrounding. By decreasing that, you limit the mushroom effect. Hope that helps
  4. 1 point
    As if figuring out Houdini is not hard enough by itself.... HDA uploaded, use Show Blueprint while tweaking params...
  5. 1 point
    easiest way is to use point cloud functions in your shader to read the points and get the average Cd in a radius, then use that as your volume color. if you need the colors in SOPs, it's more or less the same thing... pcopen() and pcfilter() in a volume wrangle to get the average P within a radius, then bind that to a Cd vector volume. just have to create the volume in advance, before the wrangle.
  6. 1 point
    try disabling Constraint Averaging and adjust your weights as Jeff describes in this master class around 32:50 https://www.sidefx.com/tutorials/h15-masterclass-grains/
  7. 1 point
    I'm working on something related to art direct the swirly motion of gases; Its an implementation of a custom buoyancy model that let you art direct very easily the general swirly motion of gases without using masks, vorticles, temperature sourcing to have more swirly motion in specific zones, etc. Also it gets rid of the "Mushroom effect" for free with a basic turbulence setup. Here are some example previews. Some with normal motion, others with extreme parameters values to stress the pipeline. For the details is just a simple turbulence + a bit of disturbance in the vel field, nothing complex, because of this the sims are very fast (for constant sources: average voxel count 1.8 billions, vxl size 0.015, sim time 1h:40min (160 frames), for burst sources, vxl size 0.015, sim time 0h:28min). I'm working on a vimeo video to explain more this new buoyancy model that I'm working on. I hope you like it! Cheers, Alejandro constantSource_v004.mp4 constantSource_v002.mp4 burstSource_v004.mp4 constantSource_v001.mp4 burstSource_v002.mp4 burstSource_v003.mp4 burstSource_v001.mp4 constantSource_v003.mp4
  8. 1 point
    Here is another slight variation. Instead of generating a fixed length line segment that moves through time, generate the full path over the entire time range. Then add a primitive attribute @path_pos to each line primitive. Drive the offset along path value, of the path deformer, with this attribute. Then you can have some geometry leading others as they each flow along their own path. float frame_end = 200.0; // deform_path node expects input in the range of 0-1. f@path_pos = fit01(@Frame,0,frame_end); // Now offset each path based upon it's index. float delta = 0.05; // per-line delay time can be set here. f@path_pos -= (delta * @prim); ap_ps_Cardume_Odforce_v3.04.hiplc
  9. 1 point
    I used assemble SOP so that I need the number of pig primitive which have name attribute. Then I enable Fracture By Name of RBD Fractured Object SOP in DOPnet. test02.hipnc
  10. 1 point
    1. Easy way. From the description, it sounds like you need something similar to common Group parameter. Create dummy node inside subnet in a proper place and promote the Group parameter. It will pick the menu script you need. Optionally, remove the code from parameter template's Action Button tab or, alternatively, promote Group Type parameter to make viewport selection button work, if you want. 2. Hard way. When you need something more custom, it is done via Python (or HScript) using Menu tab on selected parameter template in the parameter editor: Example: from itertools import chain geo = kwargs['node'].geometry() groups = [g.name() for g in geo.primGroups()] group_menu = [(g, g) for g in groups] names = geo.findPrimAttrib('name').strings() name_menu = [('@name=' + n, '@' + n) for n in names] separator = [('sep', '')] menu = group_menu + separator + name_menu return list(chain(*menu)) This will add menu for primitive selections: group_and_name_menu.hipnc
  11. 1 point
    please take a look at the attached file. it´s an example how you could create bezier curves with arbitrary degree and another one relying on beziers in hermite form since you wrote about blending curves... petz curves_vex.hipnc
  12. 1 point
    Put all point positions into an array and make parameter "t" slide e.g. from 0 to 1 inside a for loop. int steps = chi('steps'); vector all_points[]; resize(all_points, npoints(0)); for (int i = 0; i < npoints(0); i++){ all_points[i] = point(0, "P", i); } int prim = addprim(0, "polyline"); for(int i = 0; i < steps; i++){ float slide = i / float(steps - 1); vector pos = spline("catrom", slide, all_points); int inter_pt = addpoint(0, pos); addvertex(0, prim, inter_pt); } Also a simple function for interpolating 4 points to a curve by yourself would be: int steps = chi('steps'); vector pt0 = point(0, "P", 0); vector pt1 = point(0, "P", 1); vector pt2 = point(0, "P", 2); vector pt3 = point(0, "P", 3); int prim = addprim(0, "polyline"); for(int i = 0; i < steps; i++) { float slide = i / float(steps - 1); vector pos0 = lerp(pt0, pt1, slide); vector pos1 = lerp(pt2, pt3, slide); vector ipol = lerp(pos0, pos1, slide); int inter_pt = addpoint(0, ipol); addvertex(0, prim, inter_pt); } VEX_spline.hipnc
  13. 1 point
    Hi, I have a project where I want to create a realistic ice melting effect. I am quite new to FLIP fluids, however I read a lot and watched some masterclasses about how the solver works in Houdini. But I still struggle at a lot of areas. Reference for the effect: What I have done currently is played around with the viscosity. Basically I took my geometry and created points out of it, then I an SDF volume from the same geometry and passed attributes the values onto points. So, the inner most points would have the lowest value and going to the surface it would reach 0. I fitted those values from a range like 1,000,000 to 0 and then using a geometry vop in the dop context i just subtract some viscosity from the points at each time step. Here are my low resolution tests: Particles: Meshed: https://www.youtube.com/watch?v=IokJPFoNi5w&feature=youtu.be I got a somewhat decent result, however it looks more like ice cream melting than ice. It feels like the melting is not solid enough. The particles are not holding the shape as ice would. That's how far I got for now. I have a few more ideas, though (haven't tried it yet): 1) Instead of using viscosity I was thinking to start with all the points disabled (not solving) and then gradually activate them. 2) I wanted to try out using pressure, like in this example (they are using realflow): http://https://vimeo.com/13599797 but have no idea how to manipulate the pressure field: I was hoping maybe somebody with more experience would put me on a better track and maybe have more ideas or suggestions on what would be the best way to achieve this result. Also, maybe you have some suggestions on the shading part? I have some ideas, but I always tend to take the most complicated approaches I am using H15. Thank you in advance
  14. 1 point
    I've wanted to tackle mushroom caps in pyro sims for a while. Might as well start here... Three things that contribute greatly to the mushroom caps: coarse sub-steps, temperature field and divergence field. All of these together will comb your velocity field pretty much straight out and up. Turning on the velocity visualization trails will show this very clearly. If you see vel combed straight out, you are guaranteed to get mushrooms in that area. If you are visualizing the velocity, best to adjust the visualization range by going forward a couple frames and adjusting the max value until you barely see red. That's your approximate max velocity value. Off the shelf pyro explosion on a hollow fuel source sphere at frame 6 will be about 16 Houdini units per second and the max velocity coincides with the leading edge of the divergence filed (if you turn it on for display, you'll see that). So Divergence is driving the expansion, which in turn pushes the velocity field and forms a pressure front ahead of the explosion because of the Project Non-Divergent step that assumes the gas is incompressible across the timestep, that is where where divergence is 0. I'm going to get the resize field thingy out of the way first as that is minor to the issue but necessary to understand. Resizing Fields Yes, if you have a huge explosion with massive velocities driven by a rapidly expanding divergence field, you could have velocities of 40 Houdini units per second or higher! Turning off the Gas Resize will force the entire container to evaluate which is slow but may be necessary in some rare cases, but I don't buy that. What you can do is, while watching your vel and divergence fields in the viewport, adjust the Padding parameter in the Bounds field high enough to keep ahead of the velocity front as that is where you hope for some nice disturbance, turbulence and confinement to stir around the leading edge of the explosion. or... Use several fields to help drive the resizing of the containers. Repeat: Use multiple fields to control the resizing of your sim containers. Yep, even though it says "Reference Field" and the docs say "Fluid field..", you can list as many fields in this parameter field that you want to help in the resizing. In case you didn't know. Diving in to the Resize Container DOP, there is a SOP Solver that contains the resizing logic that constructs a temporary field called "ResizeField", importing the fields (by expanded string name from the simulation object which is why vector fields work) with a ForEach SOP, each field in turn, then does a volume bound with the Volume Bounds SOP on all the fields together using the Field Cutoff parameter. Yes there is a bit of an overhead in evaluating these fields for resizing, but it is minor compared to having no resizing at all, at least for the first few frames where all the action and sub-stepping needs to happen. Default is density and why not, it's good for slower moving sims. Try using density and vel: "density vel". You need both as density will ensure that the container will at least bound your sources when they are added. Then vel will very quickly take over the resizing logic as it expands far more rapidly than any other field in the sim. Then use the Field Cutoff parameter to control the extent of the container. The default here is 0.005. This works for density as this field is really a glorified mask: either 0 or 1 and not often above 1. Once you bring the velocity field in to the mix, you need to adjust the Field Cutoff. Now that you have vel defined along side density, this Field Cutoff reads as 0.005 Houdini units per second wrt the vel field. Adjust Field Cutoff to suit. Start out at 0.01 and then go up or down. Larger values give you smaller, tighter containers. Lower values give you larger padding around the action. All depends on your sim, scale and velocities present. Just beware that if you start juicing the ambient shredding velocity with no Control Field (defaults to temperature with it's own threshold parameter so leave there) to values above the Field Cutoff threshold, your container will zip to full size and if you have Max Bounds off, you will promptly fill up your memory and after a few minutes of swapping death, Houdini will run out of memory and terminate. Just one of the things to keep in mind if you use vel as a resizing field. Not that I've personally done that... The Resolution Scale is useful to save on memory for very large simulations, which means you will be adjusting this for large simulations. The Gas Resize Field DOP creates a temporary field called ResizeBounds and the resolution scale sets this containers resolution compared to the reference fields. Remember from above that this parameter is driving the Volume Bound SOP's Bounding Value. Coarser values leads to blurred edges but that is usually a good thing here. Hope that clears things up with the container resizing thing. Try other fields for sims if they make sense but remember there is an overhead to process. For Pyro explosions, density and vel work ok. For combustion sims like fire, try density and temperature where buoyancy contributes a lot to the motion.
  15. 1 point
    Hi... The pixels in the z-depth image are stored as floating point numbers. Each pixel represents the distance from the camera of the surface which was rendered. So, if you have a grid that's 5 units from the camera, the pixel will have a value of 5 (very bright). There's a command line tool called "izg" which will convert a depth image to a gray scale image. You might want to try processing the .tiff file using this application. izg -a zdepth.tiff zdepth.jpg You can also do a similar effect in COPs by adjusting the contrast of the image so that the brightest pixel goes to 1 (in the case above, you'd want to set the contrast to the range 0-0.2). However, this is probably a little harder to control.