Functions for various purposes.
GSErrCode ACAPI_Goodies ( API_GoodiesID code, void* par1 = nullptr, void* par2 = nullptr, void* par3 = nullptr, void* par4 = nullptr );
Parameters
- code
- [in] Goodie function identifier.
- par1
- [in/out] The parameter depends on the
code
parameter. - par2
- [in/out] The parameter depends on the
code
parameter. - par3
- [in/out] The parameter depends on the
code
parameter. - par4
- [in/out] The parameter depends on the
code
parameter.
Return Values
NoError
- The goodie function completed with success.
APIERR_BADID
- Invalid
code
parameter was passed.
More return values can be found at the description of each goodie functions.
Remarks
This function collects several kind of functions.
Description
General functions
Determines whether the string is a GDL keyword or reserved symbol.
Calculates the sun position in a given place.
Searches an element by a coordinate.
Converts a picture into another image format.
Converts a picture into another image format using MIME types.
Returns the ratio of the font capital size and typography size.
Returns the Guid of the top level group of a nested group element.
Retrieves the hotlink element which contains the given element.
Run the element’s GDL parameter script.
Retrieves the the base height of a curtain wall or its subelem.
Retrieves the height of a curtain wall element.
Returns the calculated additional parameters of a curtain wall subelem.
Returns the polygon data of a Skylight hole contour.
Returns user interface priority for a building material connection priority.
Returns the building material connection priority for a priority set on the user interface.
Converts the reveal depth offset from wall side to core skin for wall openings.
Converts the reveal depth offset from core skin to wall side for wall openings.
Returns the owner of the child elem in hierarchical elem.
Returns the HTTP port number, on which Archicad is expecting requests.
Activates the session report window.
Work on Parameter Lists
Opens a Library Part parameter list to edit.
Returns the possible values defined for a Library Part parameter.
Changes a value in an opened Library Part parameter list.
Returns the actual (edited) values of a Library Part parameter list opened to edit.
Closes the Library Part parameter list opened to edit.
Work on Polygons
Inserts a node into a polygon.
Deletes a node from a polygon.
Inserts a whole subpolygon (hole) into a polygon.
Deletes a whole subpolygon (hole) from a polygon.
Regularizes a polygon.
Regularizes a polyline.
Deallocates an API_RegularizedPoly structure.
Decomposes a polygon into triangles.
Work on Neigs
Return the element’s GUID from the neig information, taking sub-elements into account.
Converts an element GUID to the appropriate neig, taking sub-elements into account.
Returns the element type assigned to a neig.
Spline calculation
Returns the distance of a point and a bezier (available from 6.5 R2/v2).
PolygonId Conversion
Returns the surfaceType for the given polygonId.
Inter-addon communication
Initializes a parameter list to pass to an other add-on.
Retrieves the number of the parameters on the parameter list.
Retrieves a parameter from the parameter list.
Appends a parameter to the parameter list.
Modifies a parameter on the parameter list.
Frees the parameter list handle.
Text line length measurement
Returns the length of a given text line.
Texture coordinates
Returns the texture coordinate system of a given point of a given polygon on a given body.
Library part unique ID functions
Gets the GUID of a built in library part.
Checks whether a library part unique ID refers to a subtype of another.
Compares two library part unique IDs.
Returns the unique ID of the creator tool of the specified object.
Sets the unique ID of the empty hole.
Returns the library part unique identifier of the GDL based element.
Returns the library part’s creator element type and variation ID.
Checks whether a library part unique ID refers to a subtype of another.
Text element manipulation
Changes the content of a text or a textual label element.
Autotext manipulation
Returns the mode flag currently set for autotext replacing in retrieved texts.
Switches autotexts to be replaced with their current values or kept as autotext keys in retrieved texts.
Retrieves all possible context dependent autotext names and their corresponding keys.
Retrieves the autotext value for a context dependent autotext key.
Retrieves all autotext keys and their values.
Retrieves the key, description and value of the currently available autotexts.
Sets the value of an autotext.
Creates a new entry in the Project Info.
Deletes a custom entry in the Project Info.
Visual Override helpers
Enables graphical overrides during
ACAPI_Element_ShapePrims
.
Renovation helpers
Enables renovation graphical overrides during
ACAPI_Element_ShapePrims
.Returns the name of the given renovation filter.
Returns the name of the given renovation status.
IFC helpers
Returns if elem has visible skin depending on partial structure display.
Returns an opening’s position and normal vector.
Stair element helpers
Checks and corrects a Stair’s baseline, if it’s invalid.
Property helpers
Checks if the given property expression is a syntactically valid one.
Returns the string that can be used in expressions to refer to a specific property.
GDL helpers
Interprets a 3D GDL script with the same settings as GDL Editor.
From version 26 the GetElemTypeNameID goodie was moved to a separate ACAPI_Goodies_GetElemTypeName function.
From version 26 the ElemTypeToNeigID goodie was moved to a separate ACAPI_Goodies_ElemTypeToNeigID function.
From version 26 the NeigIDToElemTypeID goodie was moved to a separate ACAPI_Goodies_NeigIDToElemType function.
Requirements
- Version: API 2.1 or later
- Header: ACAPinc.h