I have created a centreline from a blood vessel segment. I want to export the centreline as an STL or OBJ file, so that I can import it into Fusion and use it as a path to extrude along. (Needing to 3d print this specific blood vessel. I know previous advice stated to use the markups for the models extension. However, that 3d model is not the correct diameter, nor is it hollow. Furthermore, upon import to Fusion, I can’t edit the vessel (even after converting to a mesh) to make it hollow. Is there any advice to achieve my goal of exporting the centreline? (mrk.json, .json and .fcsv can’t be read in Fusion)
If Autodesk Fusion 360 supports import of a curve from any open file format, then you can ask any chatbot to write that file format.
For example, my prompt to ChatGPT:
Write python script that I can run in 3D Slicer that exports control points of a markups curve into a CSV format that Autodesk Fusion 360 can read as a curve.
This is the code it generated:
import csv
import slicer
# --- User settings ---
outputFile = r"C:/Temp/curve_points.csv" # Change path as needed
markupsNodeName = "OC" # Name of your Markups Curve node in Slicer
# ---------------------
# Get the markups node
markupsNode = slicer.util.getNode(markupsNodeName)
nPoints = markupsNode.GetNumberOfControlPoints()
# Open CSV file for writing
with open(outputFile, "w", newline="") as csvfile:
writer = csv.writer(csvfile)
# Write header for Fusion 360 (X,Y,Z)
writer.writerow(["X", "Y", "Z"])
# Write each control point
for i in range(nPoints):
ras = [0.0, 0.0, 0.0]
markupsNode.GetNthControlPointPosition(i, ras)
# Export in millimeters (Fusion 360 expects mm)
writer.writerow(ras)
print(f"✅ Exported {nPoints} control points from '{markupsNodeName}' to {outputFile}")
I’ve tried it and it works flawlessly. If you want the points in LPS coordinate system (probably you do) or you want to get the dense curve points, not just the control points, then you can ask the chatbot to update the code accordingly (I’ve tested and it generates correct code). You can also ask the chatbot to create a simple GUI or run this operation on many files.