New tool: Curve which uses point as control handle
Allow use of previously defined points to the be end point of a control handle.
Use case:
I define a point A, then later when creating a curve I can select A as as end point to one of the curve's control handle.
Comments (22)
-
repo owner -
reporter This should be an option when creating any curve.
-
reporter This would be my preferred way to create curves. This is how I create curves in my python program. It works really well.
-
reporter But it isnt interactive, so some people would not prefer this method.
But once created, the points can be tweaked, so the user can see how the curve moves and determine the best formula for the point.
-
repo owner I can make it like a separate tool. User select point B, A, D and E. What do you think?
-
reporter Perfect.
-
reporter -
reporter - changed title to Create Curve tool which uses point as control handle
-
repo owner -
I'm really looking forward to see this implemented. It will help me a lot in a pattern I'm currently designing.
Regarding interactivity: How about making it possible to snap/connect a spline control point handle to a existing point without opening a dialog?
I'm thinking something like this:
- Create a spline
- Move spline's control point near an existing point (maybe hold down a modifier key) and it will snap
- The control point's position gets defined by the position of the other point
Now when you change the target point the spline updates automatically.
If you then want to modify the linked control point (and remove the connection):
- Select the spline
- Move the control point and it will unsnap and break the link
-
repo owner Benjamin, what you see is a "night sky". Each object has an order in history. This is the main reason why we don't have the snapping feature. Most graphic editors don't have such problems. I am speaking about depth of object in sequence. And snapping feature will not work for some cases because object exist before the target.
Regarding interactivity: How about making it possible to snap/connect a spline control point handle to a existing point without opening a dialog? I am thinking more about special tool or second mode for exist tool like Susan suggested.
-
I was looking into how to implement this. Might be a long journey, because C++ is not of my particular knowledge. However, I share here my analysis (also to understand the code better):
The candidate would be the vsplinepath.cpp here: https://bitbucket.org/dismine/valentina/src/02e312d71477c1e60cb97d86313570a8a4c191f3/src/libs/vgeometry/?at=develop
And then
VPointF GetP1 () const; QPointF GetP2 () const; QPointF GetP3 () const; VPointF GetP4 () const;
I see that the two control points are Qt's
QPointF
notVPointF
I suppose
VPointF
are well calculated Valentina Points whileQPointF
are just coordinates. My plan was to makeQPointF
VPointF
for the normal 2-enpoint-spline. A multiple spline is then just a composition and mere convenience.At tool definition time, there would then be the selection of optional 4 points, all well defined Valentina Points, there would then be any editing option disabled as the Bezier Curve is well defined by 4
VPointF
points. If I wouldn't select the two control handles as Valentina Points (as they would be optional), I would then have a traditional "manual" Bezier.However, I didn't understand where the viewport is defined and constructed.
Can you point me to an example?
-
This is by the way a feature which common CAD solutions aren't incorporating, but which is crucial to dynamic designs, in other words, measure driven patterns.
-
repo owner - changed status to open
-
repo owner - marked as enhancement
- assigned issue to
-
repo owner Issue
#394was marked as a duplicate of this issue. -
repo owner -
reporter Since this is now a separate tool, the dialog box only needs the begin & end point, and the two points to use as control points.
-
reporter New file
-
repo owner - changed status to resolved
Merge with feature. Resolved issue
#395. Create Curve tool which uses point as control handle.→ <<cset b0183b0dbf33>>
-
reporter - changed title to New tool: Curve which uses point as control handle
-
repo owner - removed milestone
Removing milestone: v0.5.0 (automated comment)
- Log in to comment
Where do you need such a case?