Houdini Simulations and Dynamics

Jul 13, 2024

Lecture: Houdini Simulations and Dynamics

Introduction

  • Topic of Lecture: Introduction to simulations and dynamics in Houdini
  • Previous Parts: Covered rendering and basics
  • Focus of This Part: Pop networks, i.e., particle operator networks

What is a Pop Net?

  • Definition: Particle Operator Network (Pop Net)
  • Terminology:
    • Sops: Surface Operators (static geometry)
    • Dops: Dynamic Operators (dynamic simulations)
    • Tops: Other Dynamic Operators

Basic Simulation: Creating a Spark System

  • Goal: Create a system where sparks fall, break, and jump along a surface
  • Steps:
    1. Create Geometry Node: Called Sparks
    2. Create Grid Node: Size 1x1, move up by 1.5 meters
    3. Animate Grid: Set keyframes for grid movement (frame 1 and frame 96)
    4. Enable Real-time Playback: Set playback to actual frame rate (96 frames @ 24 FPS = 4 seconds)

Pop Network Creation

  • Create Pop Network: Connect grid to the first input
  • Initial Observations:
    • Particles generated from grid
    • No dynamics applied initially (gravity, interaction, etc.)

Adding Dynamics

  1. Gravity:

    • Add Gravity Force: Particles now fall due to gravity
    • Caching: Blue bar indicates pre-calculated frames
  2. Collision with Ground Plane:

    • Add Ground Plane: Particles collide and bounce
    • Adjust Emission Jitter Time: Avoid uniform particle sheets
    • Initial Velocity: Set varied velocity to make particles spread out

Collision Behavior & Replication

  1. Pop Collision Behavior:
    • Detect Collisions: Particles turn red upon collision
    • Create Group: Name it Impact
    • Die on Collision: Particles disappear upon impact
  2. Pop Replicate:
    • Replicate Particles on Impact: Generate new particles upon collision
    • Adjust Settings: Impulse count, group, shape, etc.
    • Fix Order: Ensure collision detection occurs before replication
    • Adjust Life Expectancy: Define how long new particles last
    • Group Node: Name it Splash

Attribute Wrangling with Vex

  • Set p-scale: Define size of particles using @p-scale attribute
  • Generate Random Scale: Use rand function with particle ID for randomness
  • Shrink Particles Over Time: Use @nage (normalized age) attribute

Rendering Preparation

  • Adjust p-scale: Set appropriate size for rendering
  • Add Camera and Render Settings: Configure for rendering
  • Setup Material Library: Define materials for Sparks
  • Use Emission Color: Set emission intensity using point color

Motion Blur & Depth of Field

  • Motion Blur: Enabled using velocity attribute
  • Depth of Field:
    • F-stop: Adjust for desired depth effect
    • Focal Distance: Shift focal plane to desired position

Final Adjustments and Rendering

  • Tweak Settings: Adjust p-scale, emitter, camera angles, etc.
  • Setup Render to Disk: Configure frame range and output path
  • Post-Processing: Optional compositing for enhanced visuals

Conclusion

  • Summary: Created and rendered a basic particle simulation with sparks in Houdini
  • Encouragement: Experiment with adjustments, share results
  • Next Steps: Further explorations in Houdini dynamics and simulations