Click or drag to resize
AB4D logo

SceneNodeFactoryRegisterModel3DToSceneNodeCreator Method

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.

Namespace: Ab3d.DirectX.Models
Assembly: Ab3d.DXEngine.Wpf (in Ab3d.DXEngine.Wpf.dll) Version: 6.1.8746.1045
Syntax
C#
public static void RegisterModel3DToSceneNodeCreator(
	SceneNodeFactoryModel3DToSceneNodeCreatorDelegate creatorFunction
)

Parameters

creatorFunction  SceneNodeFactoryModel3DToSceneNodeCreatorDelegate
Model3DToSceneNodeCreatorDelegate to method that returns SceneNode
Remarks

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.

See Also