[Sketcher] Any suggestions on improving B-Spline knot insertion?
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Be nice to others! Respect the FreeCAD code of conduct!
[Sketcher] Any suggestions on improving B-Spline knot insertion?
In PR #5311 I introduced a new "knot insertion" command for B-Splines so that we have more tools to manipulate them without creating fresh B-Splines. However, the feature is still pretty bare and I would like interested and more knowledgeable users to suggest some improvements that would make working with it (and splines in general) more feature complete and useful.
One major step that I want to take is to give the user some sort of feedback over where the new point corresponding to the new knot will lie. Currently we only see the new knot after it's created, but it doesn't sound like a difficult task to show the new point on the viewport. Unfortunately the dialog box obstructs this viewport (see https://github.com/FreeCAD/FreeCAD/pull ... 1008352439). I am looking for alternative ways to show this dialog so that the viewport is visible. My first instinct is to start a Taskview for knot insertion, but if we are editing a sketcher object, we already are in sketch TaskView, and I don't know of a taskview providing k
Any suggestions for how to implement this would be greatly appreciated
One major step that I want to take is to give the user some sort of feedback over where the new point corresponding to the new knot will lie. Currently we only see the new knot after it's created, but it doesn't sound like a difficult task to show the new point on the viewport. Unfortunately the dialog box obstructs this viewport (see https://github.com/FreeCAD/FreeCAD/pull ... 1008352439). I am looking for alternative ways to show this dialog so that the viewport is visible. My first instinct is to start a Taskview for knot insertion, but if we are editing a sketcher object, we already are in sketch TaskView, and I don't know of a taskview providing k
Any suggestions for how to implement this would be greatly appreciated
Re: [Sketcher] Any suggestions on improving B-Spline knot insertion?
Tagging you since @chennes suggested in a PM, and since we've been discussing this on Github.uwestoehr wrote: Ping
- adrianinsaval
- Veteran
- Posts: 5553
- Joined: Thu Apr 05, 2018 5:15 pm
Re: [Sketcher] Any suggestions on improving B-Spline knot insertion?
paddle has been working on adding a widget to the task view to input stuff for sketcher commands, perhaps you could use that while on sketcher?
Re: [Sketcher] Any suggestions on improving B-Spline knot insertion?
If it is what I think it is, it will be useful.adrianinsaval wrote: ↑Thu Feb 10, 2022 3:58 pm paddle has been working on adding a widget to the task view to input stuff for sketcher commands, perhaps you could use that while on sketcher?
Hello @paddle I'm not aware of what feature you're working but it sounds interesting. Any sneak peek?paddle wrote: Ping
Re: [Sketcher] Any suggestions on improving B-Spline knot insertion?
Hello!
You can see a video showing Tool Setting widget :
https://forum.freecadweb.org/viewtopic.php?f=9&t=65279
I think it's possibly something that will help you indeed. But it hasn't merge yet.
If you want to check the latest version of ToolSetting it's on this branch :
https://github.com/PaddleStroke/FreeCAD ... Contextual
Support me on Patreon: https://www.patreon.com/FreeCadDevDiary
FreeCad Dev Diary channel:[/b] https://www.youtube.com/channel/UCGMTmJ ... NiPSSEhBHA
FreeCad Dev Diary channel:[/b] https://www.youtube.com/channel/UCGMTmJ ... NiPSSEhBHA
Re: [Sketcher] Any suggestions on improving B-Spline knot insertion?
From reading the forum post it appears you are done with coding the tool settings task box and are now just making the different settings for different sketch features? If you could rebase on the latest master with knot insertion I can work on the settings for that tool.paddle wrote: ↑Thu Feb 10, 2022 7:28 pm If you want to check the latest version of ToolSetting it's on this branch :
https://github.com/PaddleStroke/FreeCAD ... Contextual
Re: [Sketcher] Any suggestions on improving B-Spline knot insertion?
You're right, the tool settings is working and I'm just improving it, fixing bad hacks as per Abdullah recommendations and making new settings for new tools.jnxd wrote: ↑Thu Feb 10, 2022 11:31 pm From reading the forum post it appears you are done with coding the tool settings task box and are now just making the different settings for different sketch features? If you could rebase on the latest master with knot insertion I can work on the settings for that tool.
Basically the idea is that when your tool launches it calls
Code: Select all
toolSettings->widget->setSettings(x);
You might need to add other components depending on what you need.
I'll rebase on master now. Edit: Git is driving me crazy again. I just can't rebase and I can't find why.
I'm trying simple "git pull --rebase origin master" and he's throwing me conflicts that makes no sens.
Code: Select all
Freecad-Src (ConstraintContextual)
$ git pull --rebase origin master
From https://github.com/PaddleStroke/FreeCAD
* branch master -> FETCH_HEAD
Auto-merging src/Mod/Sketcher/Gui/CommandCreateGeo.cpp
CONFLICT (content): Merge conflict in src/Mod/Sketcher/Gui/CommandCreateGeo.cpp
Auto-merging src/Mod/Sketcher/Gui/TaskSketcherTool.cpp
CONFLICT (add/add): Merge conflict in src/Mod/Sketcher/Gui/TaskSketcherTool.cpp
Auto-merging src/Mod/Sketcher/Gui/TaskSketcherTool.h
CONFLICT (add/add): Merge conflict in src/Mod/Sketcher/Gui/TaskSketcherTool.h
Auto-merging src/Mod/Sketcher/Gui/TaskSketcherTool.ui
CONFLICT (add/add): Merge conflict in src/Mod/Sketcher/Gui/TaskSketcherTool.ui
Auto-merging src/Mod/Sketcher/Gui/ViewProviderSketch.h
error: could not apply 1b0258351f... Sketcher tool setting implementation. Only for rectangle tool for now.
hint: Resolve all conflicts manually, mark them as resolved with
hint: "git add/rm <conflicted_files>", then run "git rebase --continue".
hint: You can instead skip this commit: run "git rebase --skip".
hint: To abort and get back to the state before "git rebase", run "git rebase --abort".
Could not apply 1b0258351f... Sketcher tool setting implementation. Only for rectangle tool for now. (Solved conflict)
I don't understand, why it's trying to apply a commit of itself to itself?
Edit2: It appeared that I had duplicates of commits because the remote branch was merged in the local branch at some point. I hate git. On the bright side it's rebased
Support me on Patreon: https://www.patreon.com/FreeCadDevDiary
FreeCad Dev Diary channel:[/b] https://www.youtube.com/channel/UCGMTmJ ... NiPSSEhBHA
FreeCad Dev Diary channel:[/b] https://www.youtube.com/channel/UCGMTmJ ... NiPSSEhBHA
Re: [Sketcher] Any suggestions on improving B-Spline knot insertion?
Great. Please try to squash the commits if possible as you rebase them as well. I'm pretty sure people will have a hard time handling forty eight of them in one PR. I would also suggest making the PR itself when you are confident enough for a few constraints.
Glad you found out the issue and it's resolved!paddle wrote: ↑Fri Feb 11, 2022 9:18 am I'll rebase on master now. Edit: Git is driving me crazy again. I just can't rebase and I can't find why.
...
Edit2: It appeared that I had duplicates of commits because the remote branch was merged in the local branch at some point. I hate git. On the bright side it's rebased
Re: [Sketcher] Any suggestions on improving B-Spline knot insertion?
Meanwhile, I set out to set up drawing the representative point in parallel, but I'm having issues going forward with it. See https://github.com/FreeCAD/FreeCAD/pull/6348.