Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Get the number of control points from "Spline01" and the pointpoints' s positions. Print the positions to the "Messages" panel:

Code Block
languagepy
# Get "Spline01" and its number of control points
spline = scene.getSpline("Spline01")
controlPoints = spline.getNumberOfControlPoints()
 

# Loop through the control points and print out their positions
for i in range(0, controlPoints):
	pointPosition = spline.getControlPointPosition(i)
	scene.message(str(pointPosition))