Sketcher CreateBSpline: Difference between revisions

From FreeCAD Documentation
(Trim spline has apparently been supported for a while, but split has not)
(V0.22 -> V1.0)
 
(53 intermediate revisions by 3 users not shown)
Line 4: Line 4:
<!--T:10-->
<!--T:10-->
{{Docnav
{{Docnav
|[[Sketcher_CreateArcOfParabola|Arc of parabola]]
|[[Sketcher_CompCreateBSpline|Create a B-spline]]
|[[Sketcher_CreatePeriodicBSpline|Periodic B-spline]]
|[[Sketcher_CreatePeriodicBSpline|Periodic B-spline by control points]]
|[[Sketcher_Workbench|Sketcher]]
|[[Sketcher_Workbench|Sketcher]]
|IconL=Sketcher_CompCreateBSpline.png
|IconL=Sketcher_CreateArcOfParabola.svg
|IconR=Sketcher_CreatePeriodicBSpline.svg
|IconR=Sketcher_CreatePeriodicBSpline.svg
|IconC=Workbench_Sketcher.svg
|IconC=Workbench_Sketcher.svg
Line 19: Line 19:
|Shortcut={{KEY|G}} {{KEY|B}} {{KEY|B}}
|Shortcut={{KEY|G}} {{KEY|B}} {{KEY|B}}
|Version=0.17
|Version=0.17
|SeeAlso=[[Sketcher_CreatePeriodicBSpline|Sketcher periodic B-spline]]
|SeeAlso=[[Sketcher_CreatePeriodicBSpline|Sketcher CreatePeriodicBSpline]]
}}
}}


Line 25: Line 25:


<!--T:3-->
<!--T:3-->
This tool creates a B-spline curve from its control points. (See [[B-Splines|this page]] for more info about B-splines.)
The [[Image:Sketcher_CreateBSpline.svg|24px]] [[Sketcher_CreateBSpline|Sketcher CreateBSpline]] tool creates a B-spline curve from control points. See [[B-Splines|this page]] for more information about B-splines.


</translate>
</translate>
[[File:Sketcher_B-spline_example01.png]]
[[Image:Sketcher_CreateBSpline_Example.png]]
<translate>
<translate>
<!--T:4-->
<!--T:4-->
{{Caption|B-spline curve (white) defined by 5 control points.<br>
{{Caption|A B-spline curve (in white) defined by 4 control points. Pictured are the control polygon in green (the straight lines connecting the control points) and the weight circles in dark yellow. The green digit "3" in the center refers to the [[Sketcher_BSplineIncreaseDegree#Description|degree]] of the B-spline and the digits "(4)" at the ends of the B-spline refer to their [[Sketcher_BSplineDecreaseKnotMultiplicity#Description|knot multiplicity]]. The red digit "3" denotes the control point weight which is defined as radius constraint to the control point circle.}}
The control polygon (green) connects the control points (marked with dark yellow weight circles).<br>
The number 3 (green, without brackets) in the center refers to the [[Sketcher_BSplineIncreaseDegree#Description|degree]] of the B-spline.<br>
The numbers (1) and (4) (green, in round brackets) refer to the [[Sketcher_BSplineDecreaseKnotMultiplicity#Description|multiplicity]] of the knot points.<br>
The numbers [1.00] (green, in square brackets) refer to the weights of the control points.}}


==Usage== <!--T:5-->
==Usage== <!--T:5-->

<!--T:16-->
See also: [[Sketcher_Workbench#Drawing_aids|Drawing aids]].


<!--T:6-->
<!--T:6-->
# There are several ways to invoke the tool:
# Press the {{Button|[[File:Sketcher_CreateBSpline.svg|16px]] [[Sketcher_CreateBSpline|Create B-spline]]}} button.
#* Press the {{Button|[[Image:Sketcher_CreateBSpline.svg|16px]] [[Sketcher_CreateBSpline|B-spline by control points]]}} button.
# Create a series of points by clicking in the [[3D_view|3D view]]. While the command is active, the created points are connected with straight lines, and a construction circle is created centered on each point.
#* Select the {{MenuCommand|Sketcher → Sketcher geometries → [[Image:Sketcher_CreateBSpline.svg|16px]] Create B-spline}} option from the menu.
# Optionally press {{KEY|D}} before terminating the input to define the degree of the B-spline. {{Version|0.20}}
#* Right-click in the [[3D_view|3D view]] and select the {{MenuCommand|[[Image:Sketcher_CreateBSpline.svg|16px]] Create B-spline}} option from the context menu. {{Version|1.0}}
# Optionally press {{KEY|Backspace}} before terminating the input to delete the last created control point. {{Version|0.20}}
#* Use the keyboard shortcut: {{KEY|G}} then {{KEY|B}}, then {{KEY|B}}.
# Right-click to terminate the input and generate the curve.
# The cursor changes to a cross with the tool icon.
# Depending on preferences, the tool may remain active to trace a new curve. Right-click again to exit the command.
# Pick several control points.
* 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 the control point.
# While the tool is active a small construction circle is created centered on each point.
* The visibility of the control polygon, the curvature comb, the degree and the knot multiplicity can be toggled on/off from the [[Sketcher_Workbench#Sketcher_B-spline_tools|B-spline tools]] toolbar.
# Optionally press {{KEY|D}} before finishing the input to define the degree of the B-spline.
* Check out the other tools in the [[Sketcher_Workbench#Sketcher_B-spline_tools|B-spline tools]] toolbar for more B-spline editing tools.
# Optionally press {{KEY|Backspace}} before finishing the input to delete the last control point.
# Right-click or press {{KEY|Esc}} to finish the input.
# The B-spline is created, including a set of internal geometry (weight circles and knot points).
# If the tool runs in [[Sketcher_Workbench#Continue_modes|continue mode]]:
## Optionally keep creating B-splines.
## To finish, right-click or press {{KEY|Esc}}, or start another geometry or constraint creation tool.

==Notes== <!--T:14-->

<!--T:15-->
* Elements of the internal geometry can be deleted. They can be recreated at any time with [[Sketcher_RestoreInternalAlignmentGeometry|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 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.


==Limitations== <!--T:7-->
==Limitations== <!--T:7-->


<!--T:8-->
<!--T:8-->
* Many types of constraints are not supported at this time. Only the B-spline's control point and end points can be constrained.
* Several constraints are not supported at this time.
* [[Sketcher_Split|Split]] and [[Sketcher_Extend|extend]] tools are not supported.
* The shape of a B-spline curve can only be edited by dragging one of the control points. The knots lying on the curve cannot be selected.




<!--T:11-->
<!--T:11-->
{{Docnav
{{Docnav
|[[Sketcher_CreateArcOfParabola|Arc of parabola]]
|[[Sketcher_CompCreateBSpline|Create a B-spline]]
|[[Sketcher_CreatePeriodicBSpline|Periodic B-spline]]
|[[Sketcher_CreatePeriodicBSpline|Periodic B-spline by control points]]
|[[Sketcher_Workbench|Sketcher]]
|[[Sketcher_Workbench|Sketcher]]
|IconL=Sketcher_CompCreateBSpline.png
|IconL=Sketcher_CreateArcOfParabola.svg
|IconR=Sketcher_CreatePeriodicBSpline.svg
|IconR=Sketcher_CreatePeriodicBSpline.svg
|IconC=Workbench_Sketcher.svg
|IconC=Workbench_Sketcher.svg

Latest revision as of 10:14, 21 April 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 from control points. See this page for more information about B-splines.

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. Pick several control points.
  4. While the tool is active a small construction circle is created centered on each point.
  5. Optionally press D before finishing the input to define the degree of the B-spline.
  6. Optionally press Backspace before finishing the input to delete the last control point.
  7. Right-click or press Esc to finish the input.
  8. The B-spline is created, including a set of internal geometry (weight circles and knot points).
  9. 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 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.