Functions related to the manipulation of and accessing the Project Location data and Archicad's related functionalities.
More...
Functions related to the manipulation of and accessing the Project Location data and Archicad's related functionalities.
◆ API_LongLatUnitID
Possible values for longitude and latitude unit preferences.
- Since
- Archicad 26
Enumerator |
---|
APILongLatUnit_DecimalDegree | Show longitude and latitude in decimal degrees
|
APILongLatUnit_DegreeMinSec | Show longitude and latitude in degrees, minutes, seconds
|
◆ ACAPI_GeoLocation_CalcSunOnPlace()
GSErrCode ACAPI_GeoLocation_CalcSunOnPlace |
( |
API_PlaceInfo * | placeInfo | ) |
|
Calculates the sun position in a given place.
- Since
- Archicad 26
- Parameters
-
placeInfo | [in/out] Parameters of the sun place.
API_PlaceInfo |
longitude | required, longitude |
latitude | required, latitude |
sumTime | required, daylight saving on/off |
year | required, year |
month | required, month |
day | required, day |
hour | required, hour |
minute | required, minute |
second | required, second |
time zone | required, time zone in minutes |
north | required, north direction |
sunAngXY | out, the sun angle |
sunAngZ | out, the sun angle |
|
- Returns
- NoError - The function has completed with success.
- APIERR_NOPLAN - no open project
- APIERR_BADPARS - placeInfo is
nullptr
or contains invalid data
- Example
GSErrCode err;
placeInfo.latitude = 19.040236;
placeInfo.sumTime = false;
placeInfo.year= 2001;
placeInfo.month = 11;
placeInfo.day = 11;
placeInfo.hour= 10;
placeInfo.minute = 7;
placeInfo.second = 12;
placeInfo.timeZoneInMinutes = 60;
placeInfo.north = PI / 2;
◆ ACAPI_GeoLocation_CanChangePlaceSets()
GSErrCode ACAPI_GeoLocation_CanChangePlaceSets |
( |
bool * | withDialog | ) |
|
May the current user change the place settings now?
- Parameters
-
withDialog | [in] If the user don't have permisson to change the place settings now, then the Location Dialog will open if this parameter is true, otherwise it will just return whether the user can or can not change the place settings now. This parameter is optional; if you pass nullptr, it defaults to true. |
- Returns
- NoError - The user is allowed to change the place settings.
- APIERR_NOTEDITABLE - The user is not allowed to change the place settings.
- Example
-
◆ ACAPI_GeoLocation_ChangePlaceSets()
GSErrCode ACAPI_GeoLocation_ChangePlaceSets |
( |
API_PlaceInfo * | placeInfo | ) |
|
Changes the place settings.
- Since
- Archicad 26
- Parameters
-
placeInfo | [in] This structure holds the parameters of the place. |
- Returns
- NoError - The function has completed with success.
- APIERR_BADPARS - placeInfo is nullptr or contains invalid data.
- APIERR_NOPLAN - No open project.
- Example
-
◆ ACAPI_GeoLocation_GetGeoLocation()
GSErrCode ACAPI_GeoLocation_GetGeoLocation |
( |
API_GeoLocation * | apiGeoLocation | ) |
|
Returns the Location settings of the project.
- Since
- Archicad 25
- Parameters
-
apiGeoLocation | [out] Location data associated with the project |
- Returns
- NoError - The function has completed with success.
- APIERR_BADPARS - apiGeoLocation is nullptr
- Example
-
◆ ACAPI_GeoLocation_GetPlaceSets()
GSErrCode ACAPI_GeoLocation_GetPlaceSets |
( |
API_PlaceInfo * | placeInfo | ) |
|
Returns information on location parameters.
- Since
- Archicad 26
- Parameters
-
placeInfo | [out] Parameters of the place. |
- Returns
- NoError - The function has completed with success.
- APIERR_BADPARS - placeInfo is nullptr.
- APIERR_NOPLAN - No open project.
- Example
-
◆ ACAPI_GeoLocation_GetSunSets()
GSErrCode ACAPI_GeoLocation_GetSunSets |
( |
API_SunInfo * | sunInfo | ) |
|
Returns information on sun parameters.
- Parameters
-
sunInfo | [out] Parameters of the sun. |
- Returns
- NoError - The function has completed with success.
- APIERR_BADPARS - sunInfo is nullptr.
- APIERR_NOPLAN - No open project.
- Example
-
◆ ACAPI_GeoLocation_SetGeoLocation()
GSErrCode ACAPI_GeoLocation_SetGeoLocation |
( |
API_GeoLocation * | apiGeoLocation | ) |
|
Modifies the Location settings of the project.
- Since
- Archicad 25
- Parameters
-
apiGeoLocation | [in] the Location settings associated with the project |
- Returns
- NoError - The function has completed with success.
- APIERR_BADPARS - apiGeoLocation is nullptr
- APIERR_NOTEDITABLE - The Location settings cannot be modified in Teamwork unless it is reserved by the current user.
- Example
-