2024 Technology Preview Program:
Master powerful new features and shape the latest BIM-enabled innovations
2022-09-29 09:25 AM
hi,
I am a c++ beginner investigating Archicad APIs.
Is it possible to use Archicad's API to reflect materials on objects (walls and doors) displayed in the project?
If possible, are functions or sample code available in the development kit?
itono,
2022-10-01 10:48 AM
Hi Itono,
Yes you can read and set the building material of elements with the API. The API DevKit includes and example directory. Check the example "Element_Test" for changing/reading/creation of elements. Specifically in "Element_Test\Src\Element_Modify_ChangeParameters.cpp" there are a few lines where the buildingMaterial of a hatch is changed.
For walls it's very similar to that example. For details check the documentation of the wall element type here: https://archicadapi.Graphisoft.com/documentation/api_walltype.
For doors/windows it's a bit more difficult, since you need to change the corresponding GDL parameters. For an intro to that, check out the example "LibPart_Test".
Hope that gives you a first starting point to look into!
Best,
Bernd