solved: failed loft (v.19)

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!
byakk0
Posts: 83
Joined: Fri Sep 04, 2020 7:38 pm

solved: failed loft (v.19)

Post by byakk0 »

I'm at a loss here.
Trying to loft a series of ovals from a padded/fileted base oval.
As you can see from the pics it initially renders something like a bird body, then some incomplete thing. Its supposed look similar to red circled base of the mirror below.
I select the face of the oval pad I want to start with, then select the ovals in order, lowest to highest, and click the yellow loft icon (part design WB)
(for those who look at my file, the oval sketch order is 21, 18, 19, 20)
I've managed this once successfully on a different computer, but it was just a quick test to see if I could, and I didn't save the file.
I'm not sure why it was successful once and failed this time. The only difference is dimensions, that I can see.

Thanks again.
mirrorStand.fcstd
(46.65 KiB) Downloaded 25 times
standProblem1.png
standProblem1.png (135.16 KiB) Viewed 1616 times

OS: Windows 10 Version 2004
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.24267 +99 (Git)
Build type: Release
Branch: Branch_0.19.3
Hash: 6530e364184ce05ccff39501e175cf2237e6ee4b
Python version: 3.8.6+
Qt version: 5.15.2
Coin version: 4.0.1
OCC version: 7.5.3
Locale: English/United States (en_US)
Last edited by byakk0 on Thu Jan 20, 2022 4:42 pm, edited 1 time in total.
~~Hazen
TheMarkster
Veteran
Posts: 5505
Joined: Thu Apr 05, 2018 1:53 am

Re: failed loft

Post by TheMarkster »

I don't know why, but it seems OCCT does not like working with these ellipses. If you go into each of the sketches and convert the ellipse edges to bsplines, then it works. This file is likely to crash FreeCAD for Linux and probably Mac users. But Windows is a bit more robust and you only get an error in the report view.
Snip macro screenshot-b3d231.png
Snip macro screenshot-b3d231.png (88.27 KiB) Viewed 1568 times
Snip macro screenshot-212ab4.png
Snip macro screenshot-212ab4.png (59.14 KiB) Viewed 1568 times
But the solid produced does fail checkgeometry.
Snip macro screenshot-d4980d.png
Snip macro screenshot-d4980d.png (84.52 KiB) Viewed 1568 times
byakk0
Posts: 83
Joined: Fri Sep 04, 2020 7:38 pm

Re: failed loft

Post by byakk0 »

Thanks for looking at it. I'll that a go.
TheMarkster wrote: Wed Jan 19, 2022 6:48 am But the solid produced does fail checkgeometry.
I plan on 3D printing. does this mean it won't produce a solid print?
~~Hazen
drmacro
Veteran
Posts: 8806
Joined: Sun Mar 02, 2014 4:35 pm

Re: failed loft

Post by drmacro »

byakk0 wrote: Wed Jan 19, 2022 4:23 pm Thanks for looking at it. I'll that a go.
TheMarkster wrote: Wed Jan 19, 2022 6:48 am But the solid produced does fail checkgeometry.
I plan on 3D printing. does this mean it won't produce a solid print?
Use the Mesh workbench to create the mesh. Then use the Mesh Evaluate and repair tool to see if the mesh is valid. If yes, then export the stl.
Star Trek II: The Wrath of Khan: Spock: "...His pattern indicates two-dimensional thinking."
kisolre
Veteran
Posts: 4159
Joined: Wed Nov 21, 2018 1:13 pm

Re: failed loft

Post by kisolre »

So I played a little with that file and found out that the order of the profiles matters. I made the separate sections from top to bottom and the second one works only when made top to bottom. Bottom to top giver this error:
.
LoftOrderError.JPG
LoftOrderError.JPG (79.58 KiB) Viewed 1475 times
.
Is this OCC error or the way data is passed to it? Should it be reported as a bug?

Here is a file with the correct loft created top to bottom:
.
mirrorStand_kiss.fcstd
(75.01 KiB) Downloaded 16 times
.
OS: Windows 8.1 Version 6.3 (Build 9600)
Word size of FreeCAD: 64-bit
Version: 0.20.27100 (Git)
Build type: Release
Branch: master
Hash: b9280ae760182783f74eddc77a114686c4143e00
Python version: 3.8.8
Qt version: 5.15.2
Coin version: 4.0.1
OCC version: 7.5.3
Locale: Bulgarian/Bulgaria (bg_BG)
TheMarkster
Veteran
Posts: 5505
Joined: Thu Apr 05, 2018 1:53 am

Re: failed loft

Post by TheMarkster »

Drmacro beat me to it. I was going to give the same reply. Often there are failures with check geometry that do not necessarily mean the object is not usable in further operations. I see them more as warning flags that there could be potential issues, and if there are, then this could be the culprit. Some errors, such as self-intersections, are almost always indicators that future operations will fail.

The analyze tool in Mesh Design is great for finding problems, not as much great at fixing them. My experience has been it's usually more of a radical surgery than a true fix. Defective bits are removed, leaving a broken object that must then be fixed, for example by filling some holes. I generally prefer to go back into the solid and try to fix it there rather than trying to repair the mesh.

I think it is also worth remarking that you are making the mistake of attaching to faces. This will inevitably lead to ruin as you will run afoul of the topological naming problem in doing so. Better instead to attach to one of the planes, e.g. xy_plane and offset from there. But I don't think this is related to this particular issue with this particular model.
TheMarkster
Veteran
Posts: 5505
Joined: Thu Apr 05, 2018 1:53 am

Re: failed loft

Post by TheMarkster »

I thought I had tried going from the opposite direction, but either I didn't or I had some other user error when I tried it, maybe a bad selection. This is better than converting to bsplines and it also passes check geometry.
User avatar
Shalmeneser
Veteran
Posts: 9443
Joined: Wed Dec 23, 2020 12:04 am
Location: Fr

Re: failed loft

Post by Shalmeneser »

kisolre wrote: Wed Jan 19, 2022 5:34 pm So I played a little with that file and found out that the order of the profiles matters.
I made the separate sections from top to bottom and the second one works only when made top to bottom. Bottom to top ...
... crash.

Code: Select all

OS: Linux Mint 20.3 (MATE/mate)
Word size of FreeCAD: 64-bit
Version: 0.20.27008 (Git) AppImage
Build type: Release
Branch: (HEAD detached at 9162733)
Hash: 91627338a44371fe9a8e815b4900f62558af98a1
Python version: 3.9.9
Qt version: 5.12.9
Coin version: 4.0.0
OCC version: 7.5.3
Locale: French/France (fr_FR)
byakk0
Posts: 83
Joined: Fri Sep 04, 2020 7:38 pm

Re: failed loft

Post by byakk0 »

The following I am typing as I am working, listing what is happening as I try it.

OK, so for selecting the base, the sketches need to be in order then? not just the selection order?

So at this point, I converted to B splines and got the same result.

... (having converted to b splines at this point) I omitted #21 and selecting the top face, so I get a bottom to top progression and initially the loft looks like it will work, but when I press ok I just get weird geometry on just the base and the oval sketches disappear
++When selecting the entire filet, I get 'No valid subelement linked in Part:Feature.

...tried selecting just the ovals. 18,19,20 (in that order) then loft, and nothing. it shows the 3 ovals lofted correctly (yellowish) but when I click OK they disappear and leave the base.

...tried 21,18,19,20, and I got the desired shape. hmmm Is this because #21 is sketched on the face of the base/filet?

The documentation for loft in the wiki makes it seems simpler...did I miss something?

Thanks again. I think I'm making progress of some sort.
~~Hazen
byakk0
Posts: 83
Joined: Fri Sep 04, 2020 7:38 pm

Re: failed loft

Post by byakk0 »

Finally got it to work.
Here's a shot of this project as it sits.

Now I need to figure out how pad or loft the base up to the mirror body. Any suggestions? Or should I make that a new topic.
MirrorNStand.png
MirrorNStand.png (219.62 KiB) Viewed 1348 times
~~Hazen
Post Reply