Google Summer of Code 2023 - Coding! Up to July 10th

Contributions from the participants, questions and answers to their projects.
Discussions of proposals for upcoming events.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
bleber
Posts: 259
Joined: Thu Jun 30, 2016 5:12 pm

Re: Google Summer of Code 2023 - Call for Ideas

Post by bleber »

Formula editor improvement.
A mockup with the process to "catch" a length propriety of an edge with a pick tool.
For maximum flexibility, the reference can ve anything that you can extract a number to assign to an expression to make a formula.
The "another level feature" are make an: if, or, ..... basic programming code formulas in the formula editor.
Attachments
Screenshot_20230124_013406.png
Screenshot_20230124_013406.png (122.23 KiB) Viewed 3302 times
User avatar
adrianinsaval
Veteran
Posts: 5541
Joined: Thu Apr 05, 2018 5:15 pm

Re: Google Summer of Code 2023 - Call for Ideas

Post by adrianinsaval »

bleber wrote: Tue Feb 07, 2023 6:50 pm Formula editor improvement.
A mockup with the process to "catch" a length propriety of an edge with a pick tool.
For maximum flexibility, the reference can ve anything that you can extract a number to assign to an expression to make a formula.
The "another level feature" are make an: if, or, ..... basic programming code formulas in the formula editor.
expressions using generated geometry are a terrible idea, in any case it can allow clicking a property or referencing the whole object
Hologram
Posts: 201
Joined: Thu Nov 03, 2022 3:05 pm

Re: Google Summer of Code 2023 - Call for Ideas

Post by Hologram »

1. I could think of all sorts of tool enhancements. Like you have in-command shortcut options in the Draft Polyline (M-key), you could expand that to many more tools. Basically, implement a modal tool system.

2. 2D drafting could be improved with better polyline segment manipulation tools (sub-element selection, sub-element move)

3. Selection in general, see: https://forum.freecad.org/viewtopic.php?t=75719

4. More intuitive and efficient parametrisation through spreadsheets, maybe. Like type: "parametername = Value", have it auto-populate in the spreadsheet with the parametername alias. Add a header above for the auto-populated cells and a style to indicate they were not typed in manually. Allows you more freedom to work as you go.
5. Then you could add drag and drop row ordening (and if you have a formula that references B6, but you move it to C7, it will maintain links).
6. Get rid of the Spreadsheet.Parameter syntax for formula and instead allow to just type the parameter alias. Saves users a lot of typing the initial Spreadsheet letters.
7. A pop-up spreadsheet window
8. A dedicated spreadsheet for automatically assigned parameter aliases (ties back to 4, but make it a different sheet with headers/ titles per modeling operation). This helps keep your own spreadsheets clean, while you could use the other sheet in your formulas.

9. Don't know if suitable for GSOC: try to get Paddle's sketcher work to merge. There are plenty of patches of his that could be worked on

10. For the sketcher: work on additional functionality for spline types and constraints.

11. For draft workbench a curve to curve intersection which trims/ extends both curves to their intersection point (so it's just one operation instead of 2). Could be mixed and matched with Chamfer and Fillet operations.

12. UI: Help bridge stylesheet styling so that every window/ button type that is nested in other Qt classes are documented and styleable. Polish the rough edges where possible.

13. bring RealThunder's shaded display functionality over to master (nicer realistic viewports).

14. Maybe research a way to load commands on activation from not-loaded workbenches when invoked through a macro or hotkey.

15. As per: https://forum.freecad.org/viewtopic.php?t=75768 - work on persistent toolbars (prevent them from moving around).

16. Anyone familiar with Affinity/ Illustrstor/ NX: create a shapebuilder tool, which if you drag over enclosed areas of curves, merges them to leave their oultine. With alt pressed, removes the curve sections that enclose the portion one drags in from the selected shapes. And, this could also be a trimming tool when you drag over overshooting (extending) line ends so they end at the adjacent curve intersection. Nice QoL improvement. Window/ lasso select curves to operate on, the drag to operate and button/ hotkey to accept changes.

17. A parametric, node based editor (akin to Blender's geometry nodes, but then for BREPS). This is useful for complex patterning and for the BIM workbench in general (also useable to automate tasks for those who like nodes more than scripting).

These are some initial thoughts
grd
Posts: 328
Joined: Wed Apr 13, 2022 5:13 am
Location: Eindhoven, The Netherlands

Re: Google Summer of Code 2023 - Call for Ideas

Post by grd »

Hologram wrote: Tue Feb 07, 2023 8:41 pm ...
Yes, I also have a dozen or so ideas. But if you really think hard about ONE subject, a subject where a guy is gonna work on for about three or four months with your supervision, what would your idea then? That is the subject about what we should be talking about. Think, write it down, write the rationale, the benefits and the possible failure. What can we learn? If you can write that down then I am sure that your idea gets attention.

Edit: And of course it would be better if you can maintain that code for the rest of your life ;-)
About Nim. Latest Release 2.0.2. Here is Nim in 100 seconds and a Nim package. There are Qt and OCCT packages.
bleber
Posts: 259
Joined: Thu Jun 30, 2016 5:12 pm

Re: Google Summer of Code 2023 - Call for Ideas

Post by bleber »

adrianinsaval wrote: Tue Feb 07, 2023 8:15 pm

expressions using generated geometry are a terrible idea
Ok I understand it is caused for the TNP problem, and the use of spreadsheed is recomended way.
In the example I use generated geometry, but you can pick a more stable propiety like a constraint lenght on sketch or pad lenght.
Hologram
Posts: 201
Joined: Thu Nov 03, 2022 3:05 pm

Re: Google Summer of Code 2023 - Call for Ideas

Post by Hologram »

grd wrote: Wed Feb 08, 2023 8:52 am Yes, I also have a dozen or so ideas. But if you really think hard about ONE subject, a subject where a guy is gonna work on for about three or four months with your supervision, what would your idea then? That is the subject about what we should be talking about. Think, write it down, write the rationale, the benefits and the possible failure.
I would say this final motivation for the project scope, problem definition and proposed solution are more for the person who is working on this and what they may find interesting. My list was more of a getting started list of ideas. Here's a conversion of the items to topics:

But, you can already see a couple topics:
1. Parameter management and useability thereof
Problem: Right now the system is somewhat rigid and takes away some flow of work, you need to manage your parameters manually, but if the software could take care of this, the user is more free to delegate thoughts to design.
Solution: see some points from my previous posts, it comes down to the software managing the parameters in an automated fashion. The user just specifies a parameter name, the software stores and recalls it when using the parameter name (alias).
Caveats: Is there a way for the user to manually adjust the automated parameter management? How is this made insightful for the user?

2. Tool ergonomics (& efficiency)
Problem: Many tools in FreeCAD exist for a single purpose. For instance, when you are drafting polylines, you can create one polyline at the time. When done, you exit the tool. But, if you want to create many polylines and manipulate them, you need to reinvoke tools or switch tools often.
Solution: Create 'swiss army knife' tools, which are tailored to a particular workflow. For example, the polyline command would be reactivated after closing a curve or exiting one curve. This is the idea of active tools. The advantage is that you can keep on working within a tool and that you can determine yourself whether you want to only stop drawing the current polyline or that you want to switch to another dedicated tool. The same goes for trim and extending, where you often want to make sure lines intersect. For that matter, you can create smart context sensitive tools. You could for instance add an intersection mode so curves are automatically extended/ trimmed to their intersection point before initiating a fillet or chamfer. Set the chamfer distance to 0 (with an in-command shortcut aka modal hotkey) to trim/ extend polylines to intersection points.
Caveats: which tools, what workbenches and what is the user workflow? > can ask on the forum.

3. Realistic viewport display
Problem: the current viewport display is rather barebones. We, as humans, are used to see things with shading: cast and drop shadow (not just ambient occlusion). FreeCAD doesn't do this, so it is harder to evaluate shapes (and looks less pretty).
Solution: Implement a realistic, physics based viewport.
Caveats: RealThunder uses an external library for this. What are the opportunities of the library? And what are its weaknesses? It has to be maintainable and there are downsides to incorporating a third party library in the code.

4. Selection
Problem: FreeCAD can be a bit iffy and inconsistent in its selection procedures. But, selection is one of the most important processes of modelling, you need to tell the software which operations are performed on what. This 'what' is covered by selection.
Solution: Create a more consistent selection experience across the software (read: workbenches). Having dedicated modes (with hotkeys) for selection, selection filtering, etc. helps to more accurately and more efficiently tell the software where to operate on. This in turn, saves time and reduces clicks for the user, which makes the software more efficient.
Caveats: How are each of the selection modes accessed? Are there conflicts with current hotkeys/ navigation preferences?
chrisb
Veteran
Posts: 53930
Joined: Tue Mar 17, 2015 9:14 am

Re: Google Summer of Code 2023 - Call for Ideas

Post by chrisb »

Hologram wrote: Wed Feb 08, 2023 11:27 am For instance, when you are drafting polylines, you can create one polyline at the time. When done, you exit the tool. But, if you want to create many polylines and manipulate them, you need to reinvoke tools or switch tools often.
Solution: Create 'swiss army knife' tools, which are tailored to a particular workflow. For example, the polyline command would be reactivated after closing a curve or exiting one curve.
Make yourself familiar with Draft Polyline, it's all there.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
Hologram
Posts: 201
Joined: Thu Nov 03, 2022 3:05 pm

Re: Google Summer of Code 2023 - Call for Ideas

Post by Hologram »

chrisb wrote: Thu Feb 09, 2023 6:14 am
Hologram wrote: Wed Feb 08, 2023 11:27 am For instance, when you are drafting polylines, you can create one polyline at the time. When done, you exit the tool. But, if you want to create many polylines and manipulate them, you need to reinvoke tools or switch tools often.
Solution: Create 'swiss army knife' tools, which are tailored to a particular workflow. For example, the polyline command would be reactivated after closing a curve or exiting one curve.
Make yourself familiar with Draft Polyline, it's all there.
Okay, yes, the continue option. It didn't work by using the hotkey (it exits the polyline for me). Sorta skimmed over it because of that.
E2: Appears my user.cfg got corrupted.

E: But, the Draft Fillet command, only accepts lines according to the documentation. And splitting polylines to then go to their properties to set a radius is not the most user friendly to say the least (it does not support varying fillet radii either, nor filleting non-coincident lines). So that's not already there. What is available, requires way too many clicks and can be improved, that's what I'm saying. Not to mention the lack of a live preview when performing a fillet, where you could click the lines to fillet, move the mouse and thereby change its radius (like Blender's bevel command if you are familiar with that).
GeneFC
Veteran
Posts: 5373
Joined: Sat Mar 19, 2016 3:36 pm
Location: Punta Gorda, FL

Re: Google Summer of Code 2023 - Call for Ideas

Post by GeneFC »

Hologram wrote: Tue Feb 07, 2023 8:41 pm 1. I could think of all sorts of tool enhancements.
Keep in mind the groundrules outlined in the opening post.

Looking for ideas that YOU are willing and able to mentor.

Are you ready to handle all these items?

Gene
Hologram
Posts: 201
Joined: Thu Nov 03, 2022 3:05 pm

Re: Google Summer of Code 2023 - Call for Ideas

Post by Hologram »

The way I read it is that you could also send in interesting ideas for a project. I unfortunately won't be able to participate myself, but was trying to help raise some ideas to kick-start the discussion for future prospects. The opening post's sentence is open to multiple interpretations.
Post Reply