PartDesign new development, MultiBody and more

About the development of the Part Design module/workbench. PLEASE DO NOT POST HELP REQUESTS HERE!
User avatar
OficineRobotica
Posts: 367
Joined: Thu Feb 21, 2019 8:17 am

Re: PartDesign new development, MultiBody and more

Postby OficineRobotica » Thu Dec 24, 2020 5:24 am

I am also getting a consistent crash simply by closing a sketch from a linked body.
-create a body in a file
-create a new file and link the previous body
-edit a sketch in the linked body
-segfault on closing the sketch
(my linked body is inside a assembly container)

Code: Select all

Program received signal SIGSEGV, Segmentation fault.
#0  /lib/x86_64-linux-gnu/libc.so.6(+0x46210) [0x7f05e72b9210]
#1  0x7f05e96cf738 in Gui::DAG::Model::slotResetEdit(Gui::ViewProviderDocumentObject const&) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib64/libFreeCADGui.so+0x48
#2  /tmp/.mount_FreeCAFPDg81/usr/bin/../lib64/libFreeCADGui.so(+0x46e877) [0x7f05e9429877]
#3  0x7f05e947300f in Gui::Document::_resetEdit() from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib64/libFreeCADGui.so+0x1ff
#4  0x7f05e940b41a in Gui::Application::setEditDocument(Gui::Document*) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib64/libFreeCADGui.so+0x3a
#5  0x7f05e9432b0f in Gui::Application::sResetEdit(_object*, _object*) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib64/libFreeCADGui.so+0x2f
#6  /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libpython3.8.so.1.0(PyCFunction_Call+0xf7) [0x7f05e8dab2e7]
#7  /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libpython3.8.so.1.0(_PyObject_MakeTpCall+0x250) [0x7f05e8d61890]
#8  /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libpython3.8.so.1.0(_PyEval_EvalFrameDefault+0x4ea2) [0x7f05e8defe62]
#9  /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libpython3.8.so.1.0(_PyEval_EvalCodeWithName+0x2e2) [0x7f05e8d5e022]
#10  /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libpython3.8.so.1.0(PyEval_EvalCodeEx+0x44) [0x7f05e8d5ede4]
#11  /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libpython3.8.so.1.0(PyEval_EvalCode+0x1c) [0x7f05e8e1469c]
#12  /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libpython3.8.so.1.0(+0x219ecf) [0x7f05e8e32ecf]
#13  /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libpython3.8.so.1.0(+0x252c44) [0x7f05e8e6bc44]
#14  /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libpython3.8.so.1.0(PyRun_StringFlags+0x7d) [0x7f05e8e6bcdd]
#15  0x7f05e84e69ec in Base::InterpreterSingleton::runString[abi:cxx11](char const*) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib64/libFreeCADBase.so+0x6c
#16  0x7f05e94fdab1 in Gui::Command::_runCommand(char const*, int, Gui::Command::DoCmd_Type, char const*) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib64/libFreeCADGui.so+0x91
#17  0x7f05e94fdc51 in Gui::Command::_doCommand(char const*, int, Gui::Command::DoCmd_Type, char const*, ...) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib64/libFreeCADGui.so+0x101
#18  0x7f049a221b6b in SketcherGui::TaskDlgEditSketch::reject() from /tmp/.mount_FreeCAFPDg81/usr/lib64/SketcherGui.so+0xfb
#19  0x7f05e97c8e3c in Gui::TaskView::TaskView::reject() from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib64/libFreeCADGui.so+0x5c
#20  0x7f05e77d80d2 in QMetaObject::activate(QObject*, int, int, void**) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libQt5Core.so.5+0x780
#21  /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libQt5Widgets.so.5(+0x274d7d) [0x7f05e80ecd7d]
#22  0x7f05e77d80d2 in QMetaObject::activate(QObject*, int, int, void**) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libQt5Core.so.5+0x780
#23  0x7f05e8085360 in QAbstractButton::clicked(bool) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libQt5Widgets.so.5+0x32
#24  /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libQt5Widgets.so.5(+0x20da19) [0x7f05e8085a19]
#25  /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libQt5Widgets.so.5(+0x20e2ae) [0x7f05e80862ae]
#26  0x7f05e808634a in QAbstractButton::mouseReleaseEvent(QMouseEvent*) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libQt5Widgets.so.5+0x88
#27  0x7f05e8017c23 in QWidget::event(QEvent*) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libQt5Widgets.so.5+0x135
#28  0x7f05e7fec83a in QApplicationPrivate::notify_helper(QObject*, QEvent*) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libQt5Widgets.so.5+0xde
#29  0x7f05e7ff10a9 in QApplication::notify(QObject*, QEvent*) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libQt5Widgets.so.5+0x79d
#30  0x7f05e94b63b9 in Gui::GUIApplication::notify(QObject*, QEvent*) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib64/libFreeCADGui.so+0x89
#31  0x7f05e77c1a9c in QCoreApplication::notifyInternal2(QObject*, QEvent*) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libQt5Core.so.5+0x88
#32  0x7f05e7ff0553 in QApplicationPrivate::sendMouseEvent(QWidget*, QMouseEvent*, QWidget*, QWidget*, QWidget**, QPointer<QWidget>&, bool, bool) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libQt5Widgets.so.5+0x283
#33  /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libQt5Widgets.so.5(+0x1af580) [0x7f05e8027580]
#34  /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libQt5Widgets.so.5(+0x1b03d2) [0x7f05e80283d2]
#35  0x7f05e7fec83a in QApplicationPrivate::notify_helper(QObject*, QEvent*) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libQt5Widgets.so.5+0xde
#36  0x7f05e7ff2405 in QApplication::notify(QObject*, QEvent*) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libQt5Widgets.so.5+0x1af9
#37  0x7f05e94b63b9 in Gui::GUIApplication::notify(QObject*, QEvent*) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib64/libFreeCADGui.so+0x89
#38  0x7f05e77c1a9c in QCoreApplication::notifyInternal2(QObject*, QEvent*) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libQt5Core.so.5+0x88
#39  0x7f05e7b68724 in QGuiApplicationPrivate::processMouseEvent(QWindowSystemInterfacePrivate::MouseEvent*) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libQt5Gui.so.5+0x684
#40  0x7f05e7b692f7 in QGuiApplicationPrivate::processWindowSystemEvent(QWindowSystemInterfacePrivate::WindowSystemEvent*) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libQt5Gui.so.5+0x175
#41  0x7f05e7b56020 in QWindowSystemInterface::sendWindowSystemEvents(QFlags<QEventLoop::ProcessEventsFlag>) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libQt5Gui.so.5+0x64
#42  /tmp/.mount_FreeCAFPDg81/usr/plugins/platforms/../../lib/libQt5XcbQpa.so.5(+0x5b1ea) [0x7f05deada1ea]
#43  /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/./libglib-2.0.so.0(g_main_context_dispatch+0x2cb) [0x7f05e3ec5deb]
#44  /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/./libglib-2.0.so.0(+0x55031) [0x7f05e3ec6031]
#45  /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/./libglib-2.0.so.0(g_main_context_iteration+0x2e) [0x7f05e3ec60be]
#46  0x7f05e77f0d23 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libQt5Core.so.5+0x63
#47  0x7f05e77be4d7 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libQt5Core.so.5+0x187
#48  0x7f05e77c234f in QCoreApplication::exec() from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib/libQt5Core.so.5+0x105
#49  0x7f05e9431544 in Gui::Application::runApplication() from /tmp/.mount_FreeCAFPDg81/usr/bin/../lib64/libFreeCADGui.so+0x1794
#50  /tmp/.mount_FreeCAFPDg81/usr/bin/FreeCADLink(+0x446f) [0x558568cd146f]
#51  /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf3) [0x7f05e729a0b3]
#52  /tmp/.mount_FreeCAFPDg81/usr/bin/FreeCADLink(+0x4789) [0x558568cd1789]

And another one on closing the filet task on a linked body. It seems to always hanppen when closing dialogs with either ok or cancel when editing linked bodies.

Code: Select all

Program received signal SIGSEGV, Segmentation fault.
#0  /lib/x86_64-linux-gnu/libc.so.6(+0x46210) [0x7f6c384e4210]
#1  0x7f6c3a8fa734 in Gui::DAG::Model::slotResetEdit(Gui::ViewProviderDocumentObject const&) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib64/libFreeCADGui.so+0x44
#2  /tmp/.mount_FreeCAayeHGI/usr/bin/../lib64/libFreeCADGui.so(+0x46e877) [0x7f6c3a654877]
#3  0x7f6c3a69e00f in Gui::Document::_resetEdit() from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib64/libFreeCADGui.so+0x1ff
#4  0x7f6c3a63641a in Gui::Application::setEditDocument(Gui::Document*) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib64/libFreeCADGui.so+0x3a
#5  0x7f6c3a6b0c42 in Gui::DocumentPy::resetEdit(_object*) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib64/libFreeCADGui.so+0x32
#6  0x7f6c3a6b0ca7 in Gui::DocumentPy::staticCallback_resetEdit(_object*, _object*) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib64/libFreeCADGui.so+0x57
#7  /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libpython3.8.so.1.0(PyCFunction_Call+0xf7) [0x7f6c39fd62e7]
#8  /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libpython3.8.so.1.0(_PyObject_MakeTpCall+0x250) [0x7f6c39f8c890]
#9  /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libpython3.8.so.1.0(_PyEval_EvalFrameDefault+0x4ea2) [0x7f6c3a01ae62]
#10  /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libpython3.8.so.1.0(_PyEval_EvalCodeWithName+0x2e2) [0x7f6c39f89022]
#11  /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libpython3.8.so.1.0(PyEval_EvalCodeEx+0x44) [0x7f6c39f89de4]
#12  /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libpython3.8.so.1.0(PyEval_EvalCode+0x1c) [0x7f6c3a03f69c]
#13  /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libpython3.8.so.1.0(+0x219ecf) [0x7f6c3a05decf]
#14  /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libpython3.8.so.1.0(+0x252c44) [0x7f6c3a096c44]
#15  /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libpython3.8.so.1.0(PyRun_StringFlags+0x7d) [0x7f6c3a096cdd]
#16  0x7f6c397119ec in Base::InterpreterSingleton::runString[abi:cxx11](char const*) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib64/libFreeCADBase.so+0x6c
#17  0x7f6c3a728ab1 in Gui::Command::_runCommand(char const*, int, Gui::Command::DoCmd_Type, char const*) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib64/libFreeCADGui.so+0x91
#18  0x7f6b2518caa0 in void Gui::_cmdDocument<char const (&) [12]>(Gui::Command::DoCmd_Type, App::Document const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, char const (&) [12]) from /tmp/.mount_FreeCAayeHGI/usr/lib64/PartDesignGui.so+0x3f0
#19  0x7f6b2518d98a in PartDesignGui::TaskDlgFeatureParameters::accept() from /tmp/.mount_FreeCAayeHGI/usr/lib64/PartDesignGui.so+0x29a
#20  0x7f6b251bc64d in PartDesignGui::TaskDlgDressUpParameters::accept() from /tmp/.mount_FreeCAayeHGI/usr/lib64/PartDesignGui.so+0x1fd
#21  0x7f6c3a9f3d2c in Gui::TaskView::TaskView::accept() from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib64/libFreeCADGui.so+0x5c
#22  0x7f6c38a030d2 in QMetaObject::activate(QObject*, int, int, void**) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libQt5Core.so.5+0x780
#23  /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libQt5Widgets.so.5(+0x274d73) [0x7f6c39317d73]
#24  0x7f6c38a030d2 in QMetaObject::activate(QObject*, int, int, void**) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libQt5Core.so.5+0x780
#25  0x7f6c392b0360 in QAbstractButton::clicked(bool) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libQt5Widgets.so.5+0x32
#26  /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libQt5Widgets.so.5(+0x20da19) [0x7f6c392b0a19]
#27  /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libQt5Widgets.so.5(+0x20e2ae) [0x7f6c392b12ae]
#28  0x7f6c392b134a in QAbstractButton::mouseReleaseEvent(QMouseEvent*) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libQt5Widgets.so.5+0x88
#29  0x7f6c39242c23 in QWidget::event(QEvent*) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libQt5Widgets.so.5+0x135
#30  0x7f6c3921783a in QApplicationPrivate::notify_helper(QObject*, QEvent*) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libQt5Widgets.so.5+0xde
#31  0x7f6c3921c0a9 in QApplication::notify(QObject*, QEvent*) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libQt5Widgets.so.5+0x79d
#32  0x7f6c3a6e13b9 in Gui::GUIApplication::notify(QObject*, QEvent*) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib64/libFreeCADGui.so+0x89
#33  0x7f6c389eca9c in QCoreApplication::notifyInternal2(QObject*, QEvent*) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libQt5Core.so.5+0x88
#34  0x7f6c3921b553 in QApplicationPrivate::sendMouseEvent(QWidget*, QMouseEvent*, QWidget*, QWidget*, QWidget**, QPointer<QWidget>&, bool, bool) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libQt5Widgets.so.5+0x283
#35  /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libQt5Widgets.so.5(+0x1af580) [0x7f6c39252580]
#36  /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libQt5Widgets.so.5(+0x1b03d2) [0x7f6c392533d2]
#37  0x7f6c3921783a in QApplicationPrivate::notify_helper(QObject*, QEvent*) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libQt5Widgets.so.5+0xde
#38  0x7f6c3921d405 in QApplication::notify(QObject*, QEvent*) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libQt5Widgets.so.5+0x1af9
#39  0x7f6c3a6e13b9 in Gui::GUIApplication::notify(QObject*, QEvent*) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib64/libFreeCADGui.so+0x89
#40  0x7f6c389eca9c in QCoreApplication::notifyInternal2(QObject*, QEvent*) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libQt5Core.so.5+0x88
#41  0x7f6c38d93724 in QGuiApplicationPrivate::processMouseEvent(QWindowSystemInterfacePrivate::MouseEvent*) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libQt5Gui.so.5+0x684
#42  0x7f6c38d942f7 in QGuiApplicationPrivate::processWindowSystemEvent(QWindowSystemInterfacePrivate::WindowSystemEvent*) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libQt5Gui.so.5+0x175
#43  0x7f6c38d81020 in QWindowSystemInterface::sendWindowSystemEvents(QFlags<QEventLoop::ProcessEventsFlag>) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libQt5Gui.so.5+0x64
#44  /tmp/.mount_FreeCAayeHGI/usr/plugins/platforms/../../lib/libQt5XcbQpa.so.5(+0x5b1ea) [0x7f6c2fd451ea]
#45  /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/./libglib-2.0.so.0(g_main_context_dispatch+0x2cb) [0x7f6c350f0deb]
#46  /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/./libglib-2.0.so.0(+0x55031) [0x7f6c350f1031]
#47  /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/./libglib-2.0.so.0(g_main_context_iteration+0x2e) [0x7f6c350f10be]
#48  0x7f6c38a1bd23 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libQt5Core.so.5+0x63
#49  0x7f6c389e94d7 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libQt5Core.so.5+0x187
#50  0x7f6c389ed34f in QCoreApplication::exec() from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib/libQt5Core.so.5+0x105
#51  0x7f6c3a65c544 in Gui::Application::runApplication() from /tmp/.mount_FreeCAayeHGI/usr/bin/../lib64/libFreeCADGui.so+0x1794
#52  /tmp/.mount_FreeCAayeHGI/usr/bin/FreeCADLink(+0x446f) [0x5599334ca46f]
#53  /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf3) [0x7f6c384c50b3]
#54  /tmp/.mount_FreeCAayeHGI/usr/bin/FreeCADLink(+0x4789) [0x5599334ca789]

Code: Select all

OS: KDE neon User Edition 5.20 (KDE//usr/share/xsessions/plasma)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 2020.12.17.23076 +3024 (Git) AppImage
Build type: Release
Branch: LinkStage3
Hash: 560eb2c4645cd548b6f718c645c7af70384ff54c
Python version: 3.8.6
Qt version: 5.12.9
Coin version: 4.0.0
OCC version: 7.4.0
Locale: English/United States (en_US)
User avatar
-alex-
Posts: 838
Joined: Wed Feb 13, 2019 9:42 pm
Location: France

Re: PartDesign new development, MultiBody and more

Postby -alex- » Thu Dec 24, 2020 7:22 am

Thanks again @realthunder for those great features in Partdesign WB.
Just a comment here, also a question:
When using new taper angle option for pad feature, planar faces (basically every faces) becomes Bspline faces:
Pad_taper_angle_leads-to-Bspline-faces.gif
Pad_taper_angle_leads-to-Bspline-faces.gif (260.47 KiB) Viewed 1519 times


Bsplines can lead to some fancy results sometimes, for eg. when meshing the tessellation will be much irregular, or when cutting such Bspline faces you get Bspline lines of course. Anyway, IMHO such behavior is not a big deal, and taper angle option is a very convenient feature, but it leads to several limitations sometimes, it depends the workflow. That's not suitable for sheetmetal workflow for eg. (unfolding algorithm doesn't support Bspline faces).
Is this behavior due to the underlying use of some scaling feature? Is it possible to get the same taper angle feature without this behavior? Without Bspline faces transformation I mean? Or is it a crack nut stuff to get?
Thanks for your attention.

Edit: up ;)
realthunder wrote:ping
Do you think it would be possible to keep the former kind of shape while using taper angle? Does it makes sens in your opinion?
User avatar
-alex-
Posts: 838
Joined: Wed Feb 13, 2019 9:42 pm
Location: France

Re: PartDesign new development, MultiBody and more

Postby -alex- » Fri Jan 22, 2021 12:07 am

Another question:
realthunder wrote:
Tue Mar 17, 2020 10:32 am
...It's easier than I thought, should have done that earlier.

Image

You did this great enhancement which allows to highlight faces of each feature in tree-view. Thank you so much for that!
Do you think that would be possible to do it the opposite way as well? I mean about enabling feature in tree-view by selecting some face of the 3D model in main view area?
That would be a huge enhancement, we could maybe edit directly the relevant feature by RMB on the 3D model. What do you think about such request?
Thank you for your attention.
realthunder
Posts: 1954
Joined: Tue Jan 03, 2017 10:55 am

Re: PartDesign new development, MultiBody and more

Postby realthunder » Mon Jan 25, 2021 12:45 am

-alex- wrote:
Thu Dec 24, 2020 7:22 am
Do you think it would be possible to keep the former kind of shape while using taper angle? Does it makes sens in your opinion?
Not sure about the exact criteria of OCC converting geometry into BSpline based one, but I didn't specifically do anything to make that happen. I followed what's implemented in Part extrusion drafting functionality. It basically copy and move the profile sketch, offset it, and then do a loft using those wires for the extrusion. You can in fact manually perform those steps to reproduce the same result. Maybe it is because the offset operation somehow triggering BSpline conversion in OCC. Offset has always been a troublemaker in OCC. Or maybe it is the loft, you know where the loft can morph a straight line into a curve, which would definitely require a BSpline surface.

-alex- wrote:
Fri Jan 22, 2021 12:07 am
That would be a huge enhancement, we could maybe edit directly the relevant feature by RMB on the 3D model. What do you think about such request?
Thank you for your attention.
That would be ambiguous I am afraid, because the user may actually want to select the 'real' owner object of those geometry, instead of the intermediate feature that generate the selected geometry. In some context, yes, it does make sense. And what you saw in the video demonstrated that capability. When editing the fillet, the selection of the edge or face on the fillet object is being analyzed to deduce the edge index on its base feature in order to modify the fillet edge references.
Try Assembly3 (latest version 0.11) along with my custom build of FreeCAD at here.
And if you'd like to show your support, you can donate through patreon, liberapay, or paypal
User avatar
-alex-
Posts: 838
Joined: Wed Feb 13, 2019 9:42 pm
Location: France

Re: PartDesign new development, MultiBody and more

Postby -alex- » Mon Jan 25, 2021 10:12 pm

realthunder wrote:
Mon Jan 25, 2021 12:45 am
It basically copy and move the profile sketch, offset it, and then do a loft using those wires for the extrusion.
Thanks for your reply and explanation, very interesting.
I'm just an end user, but I guess maybe there is a way to improve this behavior. I'm gonna try to explain despite my bad english:
Some time ago I've noticed Loft feature has a huge drawback in some circumstance, while lofting 2 sections with not parallel lines you get a Loft with Bspline faces and that's ok. But when lines of sections are parallel you get Bspline face as well and that's not OK IMHO.
Sweep feature has a better behaviour: if sections are parallel you get a sweep with planar faces, otherwise you get Bspline twisted face. That's a smart behaviour. Sweep feature needs a path vector in addition compare to Loft though.
See here:

Loft-vs-Sweep_Bspline_vs_flat_faces.gif
Loft-vs-Sweep_Bspline_vs_flat_faces.gif (111.01 KiB) Viewed 982 times

Maybe the Loft behaviour could be similar to Sweep?
Or maybe could you use sweep feature as an enhancement for your taper angle option in Pad feature?
Do you see what I mean? What's your opinion?

That would be ambiguous I am afraid, because the user may actually want to select the 'real' owner object of those geometry, instead of the intermediate feature that generate the selected geometry. In some context, yes, it does make sense.
I guess I see your point, so I would say in context of a Part design body such behaviour would make sens a lot.
In order to no disturb the FC standard workflow the selection of intermediate feature from 3D view to Treeview could be enabled by holding F key +RMB on the relevant face of the model.
F key as "feature selection".
IMHO such intermediate feature selection would ease a lot the access to feature properties and speedup a lot the global workflow, especially for large models with numerous features in tree view. IMHO that would be a huge improvement.
What do you think?
Thanks for your attention.
User avatar
Boogieman
Posts: 18
Joined: Wed Apr 18, 2018 9:03 am

Re: PartDesign new development, MultiBody and more

Postby Boogieman » Sat Jan 30, 2021 2:44 pm

Thank you realthunder for your great work. This is such a big leap forward for Freecad. The GUI is so much cleaner now and the Part Design features help a lot. Those are improvements i was hoping for a long time.

What i don't understand is how to use the "generic pattern feature". I didn't find any documentation so far except for the screenshot.
But when i try to use

Expression:

Code: Select all

[._app.Placement(._app.Vector(10), 
._app.Rotation()), 
._app.Placement(._app.Vector(50),
._app.Rotation())] 
i get the error message
Recompute failed! Please check report view.
<Exception> Access denied of callable in unknown module
in expression: ._app.Placement(._app.Vector(10), ._app.Rotation())
in binding 'MatrixList


Version:
OS: Linux Mint 19 (XFCE/xfce)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 2021.0129.23662 +3166 (Git) AppImage
Build type: Release
Branch: LinkStage3
Hash: bd2d90d312b3519573a323f97d7544d82f0e314d
Python version: 3.8.6
Qt version: 5.12.9
Coin version: 4.0.0
OCC version: 7.4.0
Locale: English/United Kingdom (en_GB)
realthunder
Posts: 1954
Joined: Tue Jan 03, 2017 10:55 am

Re: PartDesign new development, MultiBody and more

Postby realthunder » Wed Feb 03, 2021 12:42 am

-alex- wrote:
Mon Jan 25, 2021 10:12 pm
Sweep feature has a better behaviour: if sections are parallel you get a sweep with planar faces, otherwise you get Bspline twisted face. That's a smart behaviour. Sweep feature needs a path vector in addition compare to Loft though.
I'll try sweep later.

I guess I see your point, so I would say in context of a Part design body such behaviour would make sens a lot.
In order to no disturb the FC standard workflow the selection of intermediate feature from 3D view to Treeview could be enabled by holding F key +RMB on the relevant face of the model.
It's kind of complicated. Because topo naming trace back is ambiguous by nature. I'll probably add a similar command to 'Pick geometry' to offer selection of trace back.
Try Assembly3 (latest version 0.11) along with my custom build of FreeCAD at here.
And if you'd like to show your support, you can donate through patreon, liberapay, or paypal
realthunder
Posts: 1954
Joined: Tue Jan 03, 2017 10:55 am

Re: PartDesign new development, MultiBody and more

Postby realthunder » Wed Feb 03, 2021 1:28 am

Boogieman wrote:
Sat Jan 30, 2021 2:44 pm
i get the error message
Recompute failed! Please check report view.
<Exception> Access denied of callable in unknown module
in expression: ._app.Placement(._app.Vector(10), ._app.Rotation())
in binding 'MatrixList
This problem has been fixed in the latest 02.02 release. Please try again. Basically, the generic feature contains a PropertyMatrixList named as MatrixList, and will produce a pattern according to the given list of matrix (which allows for mirror and scale). The edit task panel just give you a shortcut to bind an expression to that property. The expression can evaluate to a list of either placement or matrix. With the new Python like syntax of expression in my branch, you can basically do anything with it. Here is an expression for an array of placements along a spherical surface (actually any type of surface).

Code: Select all

[._app.Placement(Sphere.<<Face1>>._shape.Surface.getD0(*v),
			    ._app.Rotation(._app.Vector(0, 0, 1), Sphere.<<Face1>>._shape.Surface.normal(*v)))
	for v in [(i/10.0, j/10.0) for i in ._py.range(0, 30) for j in ._py.range(0, 10)]]
Screenshot from 2021-02-03 09-24-07.png
Screenshot from 2021-02-03 09-24-07.png (113.7 KiB) Viewed 687 times
Attachments
genericpattern.FCStd
(856.53 KiB) Downloaded 21 times
Try Assembly3 (latest version 0.11) along with my custom build of FreeCAD at here.
And if you'd like to show your support, you can donate through patreon, liberapay, or paypal
bleber
Posts: 45
Joined: Thu Jun 30, 2016 5:12 pm

Re: PartDesign new development, MultiBody and more

Postby bleber » Thu Feb 04, 2021 12:44 am

In formula editor ( I'm not a programmer ) some times I need to make reference to the length of a edge to link parametrically a pad length, for example. And for me is hard to obtain these length.

A possible tool/workflow to obtain numbers from a geometry:
One possible way is to obtain the geometry reference with the right mouse button > Pick Geometry > pie menu ( select geometry ) copy to clipboard and I can paste to formula editor.And in formula editor some thing to obtain simple numbers from geometry: length, angle, radius, .....
I thing that some thing like these can improve the workflow for parametric models.
User avatar
Boogieman
Posts: 18
Joined: Wed Apr 18, 2018 9:03 am

Re: PartDesign new development, MultiBody and more

Postby Boogieman » Thu Feb 04, 2021 1:52 am

realthunder wrote:
Wed Feb 03, 2021 1:28 am
This problem has been fixed in the latest 02.02 release. Please try again.
Generic pattern works great now. This is awesome! This solves a lot of problems i had before.