surface flattening

Have some feature requests, feedback, cool stuff to share, or want to know where FreeCAD is going? This is the place.
Forum rules
Be nice to others! Read the FreeCAD code of conduct!
User avatar
looo
Veteran
Posts: 3941
Joined: Mon Nov 11, 2013 5:29 pm

Re: surface flattening

Post by looo »

A little video for surface flattening, also including the basic of conda... And yes, I know this can be improved a lot :D

https://vimeo.com/286858668
UR_
Veteran
Posts: 1354
Joined: Tue Jan 03, 2017 8:42 pm

Re: surface flattening

Post by UR_ »

Works really smooth.

GIF.gif
GIF.gif (779.79 KiB) Viewed 2245 times

Had two suggestions immediately :lol:

- why not preserve inner mesh from flattened shape, just for visiual checks, how much distortion was introduced by flattening and where to look for.
Perhaps some homebrew macros can be written to get some analysis in this regard.

- what's the official workflow to cut circular closed faces (like the one in example) to get an flatable mesh.
Should mesh be cut and how, or better the source shape?
For more complex faces, I think there is more than one cut needed, to get usable results

file:
manifold.FCStd
(409.83 KiB) Downloaded 77 times

done with:
OS: Windows 10
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.18.14575 (Git)
Build type: Release
Branch: master
Hash: a624fee2c27bbbb869df6a8ce40438953a282a8c
Python version: 3.6.6
Qt version: 5.6.2
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: German/Germany (de_DE)
User avatar
looo
Veteran
Posts: 3941
Joined: Mon Nov 11, 2013 5:29 pm

Re: surface flattening

Post by looo »

thanks for the feedback.
UR_ wrote: Mon Sep 10, 2018 6:28 pm - why not preserve inner mesh from flattened shape, just for visiual checks, how much distortion was introduced by flattening and where to look for.
Perhaps some homebrew macros can be written to get some analysis in this regard.
[/quote]

yes, I guess it would be best to add the boundary extraction function as a own command. It is maybe useful also for other tasks.
- what's the official workflow to cut circular closed faces (like the one in example) to get an flatable mesh.
Should mesh be cut and how, or better the source shape?
For more complex faces, I think there is more than one cut needed, to get usable results
yes, this is still a problem. I haven't found a solution for this. Somehow seams on closed surfaced have to be defined and applied to meshes. The only workaround right now is adding a little gap by boolean-operations.
User avatar
microelly2
Veteran
Posts: 4688
Joined: Tue Nov 12, 2013 4:06 pm
Contact:

Re: surface flattening

Post by microelly2 »

looo wrote: Thu Sep 06, 2018 12:36 pm A little video for surface flattening, also including the basic of conda... And yes, I know this can be improved a lot :D

https://vimeo.com/286858668
is it possible to get a visualization of the forces on the flattened surface? Maybe this is a way to see where to add a seam and add material to relax the stress.
User avatar
looo
Veteran
Posts: 3941
Joined: Mon Nov 11, 2013 5:29 pm

Re: surface flattening

Post by looo »

microelly2 wrote: Tue Sep 11, 2018 9:03 am
looo wrote: Thu Sep 06, 2018 12:36 pm A little video for surface flattening, also including the basic of conda... And yes, I know this can be improved a lot :D

https://vimeo.com/286858668
is it possible to get a visualization of the forces on the flattened surface? Maybe this is a way to see where to add a seam and add material to relax the stress.
Yes it shouldn't be too much work to visualize the internal forces (sxx, syy, sxy) or area-changes. I guess a simple pivy-mesh would be the easiest way. But maybe this could be integrated into a fem-pipeline. So adding this to the mesh-design workbench seems to be a bit of a duplicated work?
User avatar
-alex-
Veteran
Posts: 1856
Joined: Wed Feb 13, 2019 9:42 pm
Location: France

Re: surface flattening

Post by -alex- »

Great developpement! Any news about this surface flattening algorythm? Maybe some macro exist? That would be great :)
User avatar
looo
Veteran
Posts: 3941
Joined: Mon Nov 11, 2013 5:29 pm

Re: surface flattening

Post by looo »

-alex- wrote: Sat Mar 02, 2019 7:17 pm Great developpement! Any news about this surface flattening algorythm? Maybe some macro exist? That would be great :)
It's included in the FreeCAD-source, but there are only two cammands in mesh-part menu to unwrap meshes and surfaces. Maybe one day I have some time to work on this again. Currently other projects are more important.
User avatar
-alex-
Veteran
Posts: 1856
Joined: Wed Feb 13, 2019 9:42 pm
Location: France

Re: surface flattening

Post by -alex- »

Thanks for your reply. I'll try those tools when they will be available in standard windows builds 32bits.


OS: Windows 10
Word size of OS: 32-bit
Word size of FreeCAD: 32-bit
Version: 0.18.16028 (Git)
Build type: Release
Branch: master
Hash: 9079de7516eca945587e18f6076ec74eb7bd043c
Python version: 2.7.14
Qt version: 4.8.7
Coin version: 4.0.0a
OCC version: 7.2.0
Locale: French/France (fr_FR)
User avatar
looo
Veteran
Posts: 3941
Joined: Mon Nov 11, 2013 5:29 pm

Re: surface flattening

Post by looo »

hmm, 32 bit is a bit difficult I guess. I am not sure if there will be a python3 32-bit version of freecad. @sgrogan what do you think?
sgrogan wrote: ping
User avatar
sgrogan
Veteran
Posts: 6499
Joined: Wed Oct 22, 2014 5:02 pm

Re: surface flattening

Post by sgrogan »

looo wrote: Mon Mar 04, 2019 9:59 pm hmm, 32 bit is a bit difficult I guess. I am not sure if there will be a python3 32-bit version of freecad. @sgrogan what do you think?
Yes, 32 bit is frustrating. I am trying to use an old conda 32 bit environment, that used to work but doesn't any longer, to get Py3.

For the Python 2.7, VS2013 x64 builds this compiles with libboost-python, I get errors for x32. I will look for the thread where I posted the errors. I have not tried replacing libboost-python with pybind11 in the VS2013 builds, I think I need to update eigen3 to make this work?
"fight the good fight"
Post Reply