Quantcast
Channel: Scripting - McNeel Forum
Viewing all articles
Browse latest Browse all 4145

Python - Get Curve Degree

$
0
0

Hello,

I’m trying to create simple ghpython component that returns the degree number value of the input curve list and stuck on how my input should be hinted/called.

It appears it wants a guid or a string as the input but I want to be able to feed it referenced curves inside GH so I don’t always have guids available for all inputs.

Thanks for your help and pointing me in the right direction!

Script thus far:

import rhinoscriptsyntax as rs
import scriptcontext as sc

if rs.IsCurve(C):
    degree = rs.CurveDegree(C)
    print "Curve degree:", degree

D = degree

Graph space:

4 posts - 2 participants

Read full topic


Viewing all articles
Browse latest Browse all 4145

Trending Articles