Add Entities
add_entitiesBatch add geometric entities like lines, circles, arcs, polylines, text, and dimensions to a DXF modelspace. Specify file path and entity list to populate drawings efficiently.
Instructions
Batch add geometric entities to a DXF drawing's modelspace.
Supported entity types:
- line: {"type": "line", "start": [x1, y1], "end": [x2, y2], "layer": "WALL", "color": 1}
- circle: {"type": "circle", "center": [x, y], "radius": r, "layer": "HOLES"}
- arc: {"type": "arc", "center": [x, y], "radius": r, "start_angle": a1, "end_angle": a2}
- lwpolyline: {"type": "lwpolyline", "points": [[x1, y1], [x2, y2], ...], "is_closed": true}
- rectangle: {"type": "rectangle", "corner1": [x1, y1], "corner2": [x2, y2], "layer": "FRAME"}
- text: {"type": "text", "text": "Label", "insert": [x, y], "height": 3.5}
- mtext: {"type": "mtext", "text": "Multi
Line", "insert": [x, y], "height": 3.5} - point: {"type": "point", "location": [x, y]} - ellipse: {"type": "ellipse", "center": [x, y], "major_axis": [dx, dy, 0], "ratio": 0.5} - dimension_linear: {"type": "dimension_linear", "base": [x, y], "p1": [x1, y1], "p2": [x2, y2], "text": "100mm"} - block_reference: {"type": "block_reference", "block_name": "DOOR", "insert": [x, y], "scale": 1.0, "rotation": 0.0}
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| entities | Yes | ||
| file_path | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||