Cannot create instances of RevSurface no public constructors

import Rhino.Geometry as rg
import math

line = rg.Line(1,0,0, 1,0,1)
crv = rg.LineCurve(line)
axis = rg.Line(0,0,0, 0,0,1)
rg.RevSurface(crv, axis, 0.0, math.pi*2)

output is

Error: Runtime error (TypeErrorException): Cannot create instances of RevSurface because it has no public constructors

is it the Rhino.Geometry.RevSurface bag, or my ignorance?

import Rhino.Geometry as rg
import math

line = rg.Line(1,0,0, 1,0,1)
crv = rg.LineCurve(line)
axis = rg.Line(0,0,0, 0,0,1)
rev_srf=rg.RevSurface.Create(crv, axis, 0.0, math.pi*2) # you need to add the Create method

https://developer.rhino3d.com/api/rhinocommon/rhino.geometry.revsurface/create

1 Like

Oh, thank you for your assistance, Iā€™m much obliged! This is my carelessness