Nov 1, 2012 at 10:10 AM



Is it possible to use ContainerUIElement3D in conjunction with SortingVisual3D?  I would like sorted visuals that have the power of the ContainerUIElement3D class.


Best regards


Nov 2, 2012 at 10:33 PM

Hi Simon! I have not tried this, but I guess it should be possible. Let us know if there is a bug. And remember that the SortingVisual3D is only a 'basic' work-around for the transparency problem... 

Nov 5, 2012 at 10:08 AM
Edited Nov 5, 2012 at 10:08 AM

Hi Objo

Thanks for replying.  I was asking if it is possible as I can't get it to work.  If I add a ModelUIElement3D object as a child of a ContainerUIElement3D object, and add the ContainerUIElement3D object as a child of a SortingVisual3D object, I find that the mouse events are not fired.

e.g.  (geometry code excluded)

var element = new ModelUIElement3D();
element.Model = geometry;
element.MouseDown += this.ContainerElementMouseDown;
var containerUI = new ContainerUIElement3D();
var uiTransparentElements = new SortingVisual3D();

It is not too big a deal since I could use VisualTreeHelper.HitTest instead of  ContainerUIElement3D, but I was wondering if I was missing something simple.



Nov 5, 2012 at 10:28 AM
Edited Nov 5, 2012 at 10:28 AM

ok, could changing the base class of HelixToolkit.Wpf.RenderingModelVisual help? Try replace ModelVisual3D by ContainerUIElement3D (I am guessing - no time to test right now).

Nov 5, 2012 at 1:33 PM

I did start to try that but unfortunately abandoned as didn't resolve all the build errors.  I will use HitTest workaround for now.  Is it possible to add to future enhancement list?

Thanks, Simon

Nov 6, 2012 at 7:29 PM


Nov 26, 2012 at 11:48 AM
Edited Nov 26, 2012 at 11:48 AM

ContainerUIElement3D is a noniheritable class...

Nov 26, 2012 at 11:53 AM

Then try to add a ContainerUIElement3D to the ModelVisual3D.