Archicad C++ API
About Archicad add-on development using the C++ API.

LINE_PROPERTY question

Jochen Suehlo
Moderator

I built a window with WALLNICHES and Filling Blocks and wanted to have the same line colors and line weights in 2D and sections. In floor plan it works well with the LINE_PROPERTY command, but in section this seems not to work. Are there any alternatives for 3D/section?
See picture below:

Lineproperty.png

Jochen Suehlo . AC12-27 . MAC OSX 14.4 . WIN11
GDL object creation: b-prisma.de
4 REPLIES 4

I always use linetype and pen.  Never have any issues.

Jochen Suehlo
Moderator

The problem is not so easy to solve via line type and pen color.

I will have to explain this in more detail.
Unfortunately, the consistency of the GDL commands is not necessarily consistent and meaningful.
The two screenshots shown are one of a floor plan and one of a section.
In both views there is the following setting:
View >> On-Screen View Options > Bold Cut Lines.
This setting always shows the boundary lines of a wall slightly thicker than a hairline, but not as thick as a real line thickness. This slightly thicker line always has the same thickness even when zooming in. However, the composites separation lines are not thicker, but remain hairlines.

In 2D, these line thicknesses can be reproduced in GDL with the command LINE2 as well as with the POLY2 commands, namely by using the command LINE_PROPERTY.
In the floor plan example shown, the lines marked with the arrows had to be additionally redrawn with LINE2 and ARC2, because the fill surfaces created with the WALLBLOCK2 command cannot represent any border lines.

The problem could therefore be solved relatively easily in 2D.

In 3D and the section generated from it, however, one cannot work with 2D lines but would theoretically have to create a "bent thin sheet" with a thickness of zero so that a line appears at every point of the section. The correct color could be read out with the help of WALL_SKINS_PARAMS, the curved sheet could probably be generated with the help of pieced PLANES, but the representation "Bold Cut Lines" would probably hardly be possible.
This is what I meant as one of the examples of lack of consistency in the GDL commands.

(It is a shame that ArchiCADS windows do not have reveal plaster in 3D after more than 25 years of Archicad, where this topic's issue had to be solved by the way)

Jochen Suehlo . AC12-27 . MAC OSX 14.4 . WIN11
GDL object creation: b-prisma.de

Hmm, I must not see the issue as I never use those primitive elements or I'm just not getting what you are after. I have no issues with bold cut lines in any view..

Peter Baksa
Graphisoft
Graphisoft

Section pens can be set using sect_attrs{2}

These are always cut lines if the section cuts the model, so they are shown bold with On-Screen View Options > Bold Cut Lines.

Péter Baksa
Software Engineer, Library
Graphisoft SE, Budapest