How to get the bevel diameter then remove bevel or extruded value on curve with a script addon?
I have a scene with many objects including some cables made with bezier curve type poly with bevel. The curves are cables with the proper diameter and length, the cable's Diam is done with the bevel depth.
So I started a script for getting all curves and for each curve I made a copy.
Now how do I get the data from the copied object?
First I need to get the size or diameter of the bevel, then remove the bevel on the curve, and after that I can convert to a mesh line and find the length.
Here is beginning of script for this
for i in obj_sel:
if i.type=='CURVE':
print ('name = ', i.name,'Type',i.type )
ob = i.copy()
ob.location.x = 10
ob.data = ob.data.copy()
bpy.context.scene.objects.link(ob)
bpy.context.scene.update()
print ('new ob name new curve =', ob.name)
# get diameter of bevel for that curve and save it
# Make a copy of the curve then ?????
# Remove the bevel
# convert curve to mesh
bpy.ops.object.convert( target='MESH')
print ('new ob name new mesh line =', ob.name)
MESHNAME = ob.name
ect..
for more details see following thread
If a file sample is needed let me know on that thread and I can upload one
thanks for any help happy blendering