Need help creating stirrups (rebar) in beams using Dynamo — wrong dimensions & wrong placement

Need help creating stirrups (rebar) in beams using Dynamo — wrong dimensions & wrong placement

sgonzalezNXU9D
Explorer Explorer
170 Views
2 Replies
Message 1 of 3

Need help creating stirrups (rebar) in beams using Dynamo — wrong dimensions & wrong placement

sgonzalezNXU9D
Explorer
Explorer

Hi everyone,

I’m trying to build a Dynamo script that automatically generates stirrups inside a beam, but I’m running into issues with the geometry and placement of the rebar. I’ve spent several days trying to troubleshoot (even with ChatGPT) but I still can’t get it right, so I’m hoping someone here can point me in the right direction.

What the script does so far

  1. The script starts by asking the user for several inputs:

    • The beam element to place stirrups in

    • The rebar diameter

    • The stirrup shape (rectangular for now)

    • The spacing (eventually I want to support 3 sets of stirrups per beam — two end zones + one middle zone — but I am currently testing with just one set)

  2. With Python, I extract:

    • The perimeter curves of the beam’s cross-section

    • The surface and geometric data for reference

  3. I compute a centerline for the stirrup by offsetting the perimeter curves inward.
    The offset considers:

    • The beam’s cover

    • Half of the bar diameter

  4. I feed the resulting curves into Rebar.CreateFromCurves (via the Create.FromCurve node in Dynamo) to generate the stirrup.

The problem

Even though the offset geometry looks correct (conceptually), the resulting rebar:

  • Has incorrect dimensions

  • Is sometimes larger than the beam itself

  • And worst of all, is being created outside the beam, instead of inside the section

I’ve double-checked:

  • Coordinate systems

  • Units (I fixed an earlier mm vs cm issue)

  • Offsets

  • The curve order

  • The shape matching Revit’s default stirrup families

But the problem persists.

What I’m trying to understand

  • Why do the stirrups get created with the wrong dimensions even though the input curves should match the adjusted section perimeter?

  • Why does Revit place the rebar outside the beam, even when the curves are clearly inside the cross-section when inspected in Dynamo?

  • Is there something special about the coordinate system or curve direction that I’m missing when working with Rebar.CreateFromCurves?

If anyone has run into this before or can spot what I might be doing wrong, I would really appreciate the help.
This is part of a larger workflow I’m developing, and I feel stuck at this point.

Thanks in advance!Screenshot 2025-12-04 152409.png

0 Likes
Accepted solutions (1)
171 Views
2 Replies
Replies (2)
Message 2 of 3

EdwinG
Collaborator
Collaborator
Accepted solution

Try this

Create.FromCurves

EdwinG_0-1765146728545.png

 

0 Likes
Message 3 of 3

sgonzalezNXU9D
Explorer
Explorer

@EdwinG Thank you very much for your response.

You were absolutely right — I was using the Create.FromCurve node (singular) instead of Create.FromCurves. After switching to the correct node, the geometry behaves as expected. I’ll keep refining the script to reach the final result I’m aiming for.

Thanks again for the help! 🙌