This is the discussion forum for Helix Toolkit.
For bugs and new features, use the issue tracker located at GitHub.
Also try the chat room!

Is there a functionality for model hit with some tolerance?

kotsabiukmv98 2 years ago in Question updated by atsselidbe 2 months ago 11

For example, when I try hit model 3 pixels aside model will be hit.


AddExtrudedGeometry problem

MCv 3 years ago in Question 0

Hi Everyone,

I'm trying to create a simple 3d object, extruded one out of 4 pairs of 2D coordinates. But what I'm getting - is a 2d object. I can't understand: it's a my mistake or something else is wrong?

Here is my xaml code:

        <helix:HelixViewport3D x:Name="view1" Background="LightBlue" IsHeadLightEnabled="True" >

            <helix:MeshGeometryVisual3D  MeshGeometry="{Binding GlassGeometry}" Fill="White"/>

And code behind method:

  public MeshGeometry3D GlassGeometry
                var builder = new MeshBuilder(true, true);                 List<Point> pints2D = new List<Point>()
                    new Point(-1, -1),
                    new Point(0, -1),
                    new Point(1, 1),
                    new Point(-1, 1)
                Point3D sp = new Point3D(0, 0, 0);
                Point3D ep = new Point3D(0, 0, 1);

               builder.AddExtrudedGeometry(pints2D, new Vector3D(1,0, 0), sp, ep);

                return builder.ToMesh(true);

What I'm expecting to see is just a cube(in this case). But in the future I would like to get something like this:

But now my result looks like:

Or is it a possibility to create a 3d Object in code using 8 pairs of 3D coordinates?

Thank you in advance.


Reference bugs in examples/source?

zangatsu 5 years ago in Question updated 5 years ago 0

Hi I just downloaded the newest source of the helix-toolkit. I wanted to get through all the examples to learn about the application, but unfortunately I get a lot of reference errors and I do not know why. I could solve most of them by reinstalling NuGetPackages and adjusting the fakes assemblies, however there are still a lot left. For example in MainViewModel:BaseViewModel class I get the reference error:

Error CS0246 The type or namespace name 'Camera' could not be found (are you missing a using directive or an assembly reference?) DemoCore _NET40 C:\..\helix-toolkit-master\Source\Examples\WPF.SharpDX\DemoCore\BaseViewModel.cs 29 Active.

This goes on with RenderTechnique, IEffectsManager and so on.

Do you have any solution? My references in DemoCore_NET40 all seem to work fine, at least I am getting no yellow symbol in the solution explorer...


How to use ExtrudedVisual3D to get a solid shape

jclu98 5 years ago in Question updated by anonymous 1 year ago 2

I was able to use ExtrudedVisual3D to get a extruded shape along a 3D path. But how do I make it solid? Right now, the extruded shape I got is hollow (means you can see through). How do I make it solid or at least add caps to both ends. I already spent many days on this but still could not figure out.


Viewcube image

Denwood 5 years ago in Question updated by anonymous 2 years ago 4
I want to add an image to my Helix viewcube( all 6 directions). How to do it?

Show wireframe as quads with Helix and SharpDX

Raul Burgos 6 years ago in Question updated by made seo 8 hours ago 270
Is it possible to get this effect ( Connected Mesh to QuadFaces ) in the viewportDX when a .OBJ model is readed on it?.
I'm using HelixToolkit.Wpf.SharpDX.
Somebody can post a example?
Thanks in advance.


Touch operation issues

greentea175 1 year ago in Question updated by Mark Tan 3 weeks ago 6


The sample ModelViewer is operated by touch.

Open \Models\obj\wall12.obj.

After expanding wall12.obj,

Even if you move your finger over this model, you cannot rotate or zoom in smoothly.

With mouse operation, you can rotate and zoom smoothly.

It seems that OnManipulationDelta() of CameraController.cs is hard to occur. . .

\Models\obj\leone.3DBuilder.obj can be rotated and enlarged smoothly by touch operation.

I want to rotate and zoom in smoothly even with touch operation.

Please tell me how.

Thank you.


Color Interpolation for object surface

Ehsan M.A. 4 years ago in Question updated by anonymous 2 years ago 2

I have a mesh, say for example a triangle with three corners p1, p2 and p3.

i want to create a gradient that cause for example color C1 in P1 corner of triangle, C2 in P2 corner and C3 in P3 corner. Please note that C1 and C2 and C3 are different.

Any idea on how to do it?


I can't use Helix toolkit to viewport multiple model part at the same time

Philip 4 years ago in Question updated by anonymous 3 years ago 1

Hi Everyone,

I've got an existing Winsform application that model a multi-joint robotic arm, that allows the user to use a trackbar to rotate each joint for a certain degree (snipping of the winsform app below).

Since I've worked out the TranslateTransform and RotateTransform relationship in 2D drawing, I did like to convert it to 3D. I heard that helix toolkit is very good at 3D modelling things. Since I never used it before, so I would like to give helix toolkit a try. What I'm doing is draw the robot arm in wpf and use elementhost to host the drawing in winsform, and in the end aim to achieve the same results as above but in 3D. Currently I applied the same logic I used for the 2D modelling, but with set rotation angle and translation length, as well as I'm trying to get 2 joints connected.

Yet when I run my code, instead of both joints being display (similar to picture above), only 1 joint is present (as shown in picture below).

I don't understands what I did wrong, and since there is very limited documentation available I can't debug and solve the problem myself. So I hope to seek help and solution here.

below is my code:

using System;

using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
using System.IO.Ports;
using System.Windows.Threading;
using HelixToolkit.Wpf;
using HelixToolkit;
using System.Windows.Media.Media3D;

namespace _3DModel
/// <summary>
/// Interaction logic for Drawing.xaml
/// </summary>
public partial class Drawing : UserControl
HelixViewport3D viewport = new HelixViewport3D();

public Drawing()

private void Draw()

#region Camera Viewpoint of the 3D Model
viewport.DefaultCamera = new PerspectiveCamera();
viewport.DefaultCamera.Position = new Point3D(0, 600, 600);
viewport.DefaultCamera.LookDirection = new Vector3D(0, -600, -600);
viewport.DefaultCamera.UpDirection = new Vector3D(0, 1, 0);

DefaultLights light = new DefaultLights();
Model3D joint2, joint3, joint4, joint5, joint6, joint7, baselink;
ModelVisual3D model3d = new ModelVisual3D();
Model3DGroup group = new Model3DGroup();
ModelImporter import = new ModelImporter();

baselink = import.Load(@"C:\Users\tombf\Desktop\Winsform 3D Model\Base Link.obj");
joint2 = import.Load(@"C:\Users\tombf\Desktop\Winsform 3D Model\Link.obj");
joint3 = joint2.Clone();
joint4 = joint2.Clone();
joint5 = joint2.Clone();
joint6 = joint2.Clone();
joint7 = joint2.Clone();

#region Base Link
Transform3DGroup baseLinkMove = new Transform3DGroup();
TranslateTransform3D baseLinkTranslate = new TranslateTransform3D();
baseLinkTranslate.OffsetX = 0;
baseLinkTranslate.OffsetY = 0;
baseLinkTranslate.OffsetZ = 0;


RotateTransform3D baseLinkRotate = new RotateTransform3D();
baseLinkRotate.Rotation = new AxisAngleRotation3D(new Vector3D(0, 0, 0), 0);
baselink.Transform = baseLinkMove;

model3d.Content = group;

#region 1st Joint
Transform3DGroup firstJointMove = new Transform3DGroup();
TranslateTransform3D firstJointTranslate = new TranslateTransform3D();
firstJointTranslate.OffsetX = 10;
firstJointTranslate.OffsetY = 0;
firstJointTranslate.OffsetZ = 0;


RotateTransform3D firstJointRotate = new RotateTransform3D();
firstJointRotate.Rotation = new AxisAngleRotation3D(new Vector3D(0, 0, 0), 10);
joint2.Transform = firstJointMove;
model3d.Content = group;


Transform3DGroup arm = new Transform3DGroup();

TranslateTransform3D armTranslate = new TranslateTransform3D();
RotateTransform3D armRotate = new RotateTransform3D(new AxisAngleRotation3D(new Vector3D(0, 0, 1), 0));
armTranslate.OffsetX = 0;
armTranslate.OffsetY = 0;
armTranslate.OffsetZ = 0;
baselink.Transform = arm;
baselink.Transform = arm;
model3d.Content = group;

armTranslate = new TranslateTransform3D();
armRotate = new RotateTransform3D(new AxisAngleRotation3D(new Vector3D(0, 0, 1), 180));
armTranslate.OffsetX = 20;
armTranslate.OffsetY = 0;
armTranslate.OffsetZ = 0;
joint2.Transform = arm;
joint2.Transform = arm;
model3d.Content = group;


[SharpDX] Why does my model look better when using the deferred RenderTechnique instead of e.g. Blinn/Phong

Daniel Zibion 4 years ago in Question updated 4 years ago 1

Hello everyone,

When visualizing geometry in the sharpDX viewport, I noticed that all the edges are very jagged and not smooth at all.

Blinn Rendering

Deferred Rendering

This got a lot better when switching to the deferred rendering.

Is this normal? Is there maybe a way to improve the anti aliasing for the default rendering that I'm not aware of?