![]() | |
Scene |
public static void RegisterModel3DToSceneNodeCreator( SceneNodeFactoryModel3DToSceneNodeCreatorDelegate creatorFunction )
RegisterModel3DToSceneNodeCreator registers a delegate that will be called for each Model3D that is used in the CreateFromModel3D(Model3D, Effect, DXScene, DictionaryObject, String, String) method. The delegate can be used to provide custom SceneNode from some Model3D objects. If the delegate return null, then the standard creator will be used.
NOTE: The order in which the RegisterModel3DToSceneNodeCreator methods are called is important. Delegates that are registered later are checked first - this way it is possible to first register base types and than specific types.
To unregister a type use the UnRegisterModel3DToSceneNodeCreator(SceneNodeFactoryModel3DToSceneNodeCreatorDelegate) or UnregisterAllModel3DToSceneNodeCreators methods.
Method is thread safe and can be called from any thread.