C# Class HelixToolkit.Wpf.MeshElement3D

Represents a base class for elements that contain one GeometryModel3D and front and back Materials.
Derived classes should override the Tessellate method to generate the geometry.
Inheritance: System.Windows.Media.Media3D.ModelVisual3D, IEditableObject
Show file Open project: litdev1/LitDev

Public Properties

Property Type Description
BackMaterialProperty System.Windows.DependencyProperty
FillProperty System.Windows.DependencyProperty
MaterialProperty System.Windows.DependencyProperty

Public Methods

Method Description
BeginEdit ( ) : void

Begins an edit on an object.

CancelEdit ( ) : void

Discards changes since the last M:System.ComponentModel.IEditableObject.BeginEdit call.

EndEdit ( ) : void

Pushes changes since the last M:System.ComponentModel.IEditableObject.BeginEdit or M:System.ComponentModel.IBindingList.AddNew call into the underlying object.

UpdateModel ( ) : void

Forces an update to the geometry model and materials

Protected Methods

Method Description
GeometryChanged ( DependencyObject d, System.Windows.DependencyPropertyChangedEventArgs e ) : void

The geometry changed.

MaterialChanged ( DependencyObject d, System.Windows.DependencyPropertyChangedEventArgs e ) : void

The material changed.

MeshElement3D ( ) : System.ComponentModel

Initializes a new instance of the MeshElement3D class.

OnFillChanged ( ) : void

The on fill changed.

OnGeometryChanged ( ) : void

The geometry changed.

OnMaterialChanged ( ) : void

The material changed.

Tessellate ( ) : System.Windows.Media.Media3D.MeshGeometry3D

Do the tesselation and return the MeshGeometry3D.

Private Methods

Method Description
FillChanged ( DependencyObject d, System.Windows.DependencyPropertyChangedEventArgs e ) : void

Called when Fill is changed.

Method Details

BeginEdit() public method

Begins an edit on an object.
public BeginEdit ( ) : void
return void

CancelEdit() public method

Discards changes since the last M:System.ComponentModel.IEditableObject.BeginEdit call.
public CancelEdit ( ) : void
return void

EndEdit() public method

Pushes changes since the last M:System.ComponentModel.IEditableObject.BeginEdit or M:System.ComponentModel.IBindingList.AddNew call into the underlying object.
public EndEdit ( ) : void
return void

GeometryChanged() protected static method

The geometry changed.
protected static GeometryChanged ( DependencyObject d, System.Windows.DependencyPropertyChangedEventArgs e ) : void
d System.Windows.DependencyObject /// The d. ///
e System.Windows.DependencyPropertyChangedEventArgs /// The event arguments. ///
return void

MaterialChanged() protected static method

The material changed.
protected static MaterialChanged ( DependencyObject d, System.Windows.DependencyPropertyChangedEventArgs e ) : void
d System.Windows.DependencyObject /// The d. ///
e System.Windows.DependencyPropertyChangedEventArgs /// The event arguments. ///
return void

MeshElement3D() protected method

Initializes a new instance of the MeshElement3D class.
protected MeshElement3D ( ) : System.ComponentModel
return System.ComponentModel

OnFillChanged() protected method

The on fill changed.
protected OnFillChanged ( ) : void
return void

OnGeometryChanged() protected method

The geometry changed.
protected OnGeometryChanged ( ) : void
return void

OnMaterialChanged() protected method

The material changed.
protected OnMaterialChanged ( ) : void
return void

Tessellate() protected abstract method

Do the tesselation and return the MeshGeometry3D.
protected abstract Tessellate ( ) : System.Windows.Media.Media3D.MeshGeometry3D
return System.Windows.Media.Media3D.MeshGeometry3D

UpdateModel() public method

Forces an update to the geometry model and materials
public UpdateModel ( ) : void
return void

Property Details

BackMaterialProperty public static property

Identifies the BackMaterial dependency property.
public static DependencyProperty,System.Windows BackMaterialProperty
return System.Windows.DependencyProperty

FillProperty public static property

Identifies the Fill dependency property.
public static DependencyProperty,System.Windows FillProperty
return System.Windows.DependencyProperty

MaterialProperty public static property

Identifies the Material dependency property.
public static DependencyProperty,System.Windows MaterialProperty
return System.Windows.DependencyProperty