Draft Shape2DView/es: Difference between revisions

From FreeCAD Documentation
(Created page with "==Propiedades==")
(Updating to match new version of source page)
 
(30 intermediate revisions by 6 users not shown)
Line 1: Line 1:
<languages/>
{{GuiCommand/es|Name=Draft_Shape2DView|Workbenches=[[Draft Module/es|Boceto]], [[Arch Module/es|Arquitectura]]|MenuLocation=Boceto -> Vista de forma 2D}}

{{Docnav
|[[Draft_FlipDimension|FlipDimension]]
|[[Draft_SelectPlane|SelectPlane]]
|[[Draft_Workbench|Draft]]
|IconL=Draft_FlipDimension.svg
|IconR=Draft_SelectPlane.svg
|IconC=Workbench_Draft.svg
}}

<div class="mw-translate-fuzzy">
{{GuiCommand/es
|Name=Draft Shape2DView
|Name/es=Draft Shape2DView
|MenuLocation=Boceto → Vista de forma 2D
|Workbenches=[[Draft_Workbench/es|Boceto]], [[Arch_Workbench/es|Arquitectura]]
}}
</div>


<span id="Description"></span>
==Descripción==
==Descripción==


<div class="mw-translate-fuzzy">
Esta herramienta sitúa en el documento un objeto 2D que es una vista proyectada de un objeto basado en [[Part Module/es|formas]].
Esta herramienta coloca en el documento un objeto 2D que es una vista aplanada de un objeto seleccionado [[Part_Workbench/es|Shape]], proyectado a lo largo de la dirección de vista actual.
</div>

Draft Shape2DView projections can be displayed on a [[TechDraw_Workbench|TechDraw Workbench]] page using the [[TechDraw_DraftView|TechDraw DraftView]] command. Alternatively the [[TechDraw_Workbench|TechDraw Workbench]] offer its own projection commands. But these create projections that are only displayed on the drawing page and not in the [[3D_view|3D view]].


[[Image:Draft_Shape2DView_example.jpg]]
[[Image:Draft_Shape2DView_example.jpg]]
{{Caption|Projection of solid shapes onto the XY plane}}


<span id="Usage"></span>
==Utilización==
==Utilización==


<div class="mw-translate-fuzzy">
# Selecciona el objeto que quieres extraer a una vista 2D
# Selecciona el objeto que quieres extraer a una vista 2D
# Presiona el botón {{KEY|[[Image:Draft Shape2DView.png|16px]] [[Draft Shape2DView/es|Vista de forma 2D]]}}
# Presiona el botón {{KEY|[[Image:Draft Shape2DView.png|16px]] [[Draft Shape2DView/es|Vista de forma 2D]]}}
</div>


==How to produce plans and sections with different linewidths==
==Opciones==


[[Image:Draft_shape2dview_example_plan.png|700px]]
* Si el objeto seleccionado es un [[Arch SectionPlane/es|Plano de sección de arquitectura]], la proyección 2D será del contenido del plano de sección, y el vector de proyección se tomará del plano de sección en lugar de debajo de la propiedad de Projección.
* El modo de funcionamiento normal es '''Sólido''', que proyecta la forma completa, pero si seleccionas algunas caras del objeto base cuando se crea la vista 2D, también puedes establecer el modo '''Caras individuales''', que proyectará sólo las caras que están seleccionadas.
* Si el objeto seleccionado es una [[Arch SectionPlane/es|Sección Plana de arquitectura]], está disponible un modo de proyección '''líneas de corte''', que proyecta sólo las aristas que son cortadas por el plano de sección.


Drawings with different linewidths for viewed and cut lines can easily be produced by using two shape2Dview objects from a same [[Arch_SectionPlane|Arch SectionPlane]]. One of the shape2Dview objects has its projection mode set to '''Solid''', which renders the viewed lines, and another set to '''Cut lines''' or '''Cut faces''' to render the cut lines. The two shape2Dviews are then placed at the same location, one on top of the other.

<span id="Properties"></span>
==Propiedades==
==Propiedades==


See also: [[Property_editor|Property editor]].
* {{PropertyData|Projection}}: The direction of the projection.

* {{PropertyData|Projection Mode}}: The mode of the projection: solid, individual faces, or cutlines.
A Draft Shape2DView object is derived from a [[Part_Part2DObject|Part Part2DObject]] and inherits all its properties. It also has the following additional properties:

===Data===

{{TitleProperty|Draft}}

<div class="mw-translate-fuzzy">
* {{PropertyData|Projection}}: La dirección de la proyección
* {{PropertyData|Projection Mode}}: El modo de la proyección: sólido, caras individuales o líneas de corte.
</div>

===View===

{{TitleProperty|Draft}}

* {{PropertyView|Pattern|Enumeration}}: not used.
* {{PropertyView|Pattern Size|Float}}: not used.


==Scripting==
==Scripting==


<div class="mw-translate-fuzzy">
The Draft Shape2DView tool can by used in [[macros]] and from the python console by using the following function:
==Programación==
</div>


<div class="mw-translate-fuzzy">
<syntaxhighlight>
La herramienta de vista 2D de forma se puede utilizar en [[macros/es|macros]] y desde la consola de Python utilizando la siguiente función:
makeShape2DView (object,[projection],[facenumbers])
</div>
</syntaxhighlight>
* Adds a 2D shape to the document, which is a 2D projection of the given object.
* A specific projection vector can also be given.
* Returns the generated object.
* You can also provide a list of face numbers to be considered.


{{Code|code=
Example:
shape2dview = make_shape2dview(baseobj, projectionVector=None, facenumbers=[])
}}


<div class="mw-translate-fuzzy">
<syntaxhighlight>
* Añade una forma 2D al documento, la cual es una proyección 2D del objeto dado.
import FreeCAD,Draft
* Se puede indicar un vector de proyección específico.
Draft.makeShape2DView(FreeCAD.ActiveDocument.ActiveObject)
* Devuelve el objeto generado.
</syntaxhighlight>
* También puedes proporcionar una lista de números de caras a considerar.
</div>


Change the {{incode|ProjectionMode}} property of the created object if required. It can be: {{incode|"Solid"}}, {{incode|"Individual Faces"}}, {{incode|"Cutlines"}}, {{incode|"Cutfaces"}} or {{incode|"Solid faces"}}.
<languages/>

Ejemplo:

{{Code|code=
import FreeCAD as App
import Draft

doc = App.newDocument()

box = doc.addObject("Part::Box", "Box")
box.Length = 2300
box.Width = 500
box.Height = 1000

shape1 = Draft.make_shape2dview(box)

shape2 = Draft.make_shape2dview(box, App.Vector(1, -1, 1))

shape3 = Draft.make_shape2dview(box, App.Vector(-1, 1, 1), [0, 5])
shape3.ProjectionMode = "Individual Faces"

doc.recompute()
}}


{{Docnav
|[[Draft_FlipDimension|FlipDimension]]
|[[Draft_SelectPlane|SelectPlane]]
|[[Draft_Workbench|Draft]]
|IconL=Draft_FlipDimension.svg
|IconR=Draft_SelectPlane.svg
|IconC=Workbench_Draft.svg
}}

{{Draft Tools navi{{#translation:}}}}
{{Userdocnavi{{#translation:}}}}

Latest revision as of 19:51, 29 April 2023

Draft Shape2DView

Ubicación en el Menú
Boceto → Vista de forma 2D
Entornos de trabajo
Boceto, Arquitectura
Atajo de teclado por defecto
Ninguno
Introducido en versión
-
Ver también
Ninguno

Descripción

Esta herramienta coloca en el documento un objeto 2D que es una vista aplanada de un objeto seleccionado Shape, proyectado a lo largo de la dirección de vista actual.

Draft Shape2DView projections can be displayed on a TechDraw Workbench page using the TechDraw DraftView command. Alternatively the TechDraw Workbench offer its own projection commands. But these create projections that are only displayed on the drawing page and not in the 3D view.

Projection of solid shapes onto the XY plane

Utilización

  1. Selecciona el objeto que quieres extraer a una vista 2D
  2. Presiona el botón Vista de forma 2D

How to produce plans and sections with different linewidths

Drawings with different linewidths for viewed and cut lines can easily be produced by using two shape2Dview objects from a same Arch SectionPlane. One of the shape2Dview objects has its projection mode set to Solid, which renders the viewed lines, and another set to Cut lines or Cut faces to render the cut lines. The two shape2Dviews are then placed at the same location, one on top of the other.

Propiedades

See also: Property editor.

A Draft Shape2DView object is derived from a Part Part2DObject and inherits all its properties. It also has the following additional properties:

Data

Draft

  • DatosProjection: La dirección de la proyección
  • DatosProjection Mode: El modo de la proyección: sólido, caras individuales o líneas de corte.

View

Draft

  • VistaPattern (Enumeration): not used.
  • VistaPattern Size (Float): not used.

Scripting

Programación

La herramienta de vista 2D de forma se puede utilizar en macros y desde la consola de Python utilizando la siguiente función:

shape2dview = make_shape2dview(baseobj, projectionVector=None, facenumbers=[])
  • Añade una forma 2D al documento, la cual es una proyección 2D del objeto dado.
  • Se puede indicar un vector de proyección específico.
  • Devuelve el objeto generado.
  • También puedes proporcionar una lista de números de caras a considerar.

Change the ProjectionMode property of the created object if required. It can be: "Solid", "Individual Faces", "Cutlines", "Cutfaces" or "Solid faces".

Ejemplo:

import FreeCAD as App
import Draft

doc = App.newDocument()

box = doc.addObject("Part::Box", "Box")
box.Length = 2300
box.Width = 500
box.Height = 1000

shape1 = Draft.make_shape2dview(box)

shape2 = Draft.make_shape2dview(box, App.Vector(1, -1, 1))

shape3 = Draft.make_shape2dview(box, App.Vector(-1, 1, 1), [0, 5])
shape3.ProjectionMode = "Individual Faces"

doc.recompute()