Draft PointArray/it: Difference between revisions

From FreeCAD Documentation
No edit summary
No edit summary
Line 46: Line 46:
L'oggetto composto di punti può essere creato in diversi modi.
L'oggetto composto di punti può essere creato in diversi modi.
* Creare vari {{Button|[[File:Draft_Point.svg|16px]] [[Draft_Point/it|punti Draft]]}} o {{Button|[[File:Part_Point.svg|16px]] [[Part_Point/it|punti Part]]}}, epoi premere {{Button|[[File:Part_Compound.svg|16px]] [[Part_Compound/it|Crea un composto]]}} per creare il composto .
* Creare vari {{Button|[[File:Draft_Point.svg|16px]] [[Draft_Point/it|punti Draft]]}} o {{Button|[[File:Part_Point.svg|16px]] [[Part_Point/it|punti Part]]}}, epoi premere {{Button|[[File:Part_Compound.svg|16px]] [[Part_Compound/it|Crea un composto]]}} per creare il composto .
* Creare i punti il metodo precedente ma invece di creare un composto usare {{Button|[[Image:Draft_Upgrade.svg|16px]] [[Draft_Upgrade/it|Upgrade]]}} per creare un "Blocco".
* Creare i punti con il metodo precedente ma invece di creare un composto usare {{Button|[[Image:Draft_Upgrade.svg|16px]] [[Draft_Upgrade/it|Upgrade]]}} per creare un "Blocco".
* Crea uno {{Button|[[File:Sketcher_NewSketch.svg|16px]] [[Sketch/it|Schizzo]]}}, e dentro aggiungere vari punti.
* Creare uno {{Button|[[File:Sketcher_NewSketch.svg|16px]] [[Sketch/it|Schizzo]]}}, e dentro aggiungere vari punti.


In essence, the object to be used as the compound must have one of three properties, {{PropertyData|Components}}, {{PropertyData|Links}}, or {{PropertyData|Geometry}}, and inside that compound, there must be at least one point with {{PropertyData|X}}, {{PropertyData|Y}}, and {{PropertyData|Z}} properties.
In essence, the object to be used as the compound must have one of three properties, {{PropertyData|Components}}, {{PropertyData|Links}}, or {{PropertyData|Geometry}}, and inside that compound, there must be at least one point with {{PropertyData|X}}, {{PropertyData|Y}}, and {{PropertyData|Z}} properties.

Revision as of 20:21, 14 July 2020

Serie su punti

Posizione nel menu
Draft → Serie su punti
Ambiente
Draft, Arch
Avvio veloce
Nessuno
Introdotto nella versione
0.18
Vedere anche
Serie, Serie su tracciato

Descrizione

Lo strumento Serie su punti posiziona le copie di una forma selezionata lungo vari punti selezionati.

Questo strumento può essere utilizzato su qualsiasi oggetto che abbia una Part TopoShape, che significa forme 2D create con Draft, ma anche solidi 3D creati con altri ambienti, ad esempio Part, PartDesign o Arch.

Per posizionare le copie in una schiera ortogonale usare Serie; per posizionare le copie su un percorso, utilizzare Serie su percorso; per creare copie o cloni e posizionarli manualmente, utilizzare Sposta, Ruota e Clona.

Oggetto duplicato in punti specifici

Utilizzo

  1. Selezionare un oggetto che si desidera distribuire.
  2. Selezionare un composto di punti.
  3. Premere il pulsante Serie su punti.

Ogni elemento della serie è un clone esatto dell'oggetto originale, ma l'intera serie è considerata una singola unità in termini di proprietà e aspetto.

Composto di punti

L'oggetto composto di punti può essere creato in diversi modi.

In essence, the object to be used as the compound must have one of three properties, DatiComponents, DatiLinks, or DatiGeometry, and inside that compound, there must be at least one point with DatiX, DatiY, and DatiZ properties.

Note: in the case of Draft Point and Part Point the array will try to position the copies using the DatiPlacement of the point. In the case of a Sketcher Point, the position will be taken from its internal X, Y, and Z attributes.

Note 2: for Draft Point its DatiPlacement always follows the values of DatiX, DatiY, DatiZ, so modifying these values is enough to produce the desired displacement. However, for Part Point, the net displacement is given by the sum of DatiPlacement with the vector with components DatiX, DatiY, and DatiZ.

Opzioni

Non ci sono opzioni per questo strumento. O funziona con l'oggetto selezionato o non funziona.

Proprietà

A PointArray is derived from a Part Feature (Part::Feature class), therefore it shares all the latter's properties. In addition to the properties described in Part Feature, the PointArray has the following properties in the property editor.

Objects

  • DatiBase (Link): l'oggetto da duplicare; deve avere una Part TopoShape.
  • DatiCount (Integer): (sola lettura) specifica il numero di copie nella serie. Questa proprietà è di sola lettura perché il numero di copie è determinato dal numero di punti all'interno di DatiPoint Object.
  • DatiExtra Placement (Placement): specifica un posizionamento aggiuntivo, traslazione e rotazione, che verrà applicato a ciascuna copia della serie. Ogni copia appare normalmente con la stessa rotazione dell'oggetto DatiBase; con questa proprietà è possibile fornire una rotazione aggiuntiva o contrastare la rotazione originale e apportare piccole modifiche alla posizione delle copie. introduced in version 0.19
  • DatiPoint Object (Link): specifica un oggetto composto di punti che indicano dove verranno visualizzate le copie dell'oggetto DatiBase. L'oggetto composto deve avere una proprietà DatiLinks, DatiComponents, o DatiGeometry, e contenere almeno un elemento con gli attributi DatiX, DatiY, e DatiZ.

Script

Vedere anche: Draft API e Nozioni di base sugli script di FreeCAD.

Lo strumento PointArray può essere utilizzato nelle macro e dalla console di Python tramite la seguente funzione:

Older call

point_array = makePointArray(base_object, point_object)

New call

point_array = make_point_array(base_object, point_object, extra=None):
  • Crea un oggetto PointArray dall'oggetto base base, posizionando le copie sulla ptlst.
  • ptlst è un oggetto con gli attributi Geometry, Links, o Components che definisce la posizione delle copie.

Esempio:

import FreeCAD as App
import Draft

doc = App.newDocument()

polygon = Draft.make_polygon(3, radius=500.0)

p1 = Draft.make_point(App.Vector(1500, 0, 0))
p2 = Draft.make_point(App.Vector(2500, 0, 0))
p3 = Draft.make_point(App.Vector(2000, 1000, 0))

compound = doc.addObject("Part::Compound", "Compound")
compound.Links = [p1, p2, p3]

point_array = Draft.make_point_array(polygon, compound)
doc.recompute()