Click or drag to resize
Ab4d.SharpEngine logo

AxisWithLabelsNode Class

AxisWithLabelsNode shows one 3D axis with value labels and axis title shown as 3D text objects created with BitmapTextCreator.
Inheritance Hierarchy

Namespace: Ab4d.SharpEngine.SceneNodes
Assembly: Ab4d.SharpEngine (in Ab4d.SharpEngine.dll) Version: 4.0.9584+ba1aaa26d4181dd3fa8ed7b6398391d1affa36c8
Syntax
C#
public class AxisWithLabelsNode : AxisWithLabelsBaseNode

The AxisWithLabelsNode type exposes the following members.

Constructors
Properties
 NameDescription
Public propertyAdjustFirstLabelPosition When true, then the first label is moved up to prevent overlapping the first label with adjacent axis. The amount of movement is calculated by multiplying font size and the LabelAdjustmentFactor (0.45 by default). Default value is false.
Public propertyAdjustLastLabelPosition When true, then the last label is moved down to prevent overlapping the last label with adjacent axis. The amount of movement is calculated by multiplying font size and the LabelAdjustmentFactor (0.45 by default). Default value is false.
Public propertyAxisTitleTextNode Gets the SceneNode that shows axis title.
Public propertyCamera Gets or sets a camera that is showing the 3D scene (usually assigned to SceneView.Camera property). When this Camera object is set, then AxisWithLabelsNode subscribe to camera changes (when UpdateOnCameraChanges is true) and update the text directions based on the camera angles. When Camera object is not set, then text is oriented as it would be viewed with a camera with Heading = 0 and Attitude = 0. In this case it is recommended to call UpdateTextDirections(ICamera) to update the text directions.
Public propertyIsRightToLeftText Gets or sets a Boolean that specifies if text should be written in right to left direction. Default value is false, for left to right direction.
Public propertyLabelAdjustmentFactor Gets or sets a float that specifies a factor that is multiplied by FontSize and used to adjust the position of the first or last label when AdjustFirstLabelPosition or AdjustLastLabelPosition are used. Default value is 0.45.
Public propertyLabelsBitmapTextCreator Gets or sets a BitmapTextCreator that is used to generate the bitmap text for the axis labels. If this property is not set by the user, then AxisWithLabelsNode automatically use the default BitmapTextCreator (get by calling BitmapTextCreator.GetDefaultBitmapTextCreator).
Public propertyTitleBitmapTextCreator Gets or sets a BitmapTextCreator that is used to generate the bitmap text for the axis title. If this property is not set by the user, then AxisWithLabelsNode automatically use the default BitmapTextCreator (get by calling BitmapTextCreator.GetDefaultBitmapTextCreator).
Public propertyUpdateOnCameraChanges Gets or sets a Boolean that specifies if AxisWithLabelsNode subscribe to camera changes of the Camera changes and update the text directions on each camera change. By default, this value is true. When set to false, then it is recommended to manually call UpdateTextDirections to update the text directions.
Public propertyValueLabelsGroupNode Gets the GroupNode that is a parent node to all text nodes used to show value labels.
Top
Methods
 NameDescription
Public methodClone 
Protected methodDispose
(Overrides GroupNodeDispose(Boolean))
Protected methodOnInitializeSceneResources
(Overrides GroupNodeOnInitializeSceneResources(Scene, VulkanDevice))
Protected methodOnTicksPositionsChanged OnTicksPositionsChanged is called when tick positions change.
(Overrides AxisWithLabelsBaseNodeOnTicksPositionsChanged)
Protected methodOnUpdate Updates the axis if needed.
(Overrides AxisWithLabelsBaseNodeOnUpdate)
Public methodUpdateTextDirections UpdateTextDirections method can be called when Camera property is set but UpdateOnCameraChanges is false. When called, it updates the directions of the text based on the current camera.
Public methodUpdateTextDirections(ICamera) UpdateTextDirections method can be called when Camera property is not set, and we want to update the directions of the text based on the specified camera.
Top
Extension Methods
 NameDescription
Public Extension MethodDumpHierarchy Writes the hierarchy of the GroupNode and its children into the Visual Studio Output window.
(Defined by Extensions)
Top
See Also