Replies: 2 comments
|
Solved using this: https://docs.cadwork.com/projects/cwapi3dpython/en/latest/examples/geometry/ |
This is best approach for this 👍 |
|
Solved using this: https://docs.cadwork.com/projects/cwapi3dpython/en/latest/examples/geometry/ |
This is best approach for this 👍 |
Uh oh!
There was an error while loading. Please reload this page.
Hi everyone,
I am developing a Python script to automate attribute assignment for rectangular bars. To make this work, I need to automatically differentiate which of these members are acting as columns and which ones are beams.
My current idea is to analyze their spatial orientation: if the longitudinal axis of the member is aligned (or nearly aligned) with the global Z-axis, the script should classify it as a column. Otherwise, it should be classified as a beam.
I would love to get your advice on this:
Is this the best approach when using the cadwork API, or is there a native method, member type, or internal attribute that already makes this distinction directly?
If analyzing the spatial orientation is indeed the way to go, what is the cleanest way in the API to retrieve the longitudinal axis direction or the geometric orientation of a member?
I would highly appreciate any suggestions, best practices, or guidance on which API functions are best suited to query member geometry or direction vectors.
Thank you so much for your help!
All reactions