Sketcher CreateBSpline: Difference between revisions

From FreeCAD Documentation
No edit summary
No edit summary
Line 72: Line 72:
* After a B-spline is created, it is possible to define the weight of the control points by changing the radii of the weight circles. The equality constraints on the circles need to be deleted first. The radius constraint is arbitrary, the weight of the control points will be defined by the relative radii of the circles. It works similar to gravity: the bigger a circle is in relation to the others, the more the curve will be attracted to that control point.
* After a B-spline is created, it is possible to define the weight of the control points by changing the radii of the weight circles. The equality constraints on the circles need to be deleted first. The radius constraint is arbitrary, the weight of the control points will be defined by the relative radii of the circles. It works similar to gravity: the bigger a circle is in relation to the others, the more the curve will be attracted to that control point.
* The degree of a created B-spline can be [[Sketcher_BSplineIncreaseDegree|increased]] or [[Sketcher_BSplineDecreaseDegree|decreased]], an the multiplicity of its knots can be [[Sketcher_BSplineIncreaseKnotMultiplicity|increased]] or [[Sketcher_BSplineIncreaseKnotMultiplicity|decreased]] as well.
* The degree of a created B-spline can be [[Sketcher_BSplineIncreaseDegree|increased]] or [[Sketcher_BSplineDecreaseDegree|decreased]], an the multiplicity of its knots can be [[Sketcher_BSplineIncreaseKnotMultiplicity|increased]] or [[Sketcher_BSplineIncreaseKnotMultiplicity|decreased]] as well.
* B-splines by knots are always created as cubic (i.e. with degree 3) but their degree can be changed later.
* The visibility of the [[Sketcher_BSplineDegree|degree]], the [[Sketcher_BSplinePolygon|control polygon]], the [[Sketcher_BSplineComb|curvature comb]], the [[Sketcher_BSplineKnotMultiplicity|knot multiplicity]] and the [[Sketcher_BSplinePoleWeight|control point weight]] can be toggled on/off from the [[Sketcher_Workbench#Sketcher visual|Sketcher visual]] toolbar.
* The visibility of the [[Sketcher_BSplineDegree|degree]], the [[Sketcher_BSplinePolygon|control polygon]], the [[Sketcher_BSplineComb|curvature comb]], the [[Sketcher_BSplineKnotMultiplicity|knot multiplicity]] and the [[Sketcher_BSplinePoleWeight|control point weight]] can be toggled on/off from the [[Sketcher_Workbench#Sketcher visual|Sketcher visual]] toolbar.



Revision as of 09:46, 27 June 2024

Sketcher CreateBSpline

Menu location
Sketch → Sketcher geometries → Create B-spline
Workbenches
Sketcher
Default shortcut
G B B
Introduced in version
0.17
See also
Sketcher CreatePeriodicBSpline

Description

The Sketcher CreateBSpline tool creates a B-spline curve by control points. introduced in version 1.0: Or optionally by knot points. introduced in version 1.0: The curve can optionally be closed.

B-spline curve (white) defined by 5 control points.
The control polygon (green) connects the control points (marked with dark yellow weight circles).
The number 3 (green, without brackets) in the center refers to the degree of the B-spline.
The numbers (1) and (4) (green, in round brackets) refer to the multiplicity of the knot points.
The numbers [1.00] (green, in square brackets) refer to the weights of the control points.

Usage

See also: Drawing aids.

  1. There are several ways to invoke the tool:
  2. The cursor changes to a cross with the tool icon.
  3. The BSpline parameters section (introduced in version 1.0) is added at the top of the Sketcher Dialog.
  4. Optionally change the Degree (this can also be done after points have been picked):
    • Enter a number greater than zero.
    • Press the U key to increase the degree.
    • Press the J key to decrease the degree.
  5. Optionally press the R key or check the Periodic checkbox to create a closed B-spline (this can also be done after points have been picked). introduced in version 1.0
  6. Optionally press the M key or select from the dropdown list in the parameters section to change the tool mode (this can also be done after points have been picked):
  7. Pick several points.
  8. Optionally press the F key before finishing to delete the last point.
  9. Right-click or press Esc to finish the input.
  10. The B-spline is created, including a set of internal geometry (weight circles and knot points).
  11. If the tool runs in continue mode:
    1. Optionally keep creating B-splines.
    2. To finish, right-click or press Esc, or start another geometry or constraint creation tool.

Notes

  • Elements of the internal geometry can be deleted. They can be recreated at any time with Sketcher RestoreInternalAlignmentGeometry.
  • After a B-spline is created, it is possible to define the weight of the control points by changing the radii of the weight circles. The equality constraints on the circles need to be deleted first. The radius constraint is arbitrary, the weight of the control points will be defined by the relative radii of the circles. It works similar to gravity: the bigger a circle is in relation to the others, the more the curve will be attracted to that control point.
  • The degree of a created B-spline can be increased or decreased, an the multiplicity of its knots can be increased or decreased as well.
  • B-splines by knots are always created as cubic (i.e. with degree 3) but their degree can be changed later.
  • The visibility of the degree, the control polygon, the curvature comb, the knot multiplicity and the control point weight can be toggled on/off from the Sketcher visual toolbar.

Limitations

  • Several constraints are not supported at this time.
  • The defined knot multiplicity may not always be respected:
    • For a periodic spline, the first knot (coincident with last) always has a multiplicity of 2.
    • For a non-periodic spline, the first and last knots always have a multiplicity of 4.
    • If the points just before and just after have multiplicities >=3, the piece between these two is fully continuous, and this (middle) point will only be constrained with point-on-object. If a knot is needed, consider using the insert knot tool.