Skip to content

bruchansky/pipes-generator-blender

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Pipes Generator for Blender

A Python class to generate pipes that randomly fill a 3D space while avoiding obstacles. The procedural pipes are based on Blender primitives, so no need to import any mesh.

Pipes engine

Example (Sauna part II):

Pipes example

Instructions

  1. Copy the code inside Blender (scripting workspace)
  2. Add the following items onto your scene:
  • A perimeter mesh to define the 3D space where pipes can grow (to set as invisible)
  • A series of surfaces that define the origin of each pipe (location, angle and direction)
  • Obstacles that pipes should avoid (optional)
  1. Update parameters at the bottom of the script
  2. Press play in the scripting workspace to generate the pipes
  3. A random material is assigned to each pipe, and can be updated in materials

Current limitations

  • Pipes don’t scale with their origin surfaces, but their radius and length are configurable.
  • Pipes won’t be generated if other pipes are in front of their origin surfaces.
  • The algorithm won’t always find a path for a pipe to reach the perimeter zone, and some pipes might be truncated.

Best is to play the script several times until a satisfactory composition is found.

About

Pipes generator for Blender

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages