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.
Scaling a spline
Caspar
Member Posts: 17 ✭✭
I'm trying to scale a spline (and image) about an origin/base point so that the red point of the spline passes through the yellow point. I'd like the spline and image to resize about the origin without distorting when I subsequently move the yellow point. Can't think of a way to constrain the spline or image to achieve this!
0
Best Answer
-
Jake_Rosenfeld Moderator, Onshape Employees, Developers Posts: 1,646It's possible that the Measure Distance custom feature could help you here:
https://cad.onshape.com/documents/572b968ce4b07aad125dbaaf/v/08093fef6c4d4f330f24dd19/e/b40df94c5081948fe8195e81
This custom feature lets you pick two entities and stores the min or max distance between them into a variable.
The workflow could be something like:- Extrude a surface from your sketch
- Use measure distance to find the distance between the extents of your (now extruded) spline
- Use measure distance to find the distance between the two reference points
- Scale with a scale factor of #DesiredDistance / #CurrentDistance
How to use custom features (see 'Start Using Custom Features' video):
https://www.onshape.com/featurescript
Part Studio variables:
https://cad.onshape.com/help/Content/variable.htm
Jake Rosenfeld - Modeling Team5
Answers
You can dimension the image using the standard dimension tool on one of its bounding box edges, but most likely you will have to redraw the spline (as it will not rescale with that dimension).
If you're happy with your spline and do not want to redraw it, you could leave the sketch how it is, extrude it (either as a surface or a solid) and then use the 'Scale uniformly' option of the transform feature:
https://cad.onshape.com/help/Content/transform.htm
I was hoping that I'd be able to scale all the elements between two defined points, not dimension the sketch (or apply a scale factor to the surface) as this would only be approximate and wouldn't update if other elements of the drawing are moved.
I also tried offsetting the spline but couldn't select the top of the vertical line as the 'through' point.
https://cad.onshape.com/documents/572b968ce4b07aad125dbaaf/v/08093fef6c4d4f330f24dd19/e/b40df94c5081948fe8195e81
This custom feature lets you pick two entities and stores the min or max distance between them into a variable.
The workflow could be something like:
- Extrude a surface from your sketch
- Use measure distance to find the distance between the extents of your (now extruded) spline
- Use measure distance to find the distance between the two reference points
- Scale with a scale factor of #DesiredDistance / #CurrentDistance
Then you can change the original sketch and it will always update accordingly.How to use custom features (see 'Start Using Custom Features' video):
https://www.onshape.com/featurescript
Part Studio variables:
https://cad.onshape.com/help/Content/variable.htm
https://cad.onshape.com/documents/77baa8153589a7fc5f289829/w/cffd0f2a7077380d5378a885/e/d3174bf5315e6aafcb889367