The Global ARCHICAD Community

Stay informed. Get help. Share your knowledge.

Discussions about using GRAPHISOFT's tools (API DevKit) for independent software developers

Moderators: Barry Kelly, Karl Ottenstein, LaszloNagy, ejrolon, gkmethy, Tibor Lorántfy, MOREH Tamas, Akos Somorjai, Ed Brown, Mihály Palenik

#284424
Just use ordinary GDL – a GDL add-on is only needed in very exceptional circumstances. Then write an add-on using the general ARCHICAD API to populate and insert the object(s).
Thanks a lot, it's helpful. But could you please provide me with a code snippet how to create a 3D point and render it on the scene.

Thanks
#284455
Take a look at the GDL reference guide for a start. That will explain all you need to know for scripting an object. It's up to you whether the object displays one point or many (or all points).

You can place an instance of this object through an add-on with ACAPI_Element_Create.

The parameters can be populated with one or more points with APIAny_​ChangeAParameterID.

The example projects provide good sample code for using these functions.
#284494
Take a look at the GDL reference guide for a start. That will explain all you need to know for scripting an object. It's up to you whether the object displays one point or many (or all points).
Thanks Ralph. I found out that there is a possibility to import a point cloud from an external file. That flow is suitable for me but I need to use custom point cloud format not supported by Archicad.
Have I got it right that I have to create a GDL object from add on's code and then generate a LCF file? I tried to look into .lcf file and found that it's a GDL script with some binary data, isn't it?
In the GDL guide I found a 'POINTCLOUD' command, but it is not clear how one can use it. And what does it mean 'Point clouds are not displayed by the Internal 3D Engine'? It'a a quote from GDL Reference Guide P.155
What flow could you recommend me?

Thanks
#284496
I can't give detailed advice about point clouds because I haven't personally developed anything based on that technology. I suggest prototyping you workflow on a small scale to explore how these functions work and what the limitations might be. Someone from GS might be able to give more guidance.
#284644
You seem to go more broadly than topic :D

Back to the yafimsky question:
Barry has right. It's hard to get started on GS API. However it's not impossible. I had several attpemts based on documentation and white paper. Recently I have found API Blog which solves all beginners mysteries. For the beginning I suggest two crucial posts by Akos and Tibor:

Here you will solve MDID mistery:
http://archicadapi.graphisoft.com/hello ... and-button
Here you will solve VS2017 compiling issue:
http://archicadapi.graphisoft.com/worki ... tudio-2017
And helo word(this one didn't work for me but probably it was vs2017 problem)
http://archicadapi.graphisoft.com/hello-world

After those 3 post, you should be able to compile examples form API.
Please keep up with those blogs written as a coherent tutorial with each step described it way easier to understand than learning from docs.


Back to the cloud point what kind of file format are you trying to use?
#284672

Back to the cloud point what kind of file format are you trying to use?

We are trying to import custom point cloud format. The question is if it's possible to create abstract point cloud in the scene using GDL objects (the array of points of range 100 K~1 million).

Is it correct that we have to create a GDL object from add on's code, then generate a LCF file and import it?
In the GDL guide there is topic about point cloud and single command 'POINTCLOUD'. But it's not fully clear how to use it in our case. Also what does it mean: "Point clouds are not displayed by the Internal 3D Engine."? (http://gdl.graphisoft.com/reference-guide/point-clouds)

or maybe there is another solution?

Any help would be very appreciated.
#284685
I'm not an expert but the topic is interesting so I did some reading:

It seems that GDL POINTCLOUD uses two standard extensions - xyz and e57:
https://helpcenter.graphisoft.com/guide ... nt-clouds/

So It seems you have right. If you have some custom format you shall translate your format via addon first and then create GDL based on POINCLOUD command. It doesn't seem like the best way to do it in terms of performance.

Note there are some limitations because .lfc's max size:
https://helpcenter.graphisoft.com/troub ... n_ARCHICAD
#287098
Thank very much for your kind.
Back to the yafimsky question:
Barry has right. It's hard to get started on GS API. However it's not impossible. I had several attpemts based on documentation and white paper. Recently I have found API Blog which solves all beginners mysteries. For the beginning I suggest two crucial posts by Akos and Tibor:

Here you will solve MDID mistery:
http://archicadapi.graphisoft.com/hello ... and-button
Here you will solve VS2017 compiling issue:
http://archicadapi.graphisoft.com/worki ... tudio-2017
And helo word(this one didn't work for me but probably it was vs2017 problem)
http://archicadapi.graphisoft.com/hello-world

After those 3 post, you should be able to compile examples form API.
Please keep up with those blogs written as a coherent tutorial with each step described it way easier to understand than learning from docs.