I have a workflow where I am converting a best-fit cylinder into a cylinder-shaped cloud
Doing this in the UI is just a matter of selecting the cylinder and choosing Extract > Cloud > Extract Cloud
I am trying to script this action, but I am not finding an obvious function which does this
Any help much appreciated
How to script "Extract Cloud" on geometry (a cylinder)?
- geomontgomery
- V.I.P Member
- Posts: 186
- Joined: Thu Sep 13, 2018 3:23 pm
- 5
- Full Name: George Montgomery
- Company Details: ECE Design
- Company Position Title: Support Manager
- Country: USA
- Linkedin Profile: Yes
- Has thanked: 20 times
- Been thanked: 48 times
Re: How to script "Extract Cloud" on geometry (a cylinder)?
Check out the git for published scripts https://github.com/Cyclone3DR/Scripts
While I don't think there's a cylinder extraction script, those scripts above may give you inspiration on how to build your own.
Fyi, Cyclone model has a built in script to extract cylinders/pipe under Create Object > Filter Pipes
While I don't think there's a cylinder extraction script, those scripts above may give you inspiration on how to build your own.
Fyi, Cyclone model has a built in script to extract cylinders/pipe under Create Object > Filter Pipes
- gilles_3DR
- V.I.P Member
- Posts: 235
- Joined: Mon Dec 08, 2014 11:41 am
- 9
- Full Name: Gilles Monnier
- Company Details: Hexagon
- Company Position Title: 3DR Technical Manager
- Country: France
- Linkedin Profile: Yes
- Has thanked: 2 times
- Been thanked: 28 times
Re: How to script "Extract Cloud" on geometry (a cylinder)?
Hi,
the function you are looking for is SCloud.Extract(Array< SComp>, Number, Boolean)
Quick snippet of how to use it:
the function you are looking for is SCloud.Extract(Array< SComp>, Number, Boolean)
Quick snippet of how to use it:
Code: Select all
var theCyl = SCylinder.All()[0];
var theCloud = SCloud.Extract([theCyl], 10, false).Cloud;
theCloud.AddToDoc();