Sketcher Workbench/ko: Difference between revisions

From FreeCAD Documentation
No edit summary
No edit summary
Line 31: Line 31:
구속은 개체의 자유도를 제한하는 데 사용됩니다. 예를 들어, 구속이 없는 선분의 자유도(Degrees of Freedom 약어로 "DoF")는 4입니다: 수평 또는 수직으로 움직일 수 있고, 늘릴 수 있고, 회전할 수 있습니다.
구속은 개체의 자유도를 제한하는 데 사용됩니다. 예를 들어, 구속이 없는 선분의 자유도(Degrees of Freedom 약어로 "DoF")는 4입니다: 수평 또는 수직으로 움직일 수 있고, 늘릴 수 있고, 회전할 수 있습니다.


수평 또는 수직 구속 또는 각도 구속(다른 선 또는 축 중 하나에 대한 기준)을 적용하면 회전 가능성을 제한하게 되고, 따라서 3개의 자유도를 갖게 됩니다. 원점과 관련하여 중 하나를 잠그면 2개의 자유도가 추가로 제거됩니다. 치수 구속을 적용하면 마지막 남은 자유도가 제거됩니다. 그러면 선이 '''완전히 구속'''된 것으로 간주됩니다.
수평 또는 수직 구속 또는 각도 구속(다른 선 또는 축 중 하나에 대한 기준)을 적용하면 회전 가능성을 제한하게 되고, 따라서 3개의 자유도를 갖게 됩니다. 선분의 양 끝점 중 하나를 원점에 대해 고정하면 2개의 자유도가 추가로 제거됩니다. 치수 구속을 적용하면 마지막 남은 자유도가 제거됩니다. 그러면 선이 '''완전히 구속'''된 것으로 간주됩니다.


개체는 서로 연관되어 구속될 수 있습니다. 일치점 구속조건을 사용하면 두 선이 해당 점 중 하나를 통해 결합될 수 있습니다. 그들 사이에 각도를 설정하거나 수직으로 설정할 수 있습니다. 선은 호나 원 등에 접할 수 있습니다. 여러 개체가 포함된 복잡한 스케치에는 완전 구속에 이르는 다양한 해결책이 있을 수 있습니다.
개체는 서로 연관되어 구속될 수 있습니다. 일치점 구속조건을 사용하면 두 선이 해당 점 중 하나를 통해 결합될 수 있습니다. 그들 사이에 각도를 설정하거나 수직으로 설정할 수 있습니다. 선은 호나 원 등에 접할 수 있습니다. 여러 개체가 포함된 복잡한 스케치에는 완전 구속에 이르는 다양한 해결책이 있을 수 있습니다.

Revision as of 14:07, 25 June 2024

스케치 작업대 아이콘

소개

스케치 작업대에서는 다른 작업대에서 사용하기 위한 2D 스케치를 생성할 수 있습니다. 2D 스케치는 많은 CAD 모형의 출발점입니다. 스케치는 일반적으로 3D 형상을 생성하는 작업에 필요한 윤곽선과 경로를 정의합니다. 모형의 최종 형상은 다수의 스케치에 의존할 수 있습니다.

부품 작업대에서 정의된 부울 연산과 함께 스케치 작업대는 고체를 구축하는 구성적 고체 기하학(SCG:Constructive Solid Geometry)방법의 기초를 형성합니다. 그러나 다른 많은 작업대에서도 스케치를 사용합니다.

스케치 작업대에는 2D 도형이 길이, 각도, 관계(수평, 수직, 직각 등) 측면에서 정확한 기하학적 정의를 따를 수 있도록 하는 구속 기능이 있습니다. 구속 조건 해결사는 2D 기하의 구속 범위를 계산하고 스케치의 자유도를 대화식으로 탐색할 수 있습니다.

스케치 작업대는 2D 설계도면 제작용이 아닙니다. 스케치를 사용하여 고체 도형특징을 생성하면 스케치는 자동으로 숨겨지고 구속조건은 스케치 편집 모드에서만 표시됩니다. 인쇄용 2D 뷰만 생성해야 하고 3D 모델을 생성하고 싶지 않은 경우 설계제도 작업대를 활용하세요.

완전히 구속된 스케치

구속

구속은 개체의 자유도를 제한하는 데 사용됩니다. 예를 들어, 구속이 없는 선분의 자유도(Degrees of Freedom 약어로 "DoF")는 4입니다: 수평 또는 수직으로 움직일 수 있고, 늘릴 수 있고, 회전할 수 있습니다.

수평 또는 수직 구속 또는 각도 구속(다른 선 또는 축 중 하나에 대한 기준)을 적용하면 회전 가능성을 제한하게 되고, 따라서 3개의 자유도를 갖게 됩니다. 선분의 양 끝점 중 하나를 원점에 대해 고정하면 2개의 자유도가 추가로 제거됩니다. 치수 구속을 적용하면 마지막 남은 자유도가 제거됩니다. 그러면 선이 완전히 구속된 것으로 간주됩니다.

개체는 서로 연관되어 구속될 수 있습니다. 일치점 구속조건을 사용하면 두 선이 해당 점 중 하나를 통해 결합될 수 있습니다. 그들 사이에 각도를 설정하거나 수직으로 설정할 수 있습니다. 선은 호나 원 등에 접할 수 있습니다. 여러 개체가 포함된 복잡한 스케치에는 완전 구속에 이르는 다양한 해결책이 있을 수 있습니다.

구속에는 기하학적 구속과 치수 구속의 두 가지 종류가 있습니다. 아래의 도구 부분에 자세히 설명되어 있습니다.

구속 편집

When a driving dimensional constraint is created, and if the Ask for value after creating a dimensional constraint preference is selected (default), a dialog opens to edit its value.

Sketcher_Edit_Constraint.png

You can enter a numerical value or an expression, and it is possible to name the constraint to facilitate its use in other expressions. You can also check the Reference checkbox to switch the constrain to reference mode.

To edit the value of an existing dimensional constraint do one of the following:

  • Double-click the constraint value in the 3D view.
  • Double-click the constraint in the Sketcher Dialog.
  • Right-click the constraint in the Sketcher Dialog and select the Change value option from the context menu.

Reposition constraints

Dimensional constraints can be repositioned in the 3D view by dragging. Hold down the left mouse button over the constraint value and move the mouse. The symbols of geometric constraints are positioned automatically and cannot be moved.

Profile sketches

To create a sketch that can be used as a profile for generating solids certain rules must be followed:

  • The sketch must contain only closed contours. Gaps between endpoints, however small, are not allowed.
  • Contours can be nested, to create voids, but should not self-intersect or intersect other contours.
  • Contours cannot share edges with other contours. Duplicate edges must be avoided.
  • T-connections, that is more than two edges sharing a common point, or a point touching an edge, are not allowed.

These rules do not apply to construction geometry (default color blue), which is not shown outside edit mode, or if the sketch is used for a different purpose. Depending on the workbench and the tool that will use the profile sketch, additional restrictions may apply.

Drawing aids

The Sketcher Workbench has several drawing aids and other features that can help when creating geometry and applying constraints.

Continue modes

There are two continue modes: Geometry creation "Continue Mode" and Constraint creation "Continue Mode". If these are checked (default) in the preferences, related tools will restart after finishing. To exit an continuous tool press Esc or the right mouse button. This must be repeated if a continuous geometry tool has already received input. You can also exit a continuous tool by starting another geometry or constraint creation tool. Note that pressing Esc if no tool is active will exit sketch edit mode. Uncheck the Esc can leave sketch edit mode preference if you often inadvertently press Esc too many times.

Auto constraints

In sketches that have Auto constraints checked (default) several constraints are applied automatically. The icon of a proposed automatic constraint is shown next to the cursor when it is placed correctly. Left-Clicking will then apply that constraint. This is a per-sketch setting that can be changed in the Sketcher Dialog or by changing the 보기Autoconstraints property of the sketch.

The following constraints are applied automatically:

Snapping

introduced in version 0.21

It is possible to snap to grid lines and grid intersection, to edges of geometry and midpoints of lines and arcs, and to certain angles. Please note that snapping does not produce constraints in and of itself. For example, only if Auto constraints is switched on will snapping to an edge produce a Point on object constraint. But just picking a point on the edge would then have the same result.

On-View-Parameters

introduced in version 1.0

Depending on the selected option in the preferences only the dimensional On-View-Parameters or both the dimensional and the positional On-View-Parameters can be enabled. Positional parameters allow the input of exact coordinates, for example the center of a circle, or the start point of a line. Dimensional parameters allow the input of exact dimensions, for example the radius of a circle, or the length and angle of a line. On-View-Parameters are not available for all tools.

Determining the center point of a circle with the positional parameters enabled

Determining the radius of a circle with the dimensional parameters enabled

If values are entered and confirmed by pressing Enter or Tab, related constraints are added automatically. If two parameters are displayed at the same time, for example the X and Y coordinate of a point, it is possible to enter one value and pick a point to define the other. Depending on the object additional constraints may be required to fully constrain it. Constraints resulting from On-View-Parameters take precedence over those that may result from Auto constraints.

Arc created by entering all On-View-Parameters with resulting automatically created constraints

Coordinate display

If the Show coordinates beside cursor while editing preference is checked (default), the parameters of the current geometry tool (coordinates, radius, or length and angle) are displayed next to the cursor. This is deactivated while On-View-Parameters are shown.

Selection methods

While a sketch is in edit mode the following selection methods can be used:

3D view element selection

As elsewhere in FreeCAD, an element can be selected in the 3D view with a single left mouse click. But there is no need to hold down the Ctrl key when selecting multiple elements. Holding down that key is possible though and has the advantage that you can miss-click without losing the selection. Edges, points and constraints can be selected in this manner.

3D view box selection

Box selection in the 3D view works without using Std BoxSelection or Std BoxElementSelection:

  1. Make sure that no tool is active.
  2. Do one of the following:
    • Click in an empty area and drag a rectangle from left to right to select elements that lie completely inside the rectangle.
    • Click in an empty area and drag a rectangle from right to left to also select elements that touch or cross the rectangle.

You can box-select edges and points, constraints cannot be box-selected.

3D view connected geometry selection

introduced in version 1.0

Double-clicking an edge in the 3D view will select all edges directly and indirectly connected with that edge via endpoints. There is no need for the edges to be connected with Coincident constraints, endpoints need only have the same coordinates.

Sketcher Dialog selection

Edges and points can also be selected from the Elements section of the Sketcher Dialog, and constraints from the Constraints section of that dialog.

Copy, cut and paste

introduced in version 1.0

The standard keyboard shortcuts, Ctrl+C, Ctrl+X and Ctrl+V, can be used to copy, cut and paste selected Sketcher geometry including related constraints. But these tools are also available from the Sketch → Sketcher tools menu. They can be used within the same sketch but also between different sketches or separate instances of FreeCAD. Since the data is copied to the clipboard in the form of Python code, it can be used in other ways too (e.g. shared on the forum).

Tools

The Sketcher Workbench tools are located in the Sketch menu and/or several toolbars. introduced in version 0.21: Almost all Sketcher toolbars are only displayed while a sketch is in edit mode. The only exception is the Sketcher toolbar which is only displayed if no sketch is in edit mode.

Some tools are also available from the 3D view context menu while a sketch is in edit mode, or from the context menus of the Sketcher Dialog.

introduced in version 0.21: If a sketch is in edit mode the Structure toolbar is hidden as none of its tools can then be used.

General

Sketcher toolbar

  • Edit sketch: Opens the Sketcher Dialog to edit an existing sketch.
  • Reorient sketch: Places a sketch on one of the main planes with an optional offset. It can also be used to detach a sketch.
  • Validate sketch: Can analyze and repair a sketch that is no longer editable or has invalid constraints, or add missing coincident constraints.
  • Mirror sketch: Mirrors sketches across their X axis, Y axis, or origin.

Sketcher Edit Mode toolbar

  • View section: Toggles a temporary section plane that hides any objects and parts of objects in front of the sketch plane.

Sketcher edit tools toolbar

Other

  • Stop operation: Stops any currently running geometry or constraint creation tool.

Sketcher geometries

These are tools for creating objects.

  • Polyline: Creates a series of line and arc segments connected by their endpoints. The tool has several modes.
  • Create arc:
  • Create circle/ellipse:
  • Ellipse by center: Creates an ellipse by its center, an endpoint of one of its axes, and a point along the ellipse. introduced in version 1.0: Or by both endpoints of one of its axes and a point along the ellipse.
  • Create rectangle:
  • Create regular polygon:
  • Square: Creates a square. Idem.
  • Octagon: Creates an octagon. Idem.
  • Regular polygon: Creates a regular polygon. The number of sides can be specified.
  • Create slot:
  • Slot: Creates a slot.
  • Create B-spline:
  • Toggle construction geometry: Either toggles the geometry creation tools to/from construction mode, or toggles selected geometry to/from construction geometry.

Sketcher constraints

These are tools for creating constraints. Some constraints require the use of Helper constraints.

  • Dimensional constraints:
  • Dimension: Is the context-sensitive constraint tool of the Sketcher Workbench. Based on the current selection, it offers appropriate dimensional constraints, but also geometric constraints. introduced in version 1.0
  • Horizontal distance: Fixes the horizontal distance between two points or the endpoints of a line. If a single point is pre-selected, the distance is relative to the origin of the sketch.
  • Vertical distance: Fixes the vertical distance between two points or the endpoints of a line. If a single point is pre-selected, the distance is relative to the origin of the sketch.
  • Distance: Fixes the length of a line, the distance between two points, the perpendicular distance between a point and a line; or, introduced in version 0.21, the distance between the edges of two circles or arcs, or between the edge of a circle or arc and a line; or, introduced in version 1.0, the length of an arc.
  • Auto radius/diameter: Fixes the radius of arcs and B-spline weight circles, and the diameter of circles.
  • Radius: Fixes the radius of circles, arcs and B-spline weight circles.
  • Diameter: Fixes the diameter of circles and arcs.
  • Angle: Fixes the angle between two edges, the angle of a line with the horizontal axis of the sketch, or the aperture angle of a circular arc.
  • Lock: Applies Horizontal distance and Vertical distance constraints to points. If a single point is selected the constraints reference the origin of the sketch. If two or more points are selected the constraints reference the last point in the selection.
  • Coincident: Creates a coincident constraint between points, or a concentric constraint.
  • Horizontal/vertical constraints:
  • Horizontal: Constrains lines or pairs of points to be horizontal.
  • Vertical: Constrains lines or pairs of points to be vertical.
  • Parallel: Constrains lines to be parallel.
  • Perpendicular: Constrains two lines to be perpendicular, or two edges, or an edge and an axis, to be perpendicular at their intersection. The constraint can also connect two edges, forcing them to be perpendicular at the joint.
  • Tangent or collinear: Constrains two edges, or an edge and an axis, to be tangent. The constraint can also connect two edges, forcing them to be tangent at the joint. If two lines are selected they are made collinear.
  • Equal: Constrains edges to have an equal length (lines) or curvature (other edges except B-splines).
  • Symmetric: Constrains two points to be symmetrical around a line or axis, or around a third point.
  • Block: Blocks edges in place with a single constraint. It is mainly intended for B-splines.
  • Refraction (Snell's law): Constrains two lines to follow the law of refraction of light as it penetrates through an interface.
  • Toggle constraints:
  • Toggle driving/reference constraint: Toggles the dimensional constraint creation tools between driving and reference mode, or toggles selected dimensional constraints between those modes.

Sketcher tools

  • Create fillet/chamfer:
  • Edit edge:
  • Trim: Trims an edge at the nearest intersections with other edges.
  • Split: Splits an edge while transferring most constraints.
  • Extend: Extends or shortens a line or an arc to an arbitrary location, or to a target edge or point.
  • External geometry: Projects edges and/or vertices belonging to objects outside the sketch onto the sketch plane.
  • Carbon copy: Copies all geometry and constraints from another sketch into the active sketch.
  • Symmetry: Creates mirrored copies of selected elements.

Sketcher B-spline tools

  • Insert knot: Inserts a knot into a B-spline or increases the multiplicity of an existing knot.

Sketcher visual

  • Show/hide B-spline information layer:

Obsolete tools

  • Clone: Clones a Sketcher element. Not available in version 1.0 and above.
  • Close shape: Creates a closed shape by applying coincident constraints to endpoints. Not available in version 0.21 and above.
  • Corner-preserving fillet: Creates a fillet between two non-parallel lines while preserving their corner point. Not available in version 1.0 and above.
  • Connect edges: Connect Sketcher elements by applying coincident constraints to endpoints. Not available in version 0.21 and above.
  • Copy: Copies a Sketcher element. Not available in version 1.0 and above.
  • Move: Moves the selected geometry taking as reference the last selected point. Not available in version 1.0 and above.
  • Rectangular array: Creates an array of selected Sketcher elements. Not available in version 1.0 and above.

Preferences

Best practices

Every CAD user develops their own way of working over time, but there are some useful general principles to follow.

  • A series of simple sketches is easier to manage than a single complex one. For example, a first sketch can be created for the base 3D feature (either a pad or a revolve), while a second one can contain holes or cutouts (pockets). Some details can be left out, to be realized later on as 3D features. You can choose to avoid fillets in your sketch if there are too many, and add them as a 3D feature.
  • Always create a closed profile, or your sketch won't produce a solid, but rather a set of open faces. If you don't want some of the objects to be included in the solid creation, turn them to construction elements with the Construction Mode tool.
  • Use the Auto constraints feature to limit the number of constraints you'll have to add manually.
  • As a general rule, apply geometric constraints first, then dimensional constraints, and lock your sketch last. But remember: rules are made to be broken. If you're having trouble manipulating your sketch, it may be useful to constrain a few objects first before completing your profile.
  • If possible, center your sketch at the origin (0,0) with the Lock constraint. If your sketch is not symmetric, locate one of its points at the origin, or choose nice round numbers for the lock distances.
  • If you have the possibility to choose between the Length constraint and the Horizontal or Vertical distance constraints, prefer the latter. Horizontal and Vertical distance constraints are computationally cheaper.
  • In general, the best constraints to use are: Horizontal and Vertical constraints; Horizontal and Vertical length constraints; point-to-point Tangency. If possible, limit the use of these: the general Length constraint; edge-to-edge Tangency; Point on object constraint; Symmetric constraint.
  • If in doubt about the validity of a sketch once it is complete (features turn green), close the Sketcher dialog and use Validate sketch.

Tutorials

Scripting

The Sketcher scripting page contains examples on how to create constraints from Python scripts.

Examples

For some ideas of what can be achieved with Sketcher tools, have a look at: Sketcher examples.