Message 1 of 2
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
I want to create a square pipe using PipeFeatures. But I am unable to find an example related to it.
Solved! Go to Solution.
I want to create a square pipe using PipeFeatures. But I am unable to find an example related to it.
Solved! Go to Solution.
Hi @ph0en1x01 .
The API does not provide a way to create pipe features.
I believe it is possible to create the same shape using sweeps.
If you really want to create a pipe feature, the only way is to use the text command.
By slightly modifying the initPipe function in the sample here, it is possible to create a square pipe.
https://forums.autodesk.com/t5/fusion-360-api-and-scripts/use-textcommands/m-p/9645688
def initPipe(path):
sels :adsk.core.Selections = _ui.activeSelections
sels.clear()
sels.add(path)
txtCmds = [
u'Commands.Start PrimitivePipe',
u'Commands.SetDouble SWEEP_POP_ALONG 1.0',
u'Commands.SetString infoSectionType infoRectangular',
u'Commands.SetDouble SectionRadius 0.5',
u'Commands.SetBool PIPE_HOLLOW_OPTION 1',
u'Commands.SetDouble SectionThickness 0.1',
u'NuCommands.CommitCmd'
]
for cmd in txtCmds:
_app.executeTextCommand(cmd)
sels.clear()
However, we recommend using sweeps.