PartDesign Loft issue in version 0.20

Post here for help on using FreeCAD's graphical user interface (GUI).
Forum rules
and Helpful information
IMPORTANT: Please click here and read this first, before asking for help

Also, be nice to others! Read the FreeCAD code of conduct!
Post Reply
darius.m
Posts: 21
Joined: Fri Nov 15, 2019 11:55 pm

PartDesign Loft issue in version 0.20

Post by darius.m »

Hello everyone.
I came across something that I think is an issue with Part Design - Loft.
I've included below all details regarding the FreeCAD version that I'm using.

I'm also attaching here a screenshot and a FCStd file in which the issue can be reproduced.

What I'm trying to do:
1. Create a Part and a Body in the Part.
2. Create a Sketch in the Body and attach it to the Body's XY Plan
3. This sketch contains (I'll refer to it as Sketch A):
- 4 concentric circles; I'll refer to them as C1, C2, C3, C4 where C1 is the inner one and C4 is the outer one.
- 8 lines that connect C2 and C3 as 4 pair of lines, 2 vertical and 2 horizontal.
- Basically this looks like a cart wheel with 4 spokes.
4. Create a DatumPlane attached to the Body's XY plane, offset in Z by 5mm.
5. Create a New Sketch in the Body, attached to the DatumPlane.
6. This sketch contains (I'll refer to it as Sketch B):
- Everything from Sketch A, but replace C1 with a square.
- No CarbonCopy from Sketch A, just manually re-do everything. Some dimensions may slightly vary.
- This would also look like a cartwheel with 4 spokes, but the center "hole" is now square.

For steps 1-6 please see the screenshot as it will probably clarify what I'm trying to describe.

7. In PartDesign Workbench, select the two sketches and click on the "Additive Loft" button.

Expected result after step 7:
- A shape that looks like a 5mm thick cartwheel with 4 spokes, but the center hole gradually goes from circle to square.

Actual result after step 7:
- Only part (1/2 or 1/3 and something none) of the resulting shape looks like expected, everything else is all twisted.
- A better description would be that the AdditiveLoft tool appears to not connect the right vertices from Sketch A to Sketch B.

---

I'm wondering if I'm doing something incorrect when using the AdditiveLoft tool, does anyone have any insight into this?
I tried with simpler shapes and it works ok - for example just simple discs, either only the outside disc of the weel or only the "hub" of the wheel.

I can confirm it works fine even if Sketch A is 2 concentric circles and Sketch B is a square in a circle.
However it doesn't work when the spokes are there connecting the outside pair with the inside pair.

---

I did search for more information on google and also on this forum and I only found issues or questions related to "how to twist a loft".

---


Screenshot (Wireframe):
Loft-issue.jpg
Loft-issue.jpg (593.66 KiB) Viewed 578 times
Sketches are displayed white and the loft is orange.

Screenshot(flat lines):
Loft-issue-1.jpg
Loft-issue-1.jpg (514.83 KiB) Viewed 578 times
FCStd file:
LoftIssue.FCStd
(45.93 KiB) Downloaded 10 times

FreeCad version info:
Note: I copied it from FreeCad -> Help -> About Freecad but the OS is wrong.
I'm on Windows 11 Pro 21H2 22000.856

Code: Select all

OS: Windows 10 Version 2009
Word size of FreeCAD: 64-bit
Version: 0.20.29177 (Git)
Build type: Release
Branch: releases/FreeCAD-0-20
Hash: 68e337670e227889217652ddac593c93b5e8dc94
Python 3.8.10, Qt 5.15.2, Coin 4.0.1, Vtk 8.2.0, OCC 7.6.2
Locale: English/United States (en_US)
Installed mods: 
  * fasteners 0.3.49
  * ThreadProfile 1.82.0
User avatar
Vincent B
Veteran
Posts: 4735
Joined: Sun Apr 05, 2015 9:02 am
Location: La Rochelle, France

Re: PartDesign Loft issue in version 0.20

Post by Vincent B »

Did you tried to make the center hole after the main loft?
chrisb
Veteran
Posts: 54224
Joined: Tue Mar 17, 2015 9:14 am

Re: PartDesign Loft issue in version 0.20

Post by chrisb »

Loft works best if you have the same number of segments in all sections. Making the circle in Sketch A from 4 arcs gives you better control over the seams.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
darius.m
Posts: 21
Joined: Fri Nov 15, 2019 11:55 pm

Re: PartDesign Loft issue in version 0.20

Post by darius.m »

Vincent B wrote: Fri Aug 19, 2022 6:51 pm Did you tried to make the center hole after the main loft?
I did not try it that way, you mean like a substractive loft? I'm not completely sure, but it could work, thanks.

I'm not sure because I have this issue as part of another design where:
- I have two sketches at a parameterized distance between them
- I do a pad on each sketch, with the dimension being parameterized
- Then I create another body and add 2 sketches and do carbon copies of the original sketches.
- Now I'd like to be able in this new body to create a loft between the two CarbonCopied sketches, that in the overall design would connect the two already existing "faces".

By "connect" I mean that when exported as stl it would be a single solid.

Until I find a solution to this, I'll try to do some changes in that file and its parameters that would allow me to try what you recommended ( a substractive loft)

chrisb wrote: Fri Aug 19, 2022 6:58 pm Loft works best if you have the same number of segments in all sections. Making the circle in Sketch A from 4 arcs gives you better control over the seams.
It's the first thing I tried, but it results in a somewhat similar incorrect shape. Almost doesn't seem to have any effect.

[Edit] It's actually a bit worse:
Loft-issue-witharcs-1.jpg
Loft-issue-witharcs-1.jpg (502.13 KiB) Viewed 535 times

As an Update - I've also been able to reproduce this on the Link branch, so it is not a new issue.
Last edited by darius.m on Fri Aug 19, 2022 7:08 pm, edited 2 times in total.
User avatar
Shalmeneser
Veteran
Posts: 9560
Joined: Wed Dec 23, 2020 12:04 am
Location: Fr

Re: PartDesign Loft issue in version 0.20

Post by Shalmeneser »

Loft and Pipe are sensible tools :
* https://wiki.freecadweb.org/PartDesign_ ... Loft#Notes
* https://wiki.freecadweb.org/PartDesign_ ... Pipe#Notes

You should draw the 2 sketches 'in the same order'.
User avatar
Shalmeneser
Veteran
Posts: 9560
Joined: Wed Dec 23, 2020 12:04 am
Location: Fr

Re: PartDesign Loft issue in version 0.20

Post by Shalmeneser »

KISS : Keep It Stupidly Simple
Attachments
Capture d’écran 2022-08-19 211234.jpg
Capture d’écran 2022-08-19 211234.jpg (71.17 KiB) Viewed 531 times
LoftIssue_SHALM.FCStd
(49.99 KiB) Downloaded 6 times
darius.m
Posts: 21
Joined: Fri Nov 15, 2019 11:55 pm

Re: PartDesign Loft issue in version 0.20

Post by darius.m »

Shalmeneser wrote: Fri Aug 19, 2022 7:14 pm KISS : Keep It Stupidly Simple
Thank you, I'm going to use Additive and Substractive Lofts to achieve the result that I'm looking for. The file that you have attached is very hepful

Shalmeneser wrote: Fri Aug 19, 2022 7:03 pm You should draw the 2 sketches 'in the same order'.
Thanks, I'm assuming you're referring to this:
If the sketch has inner geometry, i.e. the loft is supposed to have holes, then the order in which the sketch geometry is created, should be the same for all sections: Either start all sections with the inner geometry or start them all with the outer. Otherwise an invalid loft can be created where inner and outer walls cross.
I haven't seen that section before, but I've tried that also. Basically I did the same operations in the same order in both sketches, going as far as setting the dimensions in the same order.

It didn't work but even if it did it's not something I'd use because when I go back to edit one of the sketches it can throw all that order out the window.

My lesson from here is not to use Additive Loft for anything that is supposed to have holes in it - better use combinations of Additive and Substractive lofts.

Thank you!
User avatar
Shalmeneser
Veteran
Posts: 9560
Joined: Wed Dec 23, 2020 12:04 am
Location: Fr

Re: PartDesign Loft issue in version 0.20

Post by Shalmeneser »

I'm assuming you're referring to this ...
Yes, but also everything clockwise (or anticlockwise).
Loft / Pipe should work upon the simpliest sketches.
darius.m
Posts: 21
Joined: Fri Nov 15, 2019 11:55 pm

Re: PartDesign Loft issue in version 0.20

Post by darius.m »

Shalmeneser wrote: Fri Aug 19, 2022 7:28 pm Yes, but also everything clockwise (or anticlockwise).
Loft / Pipe should work upon the simpliest sketches.
I've tried also with the C1 being circles in both sketches (as opposed to circle -> square) but I got the same result.

Perhaps an idea would be to have some sort of functionality where the user can select the vertices and/or edges that should be connected, or at least some of them.

Would this be possible in the current codebase?

---

[Edit]: I just want to say this - the support I got here is the best support I've gotten in probably forever - and I'm including here free, open source, commercial, closed source, paid or not.
Thank you!
Post Reply