WpfModelVisual3DNode not following its parent
When you change a transformation of a SceneNode, you need to notify all SceneNode parents and all its children about that change.

This is done with the following code:

// Because our transformation has changed, parent SceneNodes should update their bouding boxes                
// Also notify all child nodes that they need to update the world matrix

When you use WPF 3D objects like BoxVisual3D or other Visual3D objects, those notifications are done automatically by the WpfModelVisual3DNode that represents the ModelVisual3D objects in the DXEngine's SceneNode hierarchy.

But when you use SceneNodes directly, you need to notify the "interested" SceneNodes manually. Also when you change a setting in a DXEngine's material you need to notify the SceneNodes that use that material about the material change: NotifySceneNodeChange(SceneNodeDirtyFlags.MaterialChanged)
Andrej Benedik

Messages In This Thread
RE: WpfModelVisual3DNode not following its parent - by abenedik - 03-07-2018, 12:05 PM

Forum Jump:

Users browsing this thread:
1 Guest(s)