Class ScreenSpaceVisual3D
- Namespace
- HelixToolkit.Wpf
- Assembly
- HelixToolkit.Wpf.dll
An abstract base class for visuals that use screen space dimensions when rendering.
public abstract class ScreenSpaceVisual3D : RenderingModelVisual3D, IAnimatable, IAddChild
- Inheritance
-
ScreenSpaceVisual3D
- Implements
- Derived
- Inherited Members
- Extension Methods
Constructors
ScreenSpaceVisual3D()
Initializes a new instance of the ScreenSpaceVisual3D class.
protected ScreenSpaceVisual3D()
Fields
ColorProperty
Identifies the Color dependency property.
public static readonly DependencyProperty ColorProperty
Field Value
DepthOffsetProperty
Identifies the DepthOffset dependency property.
public static readonly DependencyProperty DepthOffsetProperty
Field Value
PointsProperty
Identifies the Points dependency property.
public static readonly DependencyProperty PointsProperty
Field Value
Properties
Clipping
Gets or sets the clipping object.
protected CohenSutherlandClipping? Clipping { get; set; }
Property Value
Color
Gets or sets the color.
public Color Color { get; set; }
Property Value
- Color
The color.
DepthOffset
Gets or sets the depth offset. A small positive number (0.0001) will move the visual slightly in front of other objects.
public double DepthOffset { get; set; }
Property Value
- double
The depth offset.
IsRendering
Gets or sets a value indicating whether this instance is being rendered. When the visual is removed from the visual tree, this property should be set to false.
public bool IsRendering { get; set; }
Property Value
Mesh
Gets or sets the mesh.
protected MeshGeometry3D Mesh { get; set; }
Property Value
Model
Gets or sets the model.
protected GeometryModel3D Model { get; set; }
Property Value
Points
Gets or sets the points collection.
public Point3DCollection Points { get; set; }
Property Value
- Point3DCollection
The points collection.
Methods
GeometryChanged(object?, DependencyPropertyChangedEventArgs)
Called when geometry properties have changed.
protected static void GeometryChanged(object? sender, DependencyPropertyChangedEventArgs e)
Parameters
senderobjectThe sender.
eDependencyPropertyChangedEventArgsThe DependencyPropertyChangedEventArgs instance containing the event data.
OnCompositionTargetRendering(object?, RenderingEventArgs?)
The composition target_ rendering.
protected override void OnCompositionTargetRendering(object? sender, RenderingEventArgs? e)
Parameters
senderobjectThe sender.
eRenderingEventArgsThe event arguments.
OnVisualParentChanged(DependencyObject)
Called when the parent of the 3-D visual object is changed.
protected override void OnVisualParentChanged(DependencyObject oldParent)
Parameters
oldParentDependencyObjectA value of type DependencyObject that represents the previous parent of the Visual3D object. If the Visual3D object did not have a previous parent, the value of the parameter is null.
UpdateGeometry()
Updates the geometry.
protected abstract void UpdateGeometry()
UpdateTransforms()
Updates the transforms.
protected abstract bool UpdateTransforms()
Returns
- bool
True if the transform is updated.