I would like to display any MeshElement3D (for example BoxVisual3d) in helix-toolkit as wireframe. How can this be accomplished?
EDIT:
Thanks to Erno de Weerd's answer I was able to write the following code
Class that extends BoxVisual3D
public class GeometryBoxVisual3D : BoxVisual3D { public MeshGeometry3D Geometry() { return Tessellate(); } }
Add the instance of box to the Viewport:
GeometryBoxVisual3D box = new GeometryBoxVisual3D(); box.Fill = new SolidColorBrush(Colors.Red); Viewport3D.Children.Add(box); MeshGeometry3D geometry3 = box.Geometry(); LinesVisual3D lines = new LinesVisual3D(); lines.Thickness = 3; lines.Points = geometry3.Positions; lines.Transform = new TranslateTransform3D(3,1,1); Viewport3D.Children.Add(lines);
This results in the following display:
If I hide the original box and place LinesVisual3D on top of the box, I can get the wirefrime displayed as if it was original object, but it is still missing the edges on the side.