# blender python: evaluate extruded curve points

I need to find coordinates of points extruded from blender's bezier curve with python. All I know right now is how to evaluate each point on the curve(mathutils.geometry.interpolate_bezier) but I don't know how to find the perpendicular vector with Spline's tilt.

Basically, I need to find a perpendicular vector with the original vector and tilt in each curve vertex. How do I do that in python?

So far I've only gotten the spline points but not the extrusion, here:

import bpy
import mathutils
interp = mathutils.geometry.interpolate_bezier

class DummyOp(bpy.types.Operator):
bl_idname = "object.get_bezier"
bl_label = "Extract Bezier Points"

def execute(self, context):
ob = context.object
dat = ob.data
bzp = dat.splines[0].bezier_points
points=interp(bzp[0].co, bzp[0].handle_right, bzp[1].handle_left, bzp[1].co, dat.resolution_u+1)
print(f"So far I can only extract this data:\n{dat.resolution_u},\nCurve points:")
for p in points:
print(p)
return {'FINISHED'}

def register():
bpy.utils.register_class(DummyOp)

def unregister():
bpy.utils.unregister_class(DummyOp)

if __name__ == "__main__":
register()

bpy.ops.object.get_bezier()


• I know this -> bpy.ops.object.convert(target='MESH', keep_original=False) method exists, but I was hoping for a cleaner solution without using bpy.ops. I will use this method for now – CompressedWizard Apr 8 at 18:12