algorithmic modeling for Rhino
Hey everyone,
I'm trying to get the length of a bezier crv made in a VB component:
Dim bezCurve As New BezierCurve(pts)
Dim bezCrvOut As NurbsCurve = bezCurve.ToNurbsCurve
Dim crv_length As Double = bezCrvOut.GetLength()
bezCrv = bezCrvOut
lenOut = crv_length
Am I doing something wrong? When I take the curve output and measure its length I get 164, but I'm getting lenOut = 0.
Thanks,
Brian
Tags:
Hi Brian,
This should have worked. Will have to dig deeper to see why the length is returning false (or zero).
If I try a small variation of your code, I can get it to work as expected:
Dim bezCurve As New BezierCurve(pts)
Dim nc As New NurbsCurve(bezCurve.ToNurbsCurve())
crvOut = nc
lenOut = nc.GetLength()
I hope this will help for now.
Welcome to
Grasshopper
© 2025 Created by Scott Davidson.
Powered by