Tutorial custom placing of windows and doors/ru: Difference between revisions

From FreeCAD Documentation
(Created page with "Category:User Documentation/ru")
(Created page with "{{Caption|align=center|Неправильный проём в стене из-за ошибочной нормали (Normal) окна}}")
(31 intermediate revisions by the same user not shown)
Line 82: Line 82:
== Создание пользовательских дверей и окон ==
== Создание пользовательских дверей и окон ==


8. Переключитесь на [[Sketcher Workbench/ru|верстак Sketcher]]; выделите часть стены справа, где нет двери; кликните на [[Sketcher NewSketch/ru|Sketcher NewSketch]]; выделите {{Button|FlatFace}} как attachment method. Если существующая геометрия заслоняет ваш вид, кликните [[Sketcher ViewSection/ru|Sketcher ViewSection]] чтобы убрать её.
8. Переключитесь на [[Sketcher Workbench/ru|верстак Sketcher]]; выделите часть стены справа, где нет двери; кликните на [[Sketcher NewSketch/ru|Новый эскиз]]; выделите {{Button|FlatFace}} как метод прикрепления. Если существующая геометрия заслоняет ваш вид, кликните [[Sketcher ViewSection/ru|Обзор эскиза]] чтобы спрятать её.


9. Нарисуйте милый эскиз с тремя замкнутыми полилиниями. Убедитесь в наличии ограничений для всех полилиний.
9. Draw a fancy sketch containing three closed wires. Make sure to provide constraints to all wires.
:9.1. The outside wire is the biggest one, and will define the main dimensions of the window object, and the size of the hole created when it's embedded in an [[Arch Wall]]. Make sure the dimensions are named appropriately, for example, {{incode|Width}} and {{incode|Height}}. A constraint also defines the curvature of the outer wire; give it an appropriate name, like {{incode|HeightCurve}}.
:9.1. Внешняя полилиния - наибольшая, определяет главный размер оконного объекта и размер выреза в стене при внедрении окна в [[Arch Wall/ru|Arch Wall]]. Убедитесь, что размеры подходяще названы, например {{incode|Width}} и {{incode|Height}}. Ограничения так же определяют curvature of the outer wire; дайте им подходящее имя, вроде {{incode|HeightCurve}}.
:9.2. Следующая полилиния это смещение от внешней полилинии, и вместе с ней определяет ширину замоноличиваемой в стену оконной коробки. Назовите смещение соответствующе, например, {{incode|FrameFixedOffset}}. Он будет использован как для вертикального, так и горизонтального смещения. Нижнее смещение, при установке в ноль приведёт к касанию оконной коробкой низа окна, это можно использовать для моделирования двери вместо окна. Дайте ей подходящее имя, вроде {{incode|FrameFixedBottom}}.
:9.2. The second wire is offset from the outer wire, and together with it, they define the width of the fixed frame of the window. Name the offset appropriately, for example, {{incode|FrameFixedOffset}}. It will be used for both the top vertical and horizontal offsets. The bottom offset, if set to zero, will result in the fixed frame touching the bottom of the window; this can be used to model a door instead of a window. Give it an appropriate name, like {{incode|FrameFixedBottom}}.
:9.3. Третья, внутренняя полилиния это смещение от второй полилинии и вместе с ней определяет подвижную раму окна. Внутренняя полилиния так же определяет размер стекла. Ещё раз, дайте этим смещениям говорящие имена, например, {{incode|FrameInnerOffset}} и {{incode|FrameInnerBottom}}.
:9.3. The third, innermost wire is offset from the second wire, and together with it, they define the frame of the window that can open. The innermost wire also defines the size of the glass panel. Again, give meaningful names to these offsets, for example, {{incode|FrameInnerOffset}} and {{incode|FrameInnerBottom}}.
:9.4. In order to build succesfully the sketch, use horizontal ([[Sketcher ConstrainHorizontal]]) and vertical ([[Sketcher ConstrainVertical]]) constraints for the straight sides; use auxiliary construction geometry ([[Sketcher ToggleConstruction]]), and tangential constraints ([[Sketcher ConstrainTangent]]) to correctly place the circular arcs at the top. As in this case the window is symmetrical, consider equality ([[Sketcher ConstrainEqual]]), symmetrical ([[Sketcher ConstrainSymmetric]]), and point on object ([[Sketcher ConstrainPointOnObject]]) constraints where it makes sense.
:9.4. Чтобы успешно построить эскиз, используйте горизонтальные ([[Sketcher ConstrainHorizontal/ru|Sketcher ConstrainHorizontal]]) вертикальные ([[Sketcher ConstrainVertical/ru|Sketcher ConstrainVertical]]) ограничения для непосредственных сторон; используйте дополнительную конструктивную геометрию ([[Sketcher ToggleConstruction/ru|Sketcher ToggleConstruction]]) и тангенциальные ограничения ([[Sketcher ConstrainTangent/ru|Sketcher ConstrainTangent]]) для корректного размещения дуг наверху. Поскольку сейчас окно симметрично, не забывайте, когда нужно, ограничения равенства ([[Sketcher ConstrainEqual/ru|Sketcher ConstrainEqual]]), симметрии ([[Sketcher ConstrainSymmetric/ru|Sketcher ConstrainSymmetric]]) и точки на объекте ([[Sketcher ConstrainPointOnObject/ru|Sketcher ConstrainPointOnObject]]).


[[Image:04_T02_window_constraints_outer_frame.png|center]]
[[Image:04_T02_window_constraints_outer_frame.png|center]]
Line 117: Line 117:
== Настройка пользовательского окна ==
== Настройка пользовательского окна ==


12. In the tree view select {{incode|Sketch002}} underlying {{incode|Window}}, and press {{KEY|Space}}, or change the property {{PropertyView|Visibility}} to {{TRUE}}.
12. В древе проекта под {{incode|Window}} выделите {{incode|Sketch002}}, и нажмите {{KEY|Space}}, или измените свойство {{PropertyView|Visibility}} на {{TRUE}}.


13. Double click {{incode|Window}} in the tree view to start editing it.
13. Дважды кликните на {{incode|Window}} в древе проекта для начала его редактирования.
:13.1. Inside the {{incode|Window elements}} dialog there are two panes, {{incode|Wires}} and {{incode|Components}}. There are three wires, {{incode|Wire0}}, {{incode|Wire1}}, and {{incode|Wire2}}, and one component, {{incode|Default}}. The wires refer to the closed loops that were drawn in the sketch; the components define the areas in the sketch that will be extruded to create frame or glass panels with real thicknesses; these areas are delimited by the wires. A window created from a preset already has two components, {{incode|OuterFrame}} and {{incode|Glass}}. The custom window needs to be edited to have a similar structure.
:13.1. Внутри диалога {{incode|Window elements}} имеется две панели, {{incode|Wires}} и {{incode|Components}}. Там будет три полилинии, {{incode|Wire0}}, {{incode|Wire1}} и {{incode|Wire2}}, и один компонент, {{incode|Default}}. Полилинии указывают на замкнутые кривые, нарисованные на эскизе; компоненты определяют области на эскизе, которые будут выдавлены для создания рамы или стеклянной панели с реальной толщиной, эти области разделяются полилиниями. Окно, созданное из заготовки, уже имеет два компонента, {{incode|OuterFrame}} и {{incode|Glass}}. Пользовательское окно нужно редактировать для получения такой структуры.


[[Image:09_T02_window_edit_default.png|center]]
[[Image:09_T02_window_edit_default.png|center]]


{{Caption|align=center|Dialog to edit a window or a door}}
{{Caption|align=center|Диалог редактирования окна или двери}}


:13.2. Click on {{incode|Default}}, and click the {{Button|Remove}} button to eliminate it.
:13.2. Кликните на {{incode|Default}}, потом на кнопке {{Button|Remove}} чтобы убрать его.


:13.3. Click {{Button|Add}}; this shows the properties of a new component like {{incode|Name}}, {{incode|Type}}, {{incode|Wires}}, {{incode|Thickness}}, {{incode|Offset}}, {{incode|Hinge}}, and {{incode|Opening mode}}. Give a name, such as {{incode|OuterFrame}}, choose {{incode|Frame}} for {{incode|Type}}, and click on {{incode|Wire0}} and then {{incode|Wire1}}; they should highlight in the 3D viewport. Add a small value for {{incode|Thickness}}, {{incode|15 mm}}, and check the checkbox to add the default value. This default value is the length assigned to the {{PropertyData|Frame}} property; a similar default can be assigned to the {{PropertyData|Offset}} property. Click the {{Button|+Create/update component}} button to finish editing the component.
:13.3. Кликните {{Button|Add}}; что покажет параметры нового компонента вроде {{incode|Name}}, {{incode|Type}}, {{incode|Wires}}, {{incode|Thickness}}, {{incode|Offset}}, {{incode|Hinge}}, и {{incode|Opening mode}}. Дайте имя, вроде {{incode|OuterFrame}}, выделите {{incode|Frame}} для типа {{incode|Type}}, и кликните на {{incode|Wire0}} и {{incode|Wire1}}; они будут подсвечены в окне трёхмерного вида. Добавьте небольшое значение для {{incode|Thickness}}, {{incode|15 mm}}, и отметьте чекбокс для установки значения по умолчанию. Это значение по умолчанию будет длинной, назначенной параметру {{PropertyData|Frame}}; подобное умолчание может быть назначено для параметра {{PropertyData|Offset}}. Кликните на кнопке {{Button|+Create/update component}}для завершения редактирования компонента.


:13.4. Click {{Button|Add}}; give another name, such as {{incode|InnerFrame}}, choose {{incode|Frame}} for {{incode|Type}}, and click on {{incode|Wire1}} and then {{incode|Wire2}}. Add a sensible {{incode|Thickness}}, {{incode|60 mm}}, and {{incode|Offset}}, {{incode|15 mm}}. Then click the {{Button|+Create/update component}} button.
:13.4. Кликните {{Button|Add}}; дайте другое имя, вроде {{incode|InnerFrame}}, укажите {{incode|Frame}} для {{incode|Type}} и кликните на {{incode|Wire1}} и {{incode|Wire2}}. Добавьте подходящего размера {{incode|Thickness}}, {{incode|60 mm}}, и {{incode|Offset}}, {{incode|15 mm}}. Затем кликните кнопку {{Button|+Create/update component}}.


:13.5. Click {{Button|Add}}; give another name, such as {{incode|Glass}}, choose {{incode|Glass panel}} for {{incode|Type}}, and click on {{incode|Wire2}}. Add a sensible {{incode|Thickness}}, {{incode|10 mm}}, and {{incode|Offset}}, {{incode|40 mm}}. Then click the {{Button|+Create/update component}} button. If any of the three components needs to be modified, select it and press {{Button|Edit}}; modifications are only saved after pressing the {{Button|+Create/update component}} button.
:13.5. Кликните {{Button|Add}}; дайте другое имя, вроде {{incode|Glass}}, выберите {{incode|Glass panel}} для {{incode|Type}}, и кликните {{incode|Wire2}}. Добавьте подходящего размера {{incode|Thickness}}, {{incode|10 mm}} и {{incode|Offset}}, {{incode|40 mm}}. Затем кликните кнопку {{Button|+Create/update component}}. Если любой из трёх компонентов нуждается в модификации, выделите его и нажмите {{Button|Edit}}; модификация сохранится только после нажатия кнопки {{Button|+Create/update component}}.


[[Image:10_T02_window_edit_components.png|center]]
[[Image:10_T02_window_edit_components.png|center]]


{{Caption|align=center|Editing a previously defined component of a window or a door}}
{{Caption|align=center|Редактирование ранее определённого компонента окна или двери}}


:13.6. If everything is set, click {{Button|Close}} to finish editing the window. The sketch may become hidden again, but the window will show distinct solid elements for the {{incode|OuterFrame}}, the {{incode|InnerFrame}}, and the {{incode|Glass}}. Give a value of {{incode|100 mm}} to {{PropertyData|Frame}} to assign a default thickness, which will be added to the value specified in the {{incode|OuterFrame}} component.
:13.6. Если всё установлено, кликните {{Button|Close}} для завершения редактирования окна. Эскиз вновь станет не виден, но окно покажет различимые элементы для {{incode|OuterFrame}}, для {{incode|InnerFrame}}, и {{incode|Glass}}. Задайте для {{PropertyData|Frame}} значение {{incode|100 mm}} для толщины по умолчанию, которое будет добавлено к значению, определённому в компоненте {{incode|OuterFrame}}.


[[Image:11_T02_window_property_view.png|center]]
[[Image:11_T02_window_property_view.png|center]]


{{Caption|align=center|Property view of the window to add default Frame length, Offset length, and other options}}
{{Caption|align=center|Вид параметров окна для добавления значений по умолчанию для Frame length, Offset length и других опций}}


[[Image:12_T02_window_finished.png|600px|center]]
[[Image:12_T02_window_finished.png|600px|center]]


{{Caption|align=center|Finished window with appropriate components embedded in the wall}}
{{Caption|align=center|Итоговое окно с соответствующими компонентами, внедрёнными в стену}}


== Размножение пользовательского окна ==
== Duplicating the custom window ==


14. In the tree view, select {{incode|Window}} and its underlying {{incode|Sketch002}}. Then go to {{MenuCommand|Edit → Duplicate selection}}, and answer {{Button|No}} if asked to duplicate unselected dependencies. A new {{incode|Window001}} and {{incode|Sketch003}} will appear in the same position as the original elements.
14. В древе проектов выделите {{incode|Window}} и нижележащий {{incode|Sketch002}}. Затем выполните {{MenuCommand|Edit → Duplicate selection}}, и при запросе ответьте {{Button|No}} для дублирования невыбранных зависимостей. Новые {{incode|Window001}} и {{incode|Sketch003}} появятся там же, где оригинальные элементы.


15. Select the new {{incode|Sketch003}}. Go to the {{PropertyData|Map Mode}} property, and click on the ellipsis next to the {{incode|FlatFace}} value. In the 3D viewport select the left side of the wall which doesn't have any element; rotate the [[standard view]] as necessary. Change the {{incode|Attachment offset}} to [-1 m, 0 m, 0 m] to center the window, and click {{Button|OK}}. The sketch and the window should appear in a new position.
15. Выделите новый {{incode|Sketch003}}. Перейдите к параметру {{PropertyData|Map Mode}} и кликните на эллипсе возле значения {{incode|FlatFace}}. В окне трёхмерного вида выделите левую сторону стены без каких-либо элементов; поверните [[standard view/ru|standard view]] куда надо. Измените {{incode|Attachment offset}} на [-1 m, 0 m, 0 m] для центрирования окна, и кликните {{Button|OK}}. Эскиз и окно появятся на новой позиции.
:{{Emphasis|Note:}} the [[Part Attachment|attachment operation]] can also be performed by changing to the [[Part Workbench]], and then using the menu {{MenuCommand|Part → Attachment}}.
:{{Emphasis|Примечание:}} [[Part Attachment|операция назначения]] так же может быть выполнена переключением на [[Part Workbench/ru|верстак Part]] и использованием меню {{MenuCommand|Part → Attachment}}.


[[Image:13_T02_sketch_attachment_edit.png|center]]
[[Image:13_T02_sketch_attachment_edit.png|center]]


{{Caption|align=center|Dialog to edit the attachment plane of the sketch}}
{{Caption|align=center|Диалог редактирования привязки плоскости эскиза}}


16. You may adjust the dimensions of the new window by changing the named parameters in {{incode|Sketch003}} under {{PropertyData|Constraints}}, for example, set {{incode|Height}} to {{incode|2 m}}, and {{incode|Frame Fixed Bottom}} to {{incode|0 m}}. Then press {{KEY|Ctrl}}+{{KEY|R}} to [[recompute]] the model. If the wall doesn't show a bigger hole for the new window, select the wall in the tree view, right click and choose {{incode|Mark to recompute}}, then press {{KEY|Ctrl}}+{{KEY|R}} again.
16. Вы можете настроить размеры нового окна изменением именованных параметров в {{incode|Sketch003}} в {{PropertyData|Constraints}}, например, установив {{incode|Height}} на {{incode|2 m}}, и {{incode|Frame Fixed Bottom}} на {{incode|0 m}}. Затем нажмите {{KEY|Ctrl}}+{{KEY|R}} для [[recompute/ru|пересчёта]] модели. Если окно не показывает увеличенного проёма под новое окно, выделите стену в древе проекта, кликните правой кнопкой и выберите {{incode|Mark to recompute}}, затем снова нажмите {{KEY|Ctrl}}+{{KEY|R}}.


17. Эти операции меняют позиции нового окна, но проём в окне не выглядит правильно. Оно наклонено, то есть, проём не перпендикулярен поверхности стены, и может даже вырезать другие части стены. Проблема в том, что {{incode|Window001}} сохранила информацию о {{PropertyData|Normal}} из оригинального {{incode|Window}}.
17. These operations have changed the position of the new window, but the opening in the wall doesn't look correct. It is slanted, that is, the hole is not perpendicular to the face of the wall, and it may even cut other parts of the wall. The problem is that {{incode|Window001}} has retained the {{PropertyData|Normal}} information of the original {{incode|Window}}.


[[Image:14_T02_sketch_2_attached_slanted.png|600px|center]]
[[Image:14_T02_sketch_2_attached_slanted.png|600px|center]]


{{Caption|align=center|Incorrect opening in the wall due to bad Normal of the window}}
{{Caption|align=center|Неправильный проём в стене из-за ошибочной нормали (Normal) окна}}


== Нормали дверей и окон ==
== Normals of doors and windows ==


18. Each [[Arch Window]] object controls the extrusion of its body and the opening that is created in its host wall by means of the {{PropertyData|Normal}}.
18. Each [[Arch Window]] object controls the extrusion of its body and the opening that is created in its host wall by means of the {{PropertyData|Normal}}.
Line 270: Line 270:
[[Category:User Documentation/ru]]
[[Category:User Documentation/ru]]


[[Category:Arch]]
[[Category:Arch/ru]]


[[Category:Draft]]
[[Category:Draft/ru]]


[[Category:Sketcher]]
[[Category:Sketcher/ru]]

Revision as of 20:22, 29 August 2019

Other languages:
Руководство
Тема
Архитектура
Уровень
Средний
Время для завершения
60 минут
Авторы
vocx
FreeCAD версия
0.18 или выше
Примеры файлов
нет
Смотрите также
None

Введение

Этот учебник покажет как поместить спроектированное пользователем окна и двери в модели здания. Он использует верстаки Draft, Arch, и Sketcher.

Используются следующие инструменты: Draft Grid, Draft Snap, Draft Wire, Arch Wall, Arch Window, и Sketcher NewSketch. Пользователь должен быть знаком с установкой ограничений в эскизах.

Этот учебник был вдохновлён учебниками, написанными jpg87 на форумах FreeCAD.

Установка

1. Откройте FreeCAD, создайте новый пустой документ, и переключитесь на Верстак Arch.

2. Убедитесь, что единицы измерения установлены в меню Правка → Настройки → Основные → Единицы измерения правильно. Например, МКС (м/кг/с/градус) хороши для работы с расстояниями в типичных строениях; и установите число знаков после запятой на 4, чтобы учитывать малейшие доли метра.

3. Используйте кнопку Показывать сетку для показа сетки с достаточным разрешением. Вы можете изменить вид сетки в меню Правка → Настройки → Draft → Сетка и привязка → Сетка. Установите линии через каждые 50 mm, с главными линиями каждые 20 линий (каждый метр), и 1000 линий всего (сетка покрывает площадь 50 x 50 метров).

4. Отодвиньте трёхмерный вид, если сетка слишком близка.

Теперь мы готовы сделать простейшую стену, где мы установим окна и двери.

Установка стены

5. Используйте инструмент Draft Wire для создания полилинии. Ведите её против часовой стрелки.

5.1. Первая точка в (0, 4, 0); в диалоге введите 0 m Enter, 4 m Enter, 0 m Enter.
5.2. Вторая точка в (2, 0, 0); в диалоге введите 2 m Enter, 0 m Enter, 0 m Enter.
5.3. Третья точка в (4, 0, 0); в диалоге введите 4 m Enter, 0 m Enter, 0 m Enter.
5.4. Четвёртая точка в (6, 2, 0); в диалоге введите 6 m Enter, 2 m Enter, 0 m Enter.
5.4. Пятая точка в (6, 5, 0); в диалоге введите 6 m Enter, 5 m Enter, 0 m Enter.
5.5. На клавиатуре нажмите A для завершения полилинии.
5.6. На клавиатуре нажмите 0 для получения аксонометрического вида модели.
Примечание: убедитесь, что чекбокс Относительно (R) не отмечен, когда вводите абсолютные координаты.
Примечание 2: точки могут быть определены указателем мыши по точкам сетки, с помощью панели Draft Snap и метода Draft Grid.
Примечание 3: вы можете создать формы программированием на Python. Учтите, что большинство функций ожидают ввод в миллиметрах.
import FreeCAD
import Draft

p = [FreeCAD.Vector(0.0, 4000.0, 0),
FreeCAD.Vector(2000.0, 0.0, 0.0),
FreeCAD.Vector(4000.0, 0.0, 0.0),
FreeCAD.Vector(6000.0, 2000.0, 0.0),
FreeCAD.Vector(6000.0, 5000.0, 0.0)]

w = Draft.makeWire(p, closed=False)

6. Выделите DWire и кликните инструмент Arch Wall; появится стена с шириной (толщиной) по умолчанию 0,2 м и высотой 3 м.

Базовая линия для стены

Стена, полученная из полилинии

Установка стандартных дверей и окон

7. Кликните инструмент Arch Window; в ниспадающем списке Preset выделите Simple door, и установите высоту в 2 м.

7.1. Установите привязку на Draft Midpoint, и попробуйте выделить нижнюю грань передней стены; поверните standard view как требуется, чтобы зацепить грань, а не поверхность стены; когда активна средняя точка, кликните для установки двери.
7.2. Кликните снова инструмент Arch Window, и установите другую дверь, на сей раз в средней точке крайней правой стены; поворачивайте standard view по необходимости.

Захват по средней точке нижней грани стены для установки двери

Примечание: Sill height это дистанция от пола до нижнего края элемента. Для дверей Sill height обычно 0 m, поскольку двери обычно на уровне пола; с другой стороны, окна обычно отделяет от пола от 0.5 до 1.5 m. Sill height может быть установлен только при создании окна или двери из заготовки. Когда окно или двери вставлены, корректируйте их размещение редактированием вектора ДанныеPosition [x, y, z] базового эскиза (Sketch).

Создание пользовательских дверей и окон

8. Переключитесь на верстак Sketcher; выделите часть стены справа, где нет двери; кликните на Новый эскиз; выделите FlatFace как метод прикрепления. Если существующая геометрия заслоняет ваш вид, кликните Обзор эскиза чтобы спрятать её.

9. Нарисуйте милый эскиз с тремя замкнутыми полилиниями. Убедитесь в наличии ограничений для всех полилиний.

9.1. Внешняя полилиния - наибольшая, определяет главный размер оконного объекта и размер выреза в стене при внедрении окна в Arch Wall. Убедитесь, что размеры подходяще названы, например Width и Height. Ограничения так же определяют curvature of the outer wire; дайте им подходящее имя, вроде HeightCurve.
9.2. Следующая полилиния это смещение от внешней полилинии, и вместе с ней определяет ширину замоноличиваемой в стену оконной коробки. Назовите смещение соответствующе, например, FrameFixedOffset. Он будет использован как для вертикального, так и горизонтального смещения. Нижнее смещение, при установке в ноль приведёт к касанию оконной коробкой низа окна, это можно использовать для моделирования двери вместо окна. Дайте ей подходящее имя, вроде FrameFixedBottom.
9.3. Третья, внутренняя полилиния это смещение от второй полилинии и вместе с ней определяет подвижную раму окна. Внутренняя полилиния так же определяет размер стекла. Ещё раз, дайте этим смещениям говорящие имена, например, FrameInnerOffset и FrameInnerBottom.
9.4. Чтобы успешно построить эскиз, используйте горизонтальные (Sketcher ConstrainHorizontal) вертикальные (Sketcher ConstrainVertical) ограничения для непосредственных сторон; используйте дополнительную конструктивную геометрию (Sketcher ToggleConstruction) и тангенциальные ограничения (Sketcher ConstrainTangent) для корректного размещения дуг наверху. Поскольку сейчас окно симметрично, не забывайте, когда нужно, ограничения равенства (Sketcher ConstrainEqual), симметрии (Sketcher ConstrainSymmetric) и точки на объекте (Sketcher ConstrainPointOnObject).

Ограничения для внешних полилиний эскиза, формирующих окно

Ограничения для внутренних полилиний эскиза, формирующих окно

10. Когда эскиз полностью зафиксирован, нажмите Close для выхода из эскиза (Sketcher LeaveSketch).

10.1. Поскольку лицевая поверхность стены выбирается при начальных шагах создания эскиза, эскиз параллелен с ней, однако он может быть в неверной позиции, вне стены. В этом случае подстройте ДанныеPosition внутри ДанныеAttachment Offset. Установите ДанныеPosition в [4 m, 1 m, 0 m], так что эскиз будет центрирован по стене в одном метре от пола.
10.2. Вы можете видеть именованные ограничения эскиза в ДанныеConstraints. Значения могут меняться с немедленным визуальным контролем изменений эскиза.

Эскиз окна движется к желательной позиции на стене

Именованные ограничения эскиза, которые могут меняться без углубления в эскиз

11. Переключитесь обратно на верстак Arch и примените Arch Window к выбранному новому Sketch002. Будет создано окно, и отверстие под него в стене. Окно сделано из пользовательского эскиза, а не стандартной заготовки, так что ему требуется редактирование для корректного отображения его компонентов, то есть неподвижной рамы, внутренней рамы, и стекла.

Пользовательское окно, созданное из эскиза, у него пока нет правильной рамы или стекла

Настройка пользовательского окна

12. В древе проекта под Window выделите Sketch002, и нажмите Space, или измените свойство ВидVisibility на true.

13. Дважды кликните на Window в древе проекта для начала его редактирования.

13.1. Внутри диалога Window elements имеется две панели, Wires и Components. Там будет три полилинии, Wire0, Wire1 и Wire2, и один компонент, Default. Полилинии указывают на замкнутые кривые, нарисованные на эскизе; компоненты определяют области на эскизе, которые будут выдавлены для создания рамы или стеклянной панели с реальной толщиной, эти области разделяются полилиниями. Окно, созданное из заготовки, уже имеет два компонента, OuterFrame и Glass. Пользовательское окно нужно редактировать для получения такой структуры.

Диалог редактирования окна или двери

13.2. Кликните на Default, потом на кнопке Remove чтобы убрать его.
13.3. Кликните Add; что покажет параметры нового компонента вроде Name, Type, Wires, Thickness, Offset, Hinge, и Opening mode. Дайте имя, вроде OuterFrame, выделите Frame для типа Type, и кликните на Wire0 и Wire1; они будут подсвечены в окне трёхмерного вида. Добавьте небольшое значение для Thickness, 15 mm, и отметьте чекбокс для установки значения по умолчанию. Это значение по умолчанию будет длинной, назначенной параметру ДанныеFrame; подобное умолчание может быть назначено для параметра ДанныеOffset. Кликните на кнопке +Create/update componentдля завершения редактирования компонента.
13.4. Кликните Add; дайте другое имя, вроде InnerFrame, укажите Frame для Type и кликните на Wire1 и Wire2. Добавьте подходящего размера Thickness, 60 mm, и Offset, 15 mm. Затем кликните кнопку +Create/update component.
13.5. Кликните Add; дайте другое имя, вроде Glass, выберите Glass panel для Type, и кликните Wire2. Добавьте подходящего размера Thickness, 10 mm и Offset, 40 mm. Затем кликните кнопку +Create/update component. Если любой из трёх компонентов нуждается в модификации, выделите его и нажмите Edit; модификация сохранится только после нажатия кнопки +Create/update component.

Редактирование ранее определённого компонента окна или двери

13.6. Если всё установлено, кликните Close для завершения редактирования окна. Эскиз вновь станет не виден, но окно покажет различимые элементы для OuterFrame, для InnerFrame, и Glass. Задайте для ДанныеFrame значение 100 mm для толщины по умолчанию, которое будет добавлено к значению, определённому в компоненте OuterFrame.

Вид параметров окна для добавления значений по умолчанию для Frame length, Offset length и других опций

Итоговое окно с соответствующими компонентами, внедрёнными в стену

Размножение пользовательского окна

14. В древе проектов выделите Window и нижележащий Sketch002. Затем выполните Edit → Duplicate selection, и при запросе ответьте No для дублирования невыбранных зависимостей. Новые Window001 и Sketch003 появятся там же, где оригинальные элементы.

15. Выделите новый Sketch003. Перейдите к параметру ДанныеMap Mode и кликните на эллипсе возле значения FlatFace. В окне трёхмерного вида выделите левую сторону стены без каких-либо элементов; поверните standard view куда надо. Измените Attachment offset на [-1 m, 0 m, 0 m] для центрирования окна, и кликните OK. Эскиз и окно появятся на новой позиции.

Примечание: операция назначения так же может быть выполнена переключением на верстак Part и использованием меню Part → Attachment.

Диалог редактирования привязки плоскости эскиза

16. Вы можете настроить размеры нового окна изменением именованных параметров в Sketch003 в ДанныеConstraints, например, установив Height на 2 m, и Frame Fixed Bottom на 0 m. Затем нажмите Ctrl+R для пересчёта модели. Если окно не показывает увеличенного проёма под новое окно, выделите стену в древе проекта, кликните правой кнопкой и выберите Mark to recompute, затем снова нажмите Ctrl+R.

17. Эти операции меняют позиции нового окна, но проём в окне не выглядит правильно. Оно наклонено, то есть, проём не перпендикулярен поверхности стены, и может даже вырезать другие части стены. Проблема в том, что Window001 сохранила информацию о ДанныеNormal из оригинального Window.

Неправильный проём в стене из-за ошибочной нормали (Normal) окна

Нормали дверей и окон

18. Each Arch Window object controls the extrusion of its body and the opening that is created in its host wall by means of the ДанныеNormal.

The normal is a vector [x, y, z] that indicates a direction perpedicular to a wall. When a window or door preset is created with the Arch Window tool directly over an Arch Wall, the normal is automatically calculated, and the resulting window or door is correctly aligned; the first two objects, Door and Door001, were created in this way.

In similar way, when a sketch is created by selecting a planar surface, it is oriented on this plane. Then when the Arch Window tool is used, the window will use as normal the perpendicular direction to the sketch. This was the case with the third object, the custom Window.

If the window already exists and needs to be moved, as was the case with the duplicated Window001 object, the sketch needs to be remapped to another plane; doing this moves both the sketch and the window, but the latter doesn't automatically update its normal, so it has incorrect extrusion information. The normal needs to be calculated manually and written to ДанныеNormal.

The three values of the normal vector are calculated as following.

x = -sin(angle)
y = cos(angle)
z = 0

Where angle is the angle of the local Z axis of the sketch with respect to the global Y axis.

When a sketch is created, it always has two axes, a local X (red) and a local Y (green). If the sketch is mapped to the global XY working plane, then these axes are aligned; but if the sketch is mapped on the global XZ or global YZ planes, as is common with windows and doors (the sketches are "standing up"), then the local Z (blue) forms an angle with the global Y axis; this angle varies from -180 to 180 degrees. The angle is considered positive if it opens counterclockwise, and it is negative if it opens clockwise, starting from the global Y axis.

Local coordinates of a sketch that is "standing up", that is, mapped to the global XZ plane

Intended directions of the normals for each door and window

If we look at the geometry created so far, we see the following normals.

Door
The local Z is aligned with the global Y, therefore, the angle is zero. The normal vector is
x = -sin(0) = 0
y = cos(0) = 1
z = 0

or ДанныеNormal is [0, 1, 0].

Door001
The local Z is rotated 90 degrees from the global Y, therefore, the angle is 90 (positive, because it opens counterclockwise). The normal vector is
x = -sin(90) = -1
y = cos(90) = 0
z = 0

or ДанныеNormal is [-1, 0, 0].

Window
The local Z is rotated 45 degrees from the global Y, therefore, the angle is 45 (positive, because it opens counterclockwise). The normal vector is
x = -sin(45) = -0.7071
y = cos(45) = 0.7071
z = 0

or ДанныеNormal is [-0.7071, 0.7071, 0].

Window001
The local Z direction is found by using the Draft Dimension tool and measuring the angle that the wall trace (Wire) makes with the global Y axis, or any line aligned to it. This angle is 26.57; the desired angle is the complement to this, so 90 - 26.57 = 63.43.

This means the local Z axis is rotated 63.43 degrees from the global Y, therefore, the angle is -63.46 (negative, because it opens clockwise). The normal vector is

x = -sin(-63.43) = 0.8943
y = cos(-63.43) = 0.4472
z = 0

Therefore ДанныеNormal should be changed to [0.8943, 0.4472, 0].

After doing these changes, recompute the model with Ctrl+R. If the wall doesn't update the hole, select it in the tree view, right click and choose Mark to recompute, then press Ctrl+R again.

19. The orientation of the extrusion of the window is resolved, together with the opening in the wall.

Correct opening in the wall due to proper Normal of the window

Final remarks

20. As demonstrated, the initial placement of the Arch Window is very important. The user should either

  • use the Arch Window tool to insert and automatically align a preset to a wall, or
  • map a sketch to the desired wall, and build the window after that.

If a window already exists, and it needs to be moved, the supporting sketch should be remapped to a new plane, and the ДанныеNormal of the window needs to be recalculated.

The new normal direction can be obtained by measuring the angle of the new wall with respect to the global Y axis, considering whether this angle is positive (counterclockwise) or negative (clockwise), and using a simple formula.

x = -sin(angle)
y = cos(angle)
z = 0

To confirm that the operations are correct, the absolute magnitude of the normal vector should be one. That is,

abs(N) = 1 = sqrt(x^2 + y^2 + z^2)
abs(N) = 1 = sqrt(sin^2(angle) + cos^2(angle) + z^2)