Archicad 28 C++ API
|
Functions related to the View Settings, zoom and various other View-related functionality. More...
Classes | |
class | ACAPI::ModelViews::v1::View |
A class that represents an Archicad navigator view. More... | |
struct | API_Box |
Rectangular region of the model. More... | |
struct | API_RGBAColor |
RGB color reference with transparency. More... | |
struct | API_Rect |
Rectangle in pixel coordinates. More... | |
struct | API_Tranmat |
A 3*4 transformation matrix. More... | |
struct | API_StoryType |
Parameters of one story. More... | |
struct | API_AxonoPars |
Parallel projection parameters. More... | |
struct | API_GhostStoryType |
Ghost Story settings. More... | |
struct | API_GhostRecord |
Describes a tracing (ghost) database. More... | |
struct | API_StoryInfo |
Story information of the active project. More... | |
struct | API_StoryCmdType |
Parameters of the change story settings command. More... | |
struct | API_3DProjectionInfo |
3D projection setting parameters. More... | |
struct | API_3DFilterAndCutSettings |
Parameters of the 'Filter and Cut Elements in 3D' dialog. More... | |
struct | API_3DWindowInfo |
3D Window setting parameters. More... | |
struct | API_3DStyle |
3D Style parameters. More... | |
struct | API_3DCutShapeType |
Shape of the 3D cutting plane. More... | |
struct | API_3DCutPlanesInfo |
Data of the "3D Cutting Planes..." dialog. More... | |
struct | API_UniformAttributeOptions |
General representation of a Model Display in 3D Document. More... | |
struct | API_SkeletonOptions |
Skeleton drawing options. More... | |
struct | API_DocumentFrom3DDefaults |
Default settings of 3D document. More... | |
struct | API_DocumentFrom3DType |
Represents a 3D Document. More... | |
Enumerations | |
enum | API_ShowGhostType { APIGhost_NoFloor = 0 , APIGhost_ShowOneFloor , APIGhost_ShowAboveFloor , APIGhost_ShowBelowFloor , APIGhost_ShowPreviousFloor , APIGhost_ShowAllStructure } |
Represents the way of the ghost to be shown. | |
enum | API_StoryCmdID { APIStory_GoTo , APIStory_Delete , APIStory_InsAbove , APIStory_InsBelow , APIStory_SetHeight , APIStory_Rename , APIStory_SetElevation , APIStory_SetDispOnSections } |
Action codes for the story settings command. More... | |
enum | API_3DFilterModeID { API_FilterByRules , API_FilterBySelection , API_FilterByMarqueeAndRules } |
The enumeration of the available 3D filter modes. More... | |
enum | API_3DModelTypeID { API3DModel_Block = 0 , API3DModel_WireFrame , API3DModel_Hiddenline , API3DModel_Shading } |
Model image type in the 3D window. More... | |
enum | API_ShadingContoursID { APIShadContours_Draft = 0 , APIShadContours_Off , APIShadContours_Best } |
Contour visibility options for shaded image mode in the 3D window. More... | |
enum | API_VectorShadowID { APIVectShad_Off = 0 , APIVectShad_ContOff_AllSurf , APIVectShad_ContOn_AllSurf , APIVectShad_ContOff_OneLevel , APIVectShad_ContOn_OneLevel } |
Options for vectorial sun shadow generation in the 3D window. More... | |
enum | API_SpecFolderID { API_ApplicationPrefsFolderID = 1 , API_GraphisoftPrefsFolderID , API_GraphisoftHomeFolderID , API_CacheFolderID , API_DataFolderID , API_UserDocumentsFolderID , API_TemporaryFolderID , API_ApplicationFolderID , API_DefaultsFolderID , API_WebObjectsFolderID , API_TemplatesFolderID , API_HelpFolderID , API_EmbeddedProjectLibraryFolderID , API_EmbeddedProjectLibraryHotlinkFolderID } |
The selector of special folders. | |
enum | API_3DCutSurfFills { API_3DDocumentVectorFilles = 1 , API_3DDocumentUniformMaterial = 2 , API_3DDocumentOwnMaterial = 3 , API_3DDocumentOwnShadedMaterial = 4 } |
How to display the cut surfaces. | |
enum | API_3DUncutSurfaceFillType { API_3DDocumentPenColor = 1 , API_3DDocumentMaterialColorShaded = 2 , API_3DDocumentMaterialColorNonShaded = 3 } |
How to display the uncut surfaces. | |
enum | API_3DHiddenEdgeVisibility { API_3DDocumentHideHiddenEdges , API_3DDocumentShowHiddenEdges } |
Show or hide hidden edges. | |
enum | API_3DOnCutPlaneVisibility { API_3DDocumentDontShowOnCutPlanes , API_3DDocumentShowOnCutPlanes } |
Show or hide hidden cut lines. | |
enum | API_DocumentSourceID { API_DDD = 1 , API_FloorPlan = 2 } |
3D Document source. | |
enum | API_ViewSourceID { API_Top = 1 , API_Bottom = 2 } |
Skeleton drawing 3D Document view source. | |
Functions | |
Result< View > | ACAPI::ModelViews::v1::FindViewByGuid (const API_Guid &guid) |
Constuct a view object referring to an existing Archicad view by guid. | |
GSErrCode | ACAPI_View_Redraw () |
Redraws the content of the current window. | |
GSErrCode | ACAPI_View_Rebuild (bool *doRebuildAndRegenerate=nullptr) |
Rebuilds the content of the current window. | |
GSErrCode | ACAPI_View_Zoom (API_Box *zoomBox=nullptr, API_Rect *zoomRect=nullptr, API_Tranmat *tranmat=nullptr) |
Performs a zoom operation. | |
GSErrCode | ACAPI_View_ZoomToSelected () |
Zooming to the actual selection. (Even in 3D.) | |
GSErrCode | ACAPI_View_ZoomToElements (const GS::Array< API_Guid > *elemsToZoom) |
Zoom to the given elements. | |
GSErrCode | ACAPI_View_GoToView (const char *viewGuidStr) |
Switches to the given navigator view. | |
GSErrCode | ACAPI_View_CoordToPoint (API_Coord *coord, API_Point *point) |
Convert a model coordinate to screen in the current database. | |
GSErrCode | ACAPI_View_PointToCoord (API_Point *point, API_Coord *coord) |
Convert a screen coordinate into model coordinate in the current database. | |
GSErrCode | ACAPI_View_SetZoom (API_Box *zoomBox=nullptr, API_Tranmat *tranmat=nullptr) |
Sets the zoom box of the current database. | |
GSErrCode | ACAPI_View_GetZoom (API_Box *zoomBox=nullptr, API_Tranmat *tranmat=nullptr) |
Returns the actual zoom parameters of the current database. | |
GSErrCode | ACAPI_View_ResetZoom (short *numOfStepsBack) |
Restores the zoom parameters of the current database by a given number of steps. | |
GSErrCode | ACAPI_View_StoreViewSettings (bool store) |
Stores/restores the actual view settings. | |
GSErrCode | ACAPI_View_IsAutoGroupOn (bool *autoGrp) |
Returns the current state of the autogroup mode. | |
GSErrCode | ACAPI_View_IsSuspendGroupOn (bool *suspGrp) |
Returns the current state of the Suspend Groups mode. | |
GSErrCode | ACAPI_View_CreateGhostRecord (const API_GhostRecord *ghostRecord) |
Create a new Trace (ghost) database. | |
GSErrCode | ACAPI_View_GetGhostRecord (const API_DatabaseUnId *databaseUnId, API_GhostRecord *ghostRecord) |
Retrieve a Trace record from the database. | |
GSErrCode | ACAPI_View_DeleteGhostRecord (const API_GhostRecord *ghostRecord) |
Deletes a Virtual Trace (ghost) record. | |
GSErrCode | ACAPI_View_ChangeGhostRecord (const API_GhostRecord *ghostRecord) |
Change the settings of a Virtual Trace (ghost) record. | |
GSErrCode | ACAPI_View_GetGhostStorySettings (API_GhostStoryType *ghostStoryType) |
Retrieves the current ghost story settings. | |
GSErrCode | ACAPI_View_Get3DProjectionSets (API_3DProjectionInfo *proj3DInfo) |
Returns information on the 3D projection settings. | |
GSErrCode | ACAPI_View_Change3DProjectionSets (API_3DProjectionInfo *proj3DInfo, bool *switchOnlyAxonoOrPersp=nullptr) |
Changes the parameters of the 3D projection. | |
GSErrCode | ACAPI_View_Get3DImageSets (API_3DFilterAndCutSettings *filterAndCutSettings) |
Returns the 3D image item settings. | |
GSErrCode | ACAPI_View_Change3DImageSets (API_3DFilterAndCutSettings *filterAndCutSettings, bool *mustConvert=nullptr) |
Changes the 3D image item settings. | |
GSErrCode | ACAPI_View_Get3DWindowSets (API_3DWindowInfo *windowInfo) |
Retrieves the 3D Window settings. | |
GSErrCode | ACAPI_View_Change3DWindowSets (API_3DWindowInfo *windowInfo) |
Changes the 3D window settings. | |
GSErrCode | ACAPI_View_Get3DStyle (API_3DStyle *style) |
Retrieves all parameters of a 3D style. | |
GSErrCode | ACAPI_View_Change3DStyle (API_3DStyle *style) |
Modifies the parameters of an existing 3D style. | |
GSErrCode | ACAPI_View_Create3DStyle (API_3DStyle *style) |
Creates a new 3D style. | |
GSErrCode | ACAPI_View_Get3DStyleList (GS::Array< GS::UniString > *styles, GS::UniString *current=nullptr) |
Retrieves the names of all styles in the project and/or the name of the current style. | |
GSErrCode | ACAPI_View_SetCurrent3DStyle (const GS::UniString *name) |
Sets an existing style as active. | |
GSErrCode | ACAPI_View_Get3DCuttingPlanes (API_3DCutPlanesInfo *cutInfo) |
Retrieves the 3D cutting plane settings. | |
GSErrCode | ACAPI_View_Change3DCuttingPlanes (API_3DCutPlanesInfo *cutInfo) |
Changes the 3D cutting planes. | |
GSErrCode | ACAPI_View_GetShowHideState (bool *isShown) |
Returns the visibility of application. | |
GSErrCode | ACAPI_View_ChangeShowHideState (bool *toShow) |
Changes the visibility of application. | |
GSErrCode | ACAPI_View_IsAutoIntersectOn (bool *isOn) |
Returns the state of the automatic wall intersection flag. | |
GSErrCode | ACAPI_View_ChangeAutoIntersect (bool *isOn) |
Modifies the automatic wall intersection flag. | |
GSErrCode | ACAPI_View_GetDocumentFrom3DDefaults (API_DocumentFrom3DDefaults *documentFrom3DDefaults) |
Returns the 3D document setting default values. | |
GSErrCode | ACAPI_View_ChangeDocumentFrom3DDefaults (API_DocumentFrom3DDefaults *documentFrom3DDefaults) |
Changes the 3D document setting default values. | |
GSErrCode | ACAPI_View_GetDocumentFrom3DSettings (API_DatabaseUnId *databaseUnId, API_DocumentFrom3DType *documentFrom3DType) |
Returns the 3D document settings of the specified database. | |
GSErrCode | ACAPI_View_ChangeDocumentFrom3DSettings (API_DatabaseUnId *databaseUnId, API_DocumentFrom3DType *documentFrom3DType) |
Changes the 3D document settings of the specified database. | |
GSErrCode | ACAPI_View_ShowSelectionIn3D () |
Activates the 3D window and shows the selected elements. | |
GSErrCode | ACAPI_View_ShowAllIn3D () |
Activates the 3D window and shows the whole model. | |
void | ACAPI_UserInput_ClearElementHighlight () |
Removes element highlights from 2D (floor plan and section) and 3D window. | |
Functions related to the View Settings, zoom and various other View-related functionality.
enum API_3DFilterModeID |
The enumeration of the available 3D filter modes.
enum API_3DModelTypeID |
Model image type in the 3D window.
Contour visibility options for shaded image mode in the 3D window.
enum API_StoryCmdID |
Action codes for the story settings command.
enum API_VectorShadowID |
Options for vectorial sun shadow generation in the 3D window.
void ACAPI_UserInput_ClearElementHighlight | ( | ) |
Removes element highlights from 2D (floor plan and section) and 3D window.
ACAPI_Automate
(ACAPI_View_Redraw). GSErrCode ACAPI_View_Change3DCuttingPlanes | ( | API_3DCutPlanesInfo * | cutInfo | ) |
Changes the 3D cutting planes.
cutInfo | Data of the "3D Cutting Planes..." dialog |
GSErrCode ACAPI_View_Change3DImageSets | ( | API_3DFilterAndCutSettings * | filterAndCutSettings, |
bool * | mustConvert = nullptr |
||
) |
Changes the 3D image item settings.
filterAndCutSettings | [in] Parameters of the 'Filter and Cut Elements in 3D' dialog box |
mustConvert | [in] Optional parameter; if it is not nullptr and its value is true then the function drops the partial conversion data, so that a full rebuild will be performed upon the next Rebuild operation |
GSErrCode ACAPI_View_Change3DProjectionSets | ( | API_3DProjectionInfo * | proj3DInfo, |
bool * | switchOnlyAxonoOrPersp = nullptr |
||
) |
Changes the parameters of the 3D projection.
proj3DInfo | [in] Parameters of the '3D Projection Settings...' dialog |
switchOnlyAxonoOrPersp | [in] Optional parameter. If it is not nullptr and the value is true, only the isPersp field of proj3DInfo is considered |
GSErrCode ACAPI_View_Change3DStyle | ( | API_3DStyle * | style | ) |
Modifies the parameters of an existing 3D style.
style | [in] New parameters of the existing 3D style |
GSErrCode ACAPI_View_Change3DWindowSets | ( | API_3DWindowInfo * | windowInfo | ) |
Changes the 3D window settings.
windowInfo | [in] Parameters of the 3D Window. |
GSErrCode ACAPI_View_ChangeAutoIntersect | ( | bool * | isOn | ) |
Modifies the automatic wall intersection flag.
isOn | Turns on/off the automatic wall intersection. |
GSErrCode ACAPI_View_ChangeDocumentFrom3DDefaults | ( | API_DocumentFrom3DDefaults * | documentFrom3DDefaults | ) |
Changes the 3D document setting default values.
documentFrom3DDefaults | [in] The new default values of the 3D document database. |
GSErrCode ACAPI_View_ChangeDocumentFrom3DSettings | ( | API_DatabaseUnId * | databaseUnId, |
API_DocumentFrom3DType * | documentFrom3DType | ||
) |
Changes the 3D document settings of the specified database.
databaseUnId | [in] The database unique ID of the 3D document database to change parameters for. |
documentFrom3DType | [in] The new parameters. |
GSErrCode ACAPI_View_ChangeGhostRecord | ( | const API_GhostRecord * | ghostRecord | ) |
Change the settings of a Virtual Trace (ghost) record.
ghostRecord | The Trace database to change. |
GSErrCode ACAPI_View_ChangeShowHideState | ( | bool * | toShow | ) |
Changes the visibility of application.
toShow | [in] Application is visible. |
Convert a model coordinate to screen in the current database.
coord | the coordinate to convert |
point | the associated screen coordinate |
GSErrCode ACAPI_View_Create3DStyle | ( | API_3DStyle * | style | ) |
Creates a new 3D style.
style | [in] Parameters of a new 3D style |
GSErrCode ACAPI_View_CreateGhostRecord | ( | const API_GhostRecord * | ghostRecord | ) |
Create a new Trace (ghost) database.
ghostRecord | Information describing the new Trace database. |
GSErrCode ACAPI_View_DeleteGhostRecord | ( | const API_GhostRecord * | ghostRecord | ) |
Deletes a Virtual Trace (ghost) record.
ghostRecord | The Trace database to delete (the parentDatabase and ghostDatabase should be set). |
GSErrCode ACAPI_View_Get3DCuttingPlanes | ( | API_3DCutPlanesInfo * | cutInfo | ) |
Retrieves the 3D cutting plane settings.
cutInfo | [out] Data of the "3D Cutting Planes..." dialog |
GSErrCode ACAPI_View_Get3DImageSets | ( | API_3DFilterAndCutSettings * | filterAndCutSettings | ) |
Returns the 3D image item settings.
filterAndCutSettings | [out] Parameters of the 'Filter and Cut Elements in 3D' dialog box |
GSErrCode ACAPI_View_Get3DProjectionSets | ( | API_3DProjectionInfo * | proj3DInfo | ) |
Returns information on the 3D projection settings.
proj3DInfo | [out] Parameters of the '3D Projection Settings...' dialog |
GSErrCode ACAPI_View_Get3DStyle | ( | API_3DStyle * | style | ) |
Retrieves all parameters of a 3D style.
style | [in/out] Parameters of the 3D Style |
ACAPI_View_Get3DStyle
to get the details of that style. Leaving the style->name field empty is equivalent to setting it to the name of the current style. GSErrCode ACAPI_View_Get3DStyleList | ( | GS::Array< GS::UniString > * | styles, |
GS::UniString * | current = nullptr |
||
) |
Retrieves the names of all styles in the project and/or the name of the current style.
styles | [out] List of the names of all styles in the project. |
current | [out] The name of the currently active style. |
nullptr
if that information is to be ignored, but doing so with both at the same time returns no information. GSErrCode ACAPI_View_Get3DWindowSets | ( | API_3DWindowInfo * | windowInfo | ) |
Retrieves the 3D Window settings.
windowInfo | [out] Parameters of the 3D Window |
GSErrCode ACAPI_View_GetDocumentFrom3DDefaults | ( | API_DocumentFrom3DDefaults * | documentFrom3DDefaults | ) |
Returns the 3D document setting default values.
documentFrom3DDefaults | [out] The default settings of 3D document database. |
GSErrCode ACAPI_View_GetDocumentFrom3DSettings | ( | API_DatabaseUnId * | databaseUnId, |
API_DocumentFrom3DType * | documentFrom3DType | ||
) |
Returns the 3D document settings of the specified database.
databaseUnId | [in] The database unique ID of the 3D document database to get the parameters for. |
documentFrom3DType | [out] The parameters. |
GSErrCode ACAPI_View_GetGhostRecord | ( | const API_DatabaseUnId * | databaseUnId, |
API_GhostRecord * | ghostRecord | ||
) |
Retrieve a Trace record from the database.
databaseUnId | [in] Retrieve the trace record for this database (the parent database unid is given here). |
ghostRecord | [out] The ghost record for that database. |
GSErrCode ACAPI_View_GetGhostStorySettings | ( | API_GhostStoryType * | ghostStoryType | ) |
Retrieves the current ghost story settings.
ghostStoryType | The ghost story settings |
GSErrCode ACAPI_View_GetShowHideState | ( | bool * | isShown | ) |
Returns the visibility of application.
isShown | [out] Application is visible. |
GSErrCode ACAPI_View_GetZoom | ( | API_Box * | zoomBox = nullptr , |
API_Tranmat * | tranmat = nullptr |
||
) |
Returns the actual zoom parameters of the current database.
zoomBox | [out] The actual zoom parameters |
tranmat | [out] Contains the floor plan grid rotation. |
GSErrCode ACAPI_View_GoToView | ( | const char * | viewGuidStr | ) |
Switches to the given navigator view.
viewGuidStr | [in] string representation of the GUID of the navigator view to be generated |
GSErrCode ACAPI_View_IsAutoGroupOn | ( | bool * | autoGrp | ) |
Returns the current state of the autogroup mode.
autoGrp | [out] Autogroup mode is ON or OFF. |
GSErrCode ACAPI_View_IsAutoIntersectOn | ( | bool * | isOn | ) |
Returns the state of the automatic wall intersection flag.
isOn | Tells whether the automatic intersection of walls is turned on. |
GSErrCode ACAPI_View_IsSuspendGroupOn | ( | bool * | suspGrp | ) |
Returns the current state of the Suspend Groups mode.
suspGrp | [out] Suspend Groups mode is ON or OFF. |
Convert a screen coordinate into model coordinate in the current database.
point | [in] the pixel screen coordinate to convert |
coord | [out] the associated model space coordinate |
GSErrCode ACAPI_View_Rebuild | ( | bool * | doRebuildAndRegenerate = nullptr | ) |
Rebuilds the content of the current window.
doRebuildAndRegenerate | [in] Performs a rebuild and regenerate operation instead of a simple rebuild. Optional; considered false (i.e. rebuild only) if omitted. |
GSErrCode ACAPI_View_Redraw | ( | ) |
Redraws the content of the current window.
GSErrCode ACAPI_View_ResetZoom | ( | short * | numOfStepsBack | ) |
Restores the zoom parameters of the current database by a given number of steps.
numOfStepsBack | [in] Number of steps to go back among the previous zoom boxes |
GSErrCode ACAPI_View_SetCurrent3DStyle | ( | const GS::UniString * | name | ) |
Sets an existing style as active.
name | [in] Name of an existing style |
GSErrCode ACAPI_View_SetZoom | ( | API_Box * | zoomBox = nullptr , |
API_Tranmat * | tranmat = nullptr |
||
) |
Sets the zoom box of the current database.
zoomBox | [in] The zoom parameters to set; pass nullptr to set the zoom factor according to the drawing extent. |
tranmat | [in] Transformation matrix (optional parameter). |
GSErrCode ACAPI_View_ShowAllIn3D | ( | ) |
Activates the 3D window and shows the whole model.
GSErrCode ACAPI_View_ShowSelectionIn3D | ( | ) |
Activates the 3D window and shows the selected elements.
GSErrCode ACAPI_View_StoreViewSettings | ( | bool | store | ) |
Stores/restores the actual view settings.
store | [in] stores the settings if not 0 , restore if 0 |
GSErrCode ACAPI_View_Zoom | ( | API_Box * | zoomBox = nullptr , |
API_Rect * | zoomRect = nullptr , |
||
API_Tranmat * | tranmat = nullptr |
||
) |
Performs a zoom operation.
zoomBox | [in] The box to zoom in (optional parameter, can be nullptr) |
zoomRect | [in] Zoom rectangle (optional parameter, alternative of zoomBox, can be nullptr) |
tranmat | [in] Transformation matrix (optional parameter) |
GSErrCode ACAPI_View_ZoomToElements | ( | const GS::Array< API_Guid > * | elemsToZoom | ) |
Zoom to the given elements.
elemsToZoom | [in] Zoom to these elements (cannot be nullptr. |
GSErrCode ACAPI_View_ZoomToSelected | ( | ) |
Zooming to the actual selection. (Even in 3D.)
Constuct a view object referring to an existing Archicad view by guid.
guid | The guid of the view. |
It is compatible with the guid member of the API_NavigatorItem struct.