nw::demo::Utility::BindAnimationByName Member Function

Syntax

template <class TObjectArray, class TResArray>
static nw::gfx::BaseAnimEvaluator * BindAnimationByName(
     os::IAllocator * allocator,
     TObjectArray & objects,
     TResArray & resources,
     const char * objectName,
     const char * animationName,
     AnimationType animationType,
     bool allocCache
);

Template Arguments

Name Description
TObjectArray Scene object collection type.
TResArray Resource object collection type.

Arguments

Name Description
in allocator Allocator to use for generation of animation objects.
in objects Collection of scene objects.
in resources Collection of resources.
in objectName Object name.
in animationName Name of animation data.
in animationType The animation type.
in allocCache Sets whether to allocate a cache buffer and enable the cache.

Return Values

Returns the animation object that was created.

Description

Binds the animation with the specified name.

Searches for objects and animation data of specified names and binds them. The function fails and returns NULLif objects and animation data of specified names cannot be found, or if the animation group of the specified type does not exist in the object, or if binding has failed.

If objects and animation data with the same name exist, the first found are used.

nw::gfx::TransformAnimEvaluator if the animation object that is to be created is a skeletal animation. Otherwise, nw::gfx::TransformAnimEvaluator.

See Also

BindAnimation
FindObjectByName
FindResAnimByName


CONFIDENTIAL