Choose your top Archicad wishes!

Read more
GDL
About building parametric objects with GDL.

GDL, How to try the OffsetEdge, OffsetPolyline command?

yongler
Enthusiast

How to try the OffsetEdge, OffsetPolyline, OffsetPolylineWithVectors... command?

GDL manual does not provide examples, please request assistance.

7 REPLIES 7
Barry Kelly
Moderator

You mean the commands you can find in the Pet palette?

There are no GDL commands for these.

 

In what context do you want to use them.

 

Barry.

One of the forum moderators.
Versions 6.5 to 27
Dell XPS- i7-6700 @ 3.4Ghz, 16GB ram, GeForce GTX 960 (2GB), Windows 10
Lenovo Thinkpad - i7-1270P 2.20 GHz, 32GB RAM, Nvidia T550, Windows 11

For example, in GDL, if there is a series of point data, it can be assumed that these points form a poly, and then offset this poly to obtain a new poly and vertex data.

 

This is very useful in GDL.

 

I found the offset command description on page 632 of the document "05 GDL Reference Guide. pdf". But there are no examples,

 

It's difficult to understand how to use it.

 

screenshot20230809 (1).pngscreenshot20230809 (2).png

Ah, that is an add-on.

I have never used it.

Having a quick look I can find no examples of using it.

 

Maybe one of the GDL gurus here has some information?

 

Barry.

One of the forum moderators.
Versions 6.5 to 27
Dell XPS- i7-6700 @ 3.4Ghz, 16GB ram, GeForce GTX 960 (2GB), Windows 10
Lenovo Thinkpad - i7-1270P 2.20 GHz, 32GB RAM, Nvidia T550, Windows 11
Lingwisyer
Guru

Did not even know this existed...

 

From a quick read, have you:

Opened the channel for the extension

Created a container

Placed your vertices into the container

Set the OffsetParams / PolylineOffsetVectors

Defined a new array for your vertices

Run the fuction with the relevant "poly1" / "polyline1" matching your container

 

I do not quite get the GET portion, as it looks like it redefines your previous array?

AC22-23 AUS 7000Help Those Help You - Add a Signature
Self-taught, bend it till it breaksCreating a Thread
Win11 | i9 10850K | 64GB | RX6600 Win10 | R5 2600 | 16GB | GTX1660

There is an example in the Example Library of the Libdev Toolkit: Polygon Operations Example.

And there are live examples in the library: Round Table 01, openingsymbol_m.

 

The addon always creates new polygons as a result of an operation. The original ones aren't modified, those can be reused for further operations. There are many cases when an operation results in different number of polygons than the input. For example offseting an edge of a concave polygon can give distinct polygons.

Péter Baksa
Software Engineer, Library as a Platform
Graphisoft SE, Budapest

one example is much too few! Maybe 30 examples with different approaches would be enough!  I tried it several times but didnt get this things to work for me and had to make my own GDL-solutions for things like that.. Many commands in GDL-Cookbook would need much more exaqmples to study for new users. Graphisoft should give muche more examples to us..

AC5.5-AC27EduAut, PC-Win10, MacbookAirM1, MacbookM1Max, Win-I7+Nvidia

Sometimes I feel a little dumb trying to use the examples. Even the GDL center is sometimes having a single example that passes the message that the thing is "obvious", but at the end you're dropping 4 hours into it ant not being able to use it sometimes.
Like MEP coonection, I had a lot of trouble to figure it out.

Archicad User Since 2013
GDL Developer
Experimenting with API
from Brazil

Didn't find the answer?

Check other topics in this Forum

Back to Forum

Read the latest accepted solutions!

Accepted Solutions

Start a new conversation!