top of page



For my graduate-level graphics course CIS 5660:  Procedural Graphics, I worked with Houdini in order to create a node-based, procedural, lego-ifier, which would use procedural modeling to convert any faceted mesh to a collection of LEGO pieces, including slope bricks, flat bricks, and block bricks (2x2, 2x1, 1x1). This project allowed me to gain more familiarity with VEX functions, custom nodes, and iterative logic in Houdini. Below is a collection of renders:

​I created a custom lego-ifying geometry node as follows: 

  • Converted mesh into points

    • Acquired color and surface normal information of each particle using an Attribute Transfer node

  • Converted points to LEGOs

    • Collected "top" particles of mesh using an Attribute Wrangle VEX function that checked if a point had a particle above it (if no particles were above, then it was placed in the "top" point group)

    • From the "top" group, checked for points to place slope bricks versus flat bricks

      • If a top group point had a surface normal that was different enough from <0, 1, 0> then it would be placed in the "slope" point group, else it was a normal "top" group point

    • Based on the normal's x/y/z values, determined if a slope brick would be facing left/right/forward/backward

    • Slope bricks were placed at slope points, whereas Flat bricks were placed at non-slope group top points

    • Block bricks (2x2, 2x1, 1x1) were placed at every point not already filled with a slope or flat brick

      • Used greedy approach

        • First populated 2x2 bricks, then 2x1, then lastly 1x1

      • Prevented bricks from intersecting by using bounding boxes and Block Begin/Block End nodes

        • If the number of particles within a bounding box equaled the number of particles that would overlap with a brick (e.g. 4 particles for a 2x2 block brick, 2 particles for 2x1), then a brick would be placed there

  • Exposed node parameters 

    • User could adjust multiple features of the lego-ifier node including: 

      • Adjusting the scale of the bricks  

      • Changing the threshold that particles would be determined to be a sloped brick  

      • Adjusting the percentage of "top" particles that use flat bricks versus no brick at all  

bottom of page