3D Projections in 2D

PROJECT2

PROJECT2 projection_code, angle, method

PROJECT2{2}

PROJECT2{2} projection_code, angle, method [, backgroundColor,
        fillOrigoX, fillOrigoY, filldirection]

Creates a projection of the 3D script in the same library part and adds the generated lines to the 2D parametric symbol.
The 2nd version PROJECT2{2}, together with a previous [SET] FILL command,
allows the user to control the fill background, origin and direction of the resulting drawing from the 2D script.
The SET FILL 0 shortcut to get an empty fill does not work in this case,
you need to reference an actual empty fill.

projection_code: the type of projection.
3: Top view,
4: Side view,
5: Side view 2,
6: Frontal axonometry,
7: Isometric axonometry,
8: Monometric axonometry,
9: Dimetric axonometry,
-3: Bottom view,
-6: Frontal bottom view,
-7: Isometric bottom view,
-8: Monometric bottom view,
-9: Dimetric bottom view.
angle: the azimuth angle set in the 3D Projection Settings dialog box.
method: the chosen imaging method. If invalid or none is set, the default is hidden lines (2).
1: wireframe,
2: hidden lines (analytic),
3: shading,
16: addition modifier: draws vectorial hatches (effective only in shaded mode),
32: addition modifier: use current attributes instead of attributes from 3D (effective in all modes),
64: addition modifier: local fill orientation (effective only in shading mode),
128: addition modifier: lines are all inner lines (effective only together with 32). Default is generic,
256: addition modifier: lines are all contour lines (effective only together with 32, if 128 is not set). Default is generic,
512: addition modifier: fills are all cut (effective only together with 32). Default is drafting fills,
1024: addition modifier: fills are all cover (effective only together with 32, if 512 is not set). Default is drafting fills.
BackgroundColor: background color of the fill.
fillOrigoX: X coordinate of the fill origin.
fillOrigoY: Y coordinate of the fill origin.
filldirection: direction angle of fill.

Note

the [SET] FILL command is effective for PROJECT2{2}

Compatibility note: using PROJECT2 with method bit 32 not set and method bit 3 set (shading),
the model being cut with the CUTPOLYA command without status bit 2 set (generating cut polygons) resulting cut polygon attributes can be different.
Cut polygons will be generated with attributes defined by the SECT_FILL command in the 3D script.

Example:

2D

http://gdl.graphisoft.com/wp-content/uploads/ac19-gdl/2Dshapes_project2_2_1.png
PROJECT2 3, 270, 2

LINE_TYPE "DASHED"
ARC2 0, 0, A-B/3, 0, E

E = 270
A = 1
B = 0.2

ROT2 E
ADD2 A-B/3, 0
LINE2 0, 0, -0.05, -0.1
LINE2 0, 0,  0.05, -0.1

DEL 2
3D

http://gdl.graphisoft.com/wp-content/uploads/ac19-gdl/2Dshapes_project2_2_2.png
n = 12
E = 270
D = 0.2
A = 1
B = 0.2

FOR i=1 TO n
    prism  4, D,
         -B/3, -B/2,
         -B/3,  B/2,
        A-B/3,  B/8,
        A-B/3, -B/8
    ADDZ D
    ROTz E/(n-1)
NEXT i

DEL n*2

 

PROJECT2{3}

PROJECT2{3} projection_code, angle, method, parts [, backgroundColor,
        fillOrigoX, fillOrigoY, filldirection][[,]
        PARAMETERS name1=value1, ..., namen=valuen]

Creates a projection of the 3D script in the same library part and adds the generated lines to the 2D parametric symbol.
The third version, PROJECT2{3}, adds the possibility to define which parts of the projected model are required
and to control separately the attributes of the cut and view part, including the line type.
You can also generate the projection with actual parameters set in the command.

method: the chosen imaging method. If invalid or none is set, the default is hidden lines (2).
1: wireframe,
2: hidden lines (analytic),
3: shading,
16: addition modifier: draws vectorial hatches (effective only in shaded mode),
32: addition modifier: use current attributes instead of attributes from 3D (effective in all modes),
64: addition modifier: local fill orientation (effective only in shading mode),
128: addition modifier: lines are all inner lines (effective only together with 32). Default is generic.
256: addition modifier: lines are all contour lines (effective only together with 32, if 128 is not set). Default is generic.
512: addition modifier: fills are all cut (effective only together with 32). Default is drafting fills.
1024: addition modifier: fills are all cover (effective only together with 32, if 512 is not set). Default is drafting fills.
2048: addition modifier: modifiers 16, 32, 64, 128, 256, 512, 1024 and fill attribute parameters are effective only for the view part of the projection. By default they are effective for all parts.
4096: addition modifier: modifiers 16, 32, 64, 128, 256, 512, 1024 and fill attribute parameters are effective only for the cut part of the projection. By default they are effective for all parts.
8192: addition modifier: vectorial hatches and fills are oriented.
16384: addition modifier: enables transparency for transparent surfaces. Note that transparency in this case means full transparency for surfaces with transmittance greater than 50, everything else is non-transparent.

Known limitation: lines of the cut part cannot be treated separately, only all lines together can be set to be inner or contour.

parts: defines the parts to generate. The 1+2+4+8+16+32 value means all parts.
parts = j1 + 2*j2 + 4*j3 + 8*j4 + 16*j5 + 32*j6, where each j can be 0 or 1.

The j1, j2, j3, j4, j5, j6 numbers represent whether the corresponding parts of the projected model are present (1) or omitted (0):

j1: cut polygons (with default fill attributes defined by SECT_FILL) (effective only in shading mode),
j2: cut polygon edges,
j3: view polygons,
j4: view polygon edges,
j5: project 3D hotspots as static 2D hotspots,
j6: project 3D hotlines and hotarcs (including related 3D hotspots converted to static 2D hotspots).

PROJECT2{4}

PROJECT2{4} projection_code, angle, 
        useTransparency, statusParts,
        numCutplanes,
        cutplaneHeight1, ..., cutplaneHeightn,

        method1, parts1,
        cutFillIndex1,
        cutFillFgPen1, cutFillBgPen1,
        cutFillOrigoX1, cutFillOrigoY1, cutFillDirection1,
        cutLinePen1, cutLineType1,
        projectedFillIndex1,
        projectedFillFgPen1, projectedFillBgPen1,
        projectedFillOrigoX1, projectedFillOrigoY1,
        projectedFillDirection1,
        projectedLinePen1, projectedLineType1,
        ...
        method(numCutplanes+1)), parts(numCutplanes+1),
        cutFillIndex(numCutplanes+1),
        cutFillFgPen(numCutplanes+1), cutFillBgPen(numCutplanes+1),
        cutFillOrigoX(numCutplanes+1), cutFillOrigoY(numCutplanes+1),
        cutFillDirection(numCutplanes+1),
        cutLinePen(numCutplanes+1), cutLineType(numCutplanes+1),
        projectedFillIndex(numCutplanes+1),
        projectedFillFgPen(numCutplanes+1), projectedFillBgPen(numCutplanes+1),
        projectedFillOrigoX(numCutplanes+1), projectedFillOrigoY(numCutplanes+1),
        projectedFillDirection(numCutplanes+1),
        projectedLinePen(numCutplanes+1), projectedLineType(numCutplanes+1)

Compatibility: Introduced in ARCHICAD 20
Creates a projection of the 3D script in the same library part and adds the generated lines to the 2D parametric symbol. The fourth version, PROJECT2{4}, adds the possibility to define multiple cutting planes parallel to the X-Y plane, and to control the attributes of the cut and projected parts of the slices, including the line type, pens and fills. The number of cutplanes can be zero, creating exactly one uncut slice (numCutplanes+1).

useTransparency: can be 0 (no transparency) or positive integer (1: transparency enabled).
statusParts: defines the status parts to generate (hotlines, hotspots, hotarcs). The 1+2 value means all parts. Setting is applied for all slices.
statusParts = j1 + 2*j2, where each j can be 0 or 1.
The j1, j2 numbers represent whether the corresponding status parts of the projected model are present (1) or omitted (0):

j1: project 3D hotspots as static 2D hotspots,
j2: project 3D hotlines and hotarcs (including related 3D hotspots converted to static 2D hotspots).
numCutplanes: the number of defined cutplanes. Can be zero, but preferably more.
cutplaneHeighti: the position of each individually defined cutplane. Measured as length perpendicularly from the X-Y plane of the object.

method: the chosen imaging method. If invalid or none is set, the default is hidden lines (2).

0: the current slice is not part of the projection,
1: wireframe,
2: hidden lines (analytic),
3: shading,
4: hidden lines with polygon: the polygon does not eliminate any polygon or line belonging to parts created with shading method, but will cover/eliminate polygons and lines belonging to other wireframe/hidden line parts. Set it to Air Space for best result. Such exploded polygons will behave in 2D according to slice order (will cover, but not eliminate shaded parts).
16: addition modifier: draws vectorial hatches (effective only in hidden line modes and shaded mode),
32: addition modifier: use current attributes instead of attributes from 3D (effective only in shading mode and hidden line with polygon mode),
64: addition modifier: local fill orientation (effective only in shading mode and hidden line with polygon mode),
128: addition modifier: lines are all inner lines (effective only together with 32). Default is generic.
256: addition modifier: lines are all contour lines (effective only together with 32, if 128 is not set). Default is generic.
512: addition modifier: fills are all cut (effective only together with 32). Default is drafting fills.
1024: addition modifier: fills are all cover (effective only together with 32, if 512 is not set). Default is drafting fills.
2048: addition modifier: modifiers 16, 32, 64, 128, 256, 512, 1024 and fill attribute parameters are effective only for the view part of the projection. By default they are effective for all parts.
4096: addition modifier: modifiers 16, 32, 64, 128, 256, 512, 1024 and fill attribute parameters are effective only for the cut part of the projection. By default they are effective for all parts.
8192: addition modifier: cut fills are slanted.
partsi: defines the parts to generate. The 1+2+4+8+64 value means all parts.
parts = j1 + 2*j2 + 4*j3 + 8*j4 + 64*j7, where each j can be 0 or 1.

The j1, j2, j3, j4, j7 numbers represent whether the corresponding parts of the projected model are present (1) or omitted (0):

j1: cut polygons (with default fill attributes defined by SECT_FILL) (effective only in shading mode),
j2: cut polygon edges,
j3: view polygons,
j4: view polygon edges,
j7: project pointclouds.
cutFillIndexi: fill type index of the cut part of the current slice.
cutFillFgPeni: fill pen of the cut part of the current slice.
cutFillBgPeni: fill background pen of the cut part of the current slice.
cutFillOrigoXi: X coordinate of the cut fill origin of the current slice.
cutFillOrigoYi: Y coordinate of the cut fill origin of the current slice.
cutFillDirectioni: direction angle of the cut fill of the current slice.
cutLinePeni: direction angle of the cut fill of the current slice.
cutLineTypei: direction angle of the cut fill of the current slice.
projectedFillIndexi: fill type index of the projected part of the current slice.
projectedFillFgPeni: fill pen of the projected part of the current slice.
projectedFillBgPeni: fill background pen of the projected part of the current slice.
projectedFillOrigoXi: X coordinate of the projected fill origin of the current slice.
projectedFillOrigoYi: Y coordinate of the projected fill origin of the current slice.
projectedFillDirectioni: direction angle of the projected fill of the current slice.
projectedLinePeni: pen index of projected lines of the current slice.
projectedLineTypei: line type of projected lines of the current slice.