DG Kernel Documentation


Skip Navigation Links.
Start page
Quick Start
Search Page
Installation
Overview of the software
What is new
Licensing
Collapse ModelsModels
Expand DG Kernel ComponentsDG Kernel Components
Expand API ReferenceAPI Reference
Expand Samples and TutorialsSamples and Tutorials
Expand GraphicsGraphics
Expand Math ObjectsMath Objects
Expand DeprecatedDeprecated
Redistribution
Model Viewer
Open Source
Support
Skip Navigation LinksHome Page > Models > Entities > Model Items > Smart Labels Search Documentation


Smart Labels

Smart Labels are a special (managed) type of facing labels. They are intended to be associated with a point in 3D space. Normally the point is the center of its parent entity.

Smart Labels are arranged automatically on the screen so they do not overlap and positioned close to the point they are associated with.

See its behaiviour on the Labels>Smart labels example in the Sample Explorer

Smart labels are items. They can be a top-level item or, most often, a child item of an entity.

By default a smart label is positioned on top of its parent object or its associated point. When the label does not fit silhouette of its parent object it is positioned on margins of the 3D window. In any case labels are arranged automatically to avoid overlapping.

Array of all smart labels and related properties are maintaned by Smart Label Manager, which can be accessed via ISmartLabelManager_KC interface queried from IView.

An individual smart label can be accessed via ILabel3D_KC queried from the relevant IItem or via ISmartLabelManager_KC.GetLabel(). Smart labels also implement IText, IDIFont, IItem, ILocation and ITypeBasic_KC.

The Smart Label Manager also implements IDynamicScreenItemManager_KC interface to control smart labels as a generic set of items.

Smart Label Manager keeps a special label, which acts as a template for new labels created with AddNewLabel, CreateLabelsAutomatic or CreateObjectLabelAutomatic. Properties of the template can be accessed via ISmartLabelManager_KC.GetLabelCreationTemplate > ILabel3D_KC

Extended Properties

Smart labels are computationaly intensive during rendering stage. The properties below are related for performance. These options mostly make difference for intersive rendering of large models like during animations. It is recommeded to experiment with the settings to tune in the performance.

Use ISmartLabelManager_KC.GetExtendedProperties() to access the properties.

Property Description Type Parameter ID Default
FavorSpeed When true speed is favored over accuracy Boolean 0 True
CacheHLR When true some extra memory and some initialisation on start is used to accelerate Hidden Label Removal during runtime Boolean 1 True
ReuseSizes When this option is true sizes of text boxes are calculated only when software detects that they are out date, which sometimes can be lagging Boolean 2 True
CacheFlatSectionArray Cache flat entity array for performance. Toggle this option twice to update the array if new sections are addded or removed Boolean 3 True
BoundingObjectScale Copies of bounding obejcts of all sections are scaled (down when <1.0) by this value by hidden label removal algorithm. Clamped to valid range of [0.1, 2.0]. Reduce to show more labels. Can be tuned in by experimenting Double 0 0.8

See also:  Smart Labels Sample,