Welcome to the Onshape forum! Ask questions and join in the discussions about everything Onshape.
First time visiting? Here are some places to start:- Looking for a certain topic? Check out the categories filter or use Search (upper right).
- Need support? Ask a question to our Community Support category.
- Please submit support tickets for bugs but you can request improvements in the Product Feedback category.
- Be respectful, on topic and if you see a problem, Flag it.
If you would like to contact our Community Manager personally, feel free to send a private message or an email.
Advanced Non-Uniform Scale Feature
leon_poot
Member, Developers Posts: 87 ✭✭✭
Here and there I've seen threads or posts about the need for a non-uniform scale feature.
I've written a little feature in FeatureScript capable of scaling in any chosen direction or set of directions.
Choice between:
It's far from perfect, the script has quite some clutter, i'm sure I have taken some detours and is has too many if/else statements.
But if you find it useful: have a copy, or import it to your collection of FS features. If you have any input for me, or tips and tricks on how to improve; all the better, do let me know!
https://cad.onshape.com/documents/c3f3651d28491d28eefba7d3/v/167ba220d329f5bec671e716/e/dbc28ecb5a20b4bfa14fc748
Cheers /Leon
Edit updated screenshots, info and version link
I've written a little feature in FeatureScript capable of scaling in any chosen direction or set of directions.
Choice between:
- Uniform scaling; in the standard coordinate system
- Non-uniform scaling; in the standard coordinate system
- Scaling in one direction; one direction query, one scale factor query
- Scaling in three directions; one or two direction queries (second will default perpendicular to the first until queried),
the third direction will be perpendicular to both, one scale factor query for each direction
- Keep Tools Boolean for keeping the original bodies and scaling a copy
- Use Entity Centre Boolean for using the calculated centroid (centre of surrounding box) or
- Feature Type choice between Feature or Entity queries. Not entirely sure whether Feature Scale works as it should.
So far it seems to work with bodies, faces, wires, and points (for the latter two you'll need to specify a reference point)
It's far from perfect, the script has quite some clutter, i'm sure I have taken some detours and is has too many if/else statements.
But if you find it useful: have a copy, or import it to your collection of FS features. If you have any input for me, or tips and tricks on how to improve; all the better, do let me know!
https://cad.onshape.com/documents/c3f3651d28491d28eefba7d3/v/167ba220d329f5bec671e716/e/dbc28ecb5a20b4bfa14fc748
Cheers /Leon
Edit updated screenshots, info and version link
"A common mistake that people make when trying to design something completely foolproof is to underestimate the ingenuity of complete fools." - Douglas Adams, Mostly Harmless
Tagged:
6
Comments
I just pieced together a bunch of small little things I had together with some bits from the forum, turned out alright it seems.
It works on points and wires, and sketches as well when using Feature Scale (forgot to put that in the version above).
I'll see if I can update the post sometime with screenshots and more info when I have the time for it / if necessary, though I believe the UI is fairly straight-forward. done
This might be a tad late, but I added the csys option now anyways.
New version:
https://cad.onshape.com/documents/c3f3651d28491d28eefba7d3/v/b5b79e36ef390264d2763eaf/e/dbc28ecb5a20b4bfa14fc748
This should really be a standard feature.
This one for example:
https://forum.onshape.com/discussion/5345/non-uniform-scale-tool-improvement-request
Will the built-in variant allow mate connectors as directional input? Gotta admit I tend to use local coordinate systems for just about anything in CAD:
IR for AS/NZS 1100
IR for AS/NZS 1100
Another possible solution is to build in a scaling factor using variables. Create a number variable #x and set it equal to 1. When you create and dimension your sketch, add "*#x" to the end of all your dimensions (or "#x*" to the beginning). Now, if you change #x, you will be scaling your whole sketch.
IR for AS/NZS 1100
Cheers,
Owen S.
HWM-Water Ltd
IR for AS/NZS 1100
Just remember to toggle "Keep tool" (yes, that's a bug.)
https://cad.onshape.com/documents/67cbb8f46b26b814e3c888d8/w/4e141b8447600e837be432a4/e/d6fa430585027cc3a96a11f6?renderMode=0&uiState=65db4de6c4c31561320a6e83