In Design ProductType we have Design::rootComponent() method; is there any similar API in CAM to get flat model?

In Design ProductType we have Design::rootComponent() method; is there any similar API in CAM to get flat model?

Anonymous
Not applicable
650 Views
2 Replies
Message 1 of 3

In Design ProductType we have Design::rootComponent() method; is there any similar API in CAM to get flat model?

Anonymous
Not applicable

Hi,

@BrianEkins 

@MattWynn 

 

Below mentioned methods are not documented at https://help.autodesk.com/view/fusion360/ENU/?guid=GUID-CACDFC5C-5339-4A9A-A9C3-3F645AC3A3D0

 

// Returns the occurrence that references the design root component in the CAM product.

core::Ptr<fusion::Occurrence> designRootOccurrence() const;

 

// Returns a read-only list of flat pattern occurrences in CAM product.

core::Ptr<fusion::OccurrenceList> flatPatternOccurrences() const;

 

We can get valid Occurrence for designRootOccurrence but when method flatPatternOccurrences is called it always returns empty OccurrenceList. We tried it for different models but could not get valid results. Are we missing something here? Can you please let us know how we can query root occurrence in CAM?

Accepted solutions (2)
651 Views
2 Replies
Replies (2)
Message 2 of 3

MattWynn
Alumni
Alumni
Accepted solution

If things are not documented they are not guaranteed to work.

I have no experience using the CAM API, but AFAIK there is no way to get sheet metal flat patterns from Fusion API.


Matt Wynn
Senior Manager, Software Development, Fusion Fabrication
Message 3 of 3

BrianEkins
Mentor
Mentor
Accepted solution

Matt's correct.  Anything not documented is not supported, which means it may not work and could go away at any time. There is still a lot of functionality that's missing in the CAM API. Hopefully, it will be enhanced in the not to distant future.

---------------------------------------------------------------
Brian Ekins
Inventor and Fusion 360 API Expert
Website/Blog: https://EkinsSolutions.com