载入中...
搜索中...
未找到
eve::avatar::AvatarInstance类 参考

Unified avatar instance. Kind is a string: "image" | "live2d" | "vroid". Script-facing API avoids overloads; kind-specific methods no-op / return false when unsupported. 更多...

#include <AvatarInstance.h>

类 eve::avatar::AvatarInstance 继承关系图:
eve::IAttachmentPointSource eve::IAnimationEventSource

Public 类型

using DestroyHook = std::function< void(AvatarInstance *)>
 Callback fired exactly once, when the instance is destroyed.
 

Public 成员函数

 AvatarInstance (std::string kind)
 Avatar instance.
 
 ~AvatarInstance ()
 Avatar instance.
 
 AvatarInstance (const AvatarInstance &)=delete
 
AvatarInstance & operator= (const AvatarInstance &)=delete
 
std::string getKind () const
 Returns the kind.
 
void setPosition (float x, float y)
 Sets the position.
 
float getX () const
 Returns the x.
 
float getY () const
 Returns the y.
 
void setScale (float sx, float sy)
 Sets the scale.
 
float getScaleX () const
 Returns the scale x.
 
float getScaleY () const
 Returns the scale y.
 
void setVisible (bool visible)
 Sets the visible.
 
bool isVisible () const
 True when visible.
 
void setLayer (int layer)
 Sets the layer.
 
int getLayer () const
 Returns the layer.
 
void setExpression (const std::string &name)
 Sets the expression.
 
std::string getExpression () const
 Returns the expression.
 
void setMotion (const std::string &name)
 Sets the motion.
 
std::string getMotion () const
 Returns the motion.
 
void setParameter (const std::string &name, float value)
 Sets the parameter.
 
float getParameter (const std::string &name) const
 Returns the parameter.
 
bool hasParameter (const std::string &name) const
 True when parameter.
 
int getParameterCount () const
 Returns the parameter count.
 
std::string getParameterName (int index) const
 Returns the parameter name.
 
bool defineParameter (const std::string &name, float defaultValue, float minimum, float maximum)
 Define reflected Avatar parameter metadata for project-built inspectors.
 
float getParameterDefault (const std::string &name) const
 Return a reflected parameter default, or zero for an unknown parameter.
 
float getParameterMinimum (const std::string &name) const
 Return a reflected parameter minimum, or zero for an unknown parameter.
 
float getParameterMaximum (const std::string &name) const
 Return a reflected parameter maximum, or one for an unknown parameter.
 
void update (float dt)
 Updates .
 
void sync ()
 Push image / live2d layers into ECS or draw queues.
 
void release ()
 Release.
 
size_t addDestroyHook (DestroyHook hook)
 Register a destruction hook; returns an id usable with removeDestroyHook().
 
void removeDestroyHook (size_t id)
 Remove a previously registered destruction hook.
 
bool addLayer (const std::string &name, graphics::Texture *texture, int zIndex)
 Adds layer.
 
bool setLayerTexture (const std::string &name, graphics::Texture *texture)
 Sets the layer texture.
 
bool setLayerVisible (const std::string &name, bool visible)
 Sets the layer visible.
 
bool setLayerOffset (const std::string &name, float ox, float oy)
 Sets the layer offset.
 
bool setLayerColor (const std::string &name, float r, float g, float b, float a)
 Sets the layer color.
 
bool setLayerZ (const std::string &name, int zIndex)
 Sets the layer z.
 
bool setLayerSize (const std::string &name, float w, float h)
 Sets the layer size.
 
int getLayerCount () const
 Returns the layer count.
 
std::string getLayerName (int index) const
 Returns the layer name.
 
bool hasLayer (const std::string &name) const
 True when layer.
 
graphics::Renderable2D * getLayerRenderable (const std::string &name)
 Return the native Renderable2D owned by a named image layer.
 
bool defineExpression (const std::string &name, const std::string &spec)
 Spec: "eyes=1;mouth=smile;blush=0" (semicolon-separated name=value).
 
bool removeExpression (const std::string &name)
 Remove a project-defined expression.
 
int getExpressionCount () const
 Return the number of imported and project-defined expressions.
 
std::string getExpressionName (int index) const
 Return a stable sorted expression name, or empty text.
 
bool applyExpression (const std::string &name)
 Applies expression.
 
bool transitionExpression (const std::string &name, float duration)
 Blend numeric/bool expression channels over duration seconds.
 
bool loadLive2DModel (const std::string &path)
 Loads live 2 d model.
 
std::string getLive2DBackendName () const
 Returns the live 2 d backend name.
 
bool hasLive2DBackend () const
 True when live 2 d backend.
 
void collectLive2DDrawItems (std::vector< graphics::DrawItem2D > &out)
 Append this instance's Live2D drawables to a shared draw queue.
 
eve::Result< void > loadVroidModel (std::string_view path)
 Import and atomically replace a complete VRM avatar from a VFS path.
 
bool loadVroidModelPath (const std::string &path)
 Compatibility-only bool projection of loadVroidModel; performs the real import.
 
int getVroidMeshCount () const
 Number of imported mesh primitives; zero before successful import.
 
int getVroidSpringCount () const
 Number of imported VRM spring chains.
 
std::string getVroidVersion () const
 Imported VRM specification version, or empty before import.
 
eve::Result< void > setHumanoidBoneRotation (std::string_view semantic, float yaw, float pitch, float roll)
 Set an imported humanoid bone's local rotation offset in radians.
 
bool bindVroidModelData (model3d::ModelData *data)
 Binds vroid model data.
 
int loadMorphNamesFromModel (int meshIndex=0)
 Register morph target names from ModelData as parameters (weights default 0).
 
void setMesh (graphics::Mesh *mesh)
 Sets the mesh.
 
void setTexture (graphics::Texture *texture)
 Sets the texture.
 
void setPosition3D (float x, float y, float z)
 Sets the position 3 d.
 
void setRotation3D (float yaw, float pitch, float roll)
 Sets the rotation 3 d.
 
void setScale3D (float sx, float sy, float sz)
 Sets the scale 3 d.
 
graphics::Renderable3D * getRenderable3D () const
 Borrow the first imported render projection, or the manual projection.
 
graphics::Mesh * getBoundMesh () const
 Borrow the first imported mesh, or the manually bound mesh.
 
std::string getVroidModelPath () const
 Returns the vroid model path.
 
bool bakeMorphs ()
 Push parameter weights onto Mesh morphs and bake GPU verts when possible.
 
bool bindAnimPlayer (animation::AnimPlayer *player)
 Bind a clip player that the avatar advances and skins each update.
 
bool bindAnimStateMachine (animation::AnimStateMachine *machine)
 Bind an animation state machine that the avatar advances each update.
 
bool bindAnimLayerMixer (animation::AnimLayerMixer *mixer)
 Bind an override/additive layer mixer that the avatar advances each update.
 
void setAnimConstraintStack (animation::AnimConstraintStack *stack)
 Copy an IK/aim stack into Avatar-owned storage; null disables it.
 
animation::AnimConstraintStack * getAnimConstraintStack () const
 Return the Avatar-owned constraint stack, or null. @ownership Borrowed from this Avatar. @lifetime Valid until replacement, disable, or Avatar destruction.
 
void setFootIKSolver (animation::FootIKSolver *solver)
 Copy paired-foot IK configuration into Avatar-owned storage; null disables it.
 
animation::FootIKSolver * getFootIKSolver () const
 Return the Avatar-owned paired-foot IK solver, or null. @ownership Borrowed from this Avatar. @lifetime Valid until replacement, disable, or Avatar destruction.
 
void setDynamicBoneSolver (animation::DynamicBoneSolver *solver)
 Copy dynamic-bone configuration into Avatar-owned storage.
 
animation::DynamicBoneSolver * getDynamicBoneSolver () const
 Return the Avatar-owned solver, or null. @ownership Borrowed from this Avatar. @lifetime Valid until replacement, disable, or Avatar destruction.
 
bool bindAnimSkin (animation::AnimSkin *skin)
 Bind CPU skin data used to deform the avatar mesh from the active pose.
 
EquipmentVisualChange bindSkinnedPart (int partIndex, const std::string &partName, graphics::Mesh *mesh, graphics::Material *material, animation::AnimSkin *skin)
 Bind an always-visible skinned mesh/material part to the shared Avatar pose.
 
EquipmentVisualChange unbindSkinnedPart (int partIndex)
 Remove a shared-pose skinned part and clear its material slot.
 
SkinnedPartUpdateMode getSkinnedPartUpdateMode (int partIndex) const
 Return the latest GPU/CPU/unavailable update mode for a material slot.
 
bool registerMotion (const std::string &name, animation::AnimClip *clip)
 Register a motion name for setMotion(); the clip is not owned.
 
bool unregisterMotion (const std::string &name)
 Remove a registered motion without destroying its clip.
 
int getMotionCount () const
 Return the number of registered skeletal motions.
 
std::string getMotionName (int index) const
 Return a stable sorted motion name, or empty text.
 
animation::AnimClip * getMotionClip (const std::string &name) const
 Return a registered non-owned motion clip, or nullptr.
 
void setMotionBlendTime (float seconds)
 Set the cross-fade duration used when switching registered motions.
 
void setApplyRootMotion (bool enabled)
 Apply root-bone X/Z deltas to the Avatar transform while animating.
 
bool getApplyRootMotion () const
 Return whether root motion is applied to the Avatar transform.
 
float getRootMotionDeltaX () const
 Last evaluated root-motion X delta.
 
float getRootMotionDeltaZ () const
 Last evaluated root-motion Z delta.
 
int getAnimationEventCount () const
 Number of animation events emitted by the latest update.
 
std::string getAnimationEventLayer (int index) const
 Source layer for an animation event ("base" for the base player).
 
std::string getAnimationEventName (int index) const
 Animation event name, or empty for an invalid index.
 
std::string getAnimationEventPayload (int index) const
 Animation event payload, or empty for an invalid index.
 
std::size_t animationEventCount () const noexcept override
 Expose latest animation events through the backend-neutral consumer contract.
 
std::string animationEventName (std::size_t index) const override
 Return one latest animation event name through the consumer contract.
 
bool mapHumanoidBone (const std::string &semantic, const std::string &boneName)
 Map a VRM humanoid semantic (for example "head") to a skeleton bone.
 
int autoMapHumanoidBones ()
 Auto-map common VRM humanoid semantics from the currently bound skeleton.
 
std::string getHumanoidBoneName (const std::string &semantic) const
 Return the mapped skeleton bone name, or an empty string.
 
bool mapViseme (const std::string &viseme, const std::string &morphName)
 Map a VRM viseme/expression semantic to an existing mesh morph.
 
bool setViseme (const std::string &viseme, float weight)
 Set a mapped viseme weight and clear the previously active viseme.
 
bool setLookAtTarget (float x, float y, float z)
 Set a world-space target tracked by the mapped humanoid head bone.
 
void setLookAtWeight (float weight)
 Set VRM-style head look-at influence in the range 0..1.
 
void clearLookAtTarget ()
 Disable procedural head look-at.
 
bool attachToBone (const std::string &name, const std::string &boneSemanticOrName, graphics::Renderable3D *renderable, float ox=0.f, float oy=0.f, float oz=0.f)
 Attach a non-owned Renderable3D to a mapped humanoid semantic or bone name.
 
bool detachAttachment (const std::string &name)
 Remove an attachment without destroying its Renderable3D.
 
int getAttachmentCount () const
 Return the number of active bone attachments.
 
eve::Result< eve::AttachmentPoint > sampleAttachmentPoint (std::string_view name, eve::AttachmentPoint localOffset={}) const override
 Sample the latest evaluated semantic/bone point in Avatar world space.
 
bool linkSceneNode (scene::Scene *scene, const std::string &nodeId)
 Link this avatar to a node in Scene's current host.
 
bool isSceneLinked () const
 Return whether this avatar is currently scene-driven.
 
EquipmentVisualChange bindEquipment (inventory::EquipmentSet *equipment)
 Bind the authoritative equipment set whose visual projection this Avatar rebuilds.
 
EquipmentVisualChange unbindEquipment ()
 Remove the equipment binding and hide all registered equipment visuals.
 
EquipmentVisualChange defineEquipmentVisual2D (const std::string &itemId, const std::string &equipmentSlot, const std::string &layerName, graphics::Texture *texture, int zIndex)
 Map an item to a 2D Avatar layer. Texture is borrowed and must remain valid while registered.
 
EquipmentVisualChange defineEquipmentVisual3D (const std::string &itemId, const std::string &equipmentSlot, graphics::Renderable3D *renderable, const std::string &boneSemanticOrName, float ox=0.f, float oy=0.f, float oz=0.f)
 Map an item to a borrowed 3D renderable, optionally following a humanoid semantic/bone.
 
EquipmentVisualChange defineEquipmentSkinnedVisual3D (const std::string &itemId, const std::string &equipmentSlot, int partIndex, const std::string &partName, graphics::Mesh *mesh, graphics::Material *material, animation::AnimSkin *skin)
 Map wearable equipment to a skinned mesh/material part sharing the Avatar pose.
 
EquipmentVisualChange defineEquipmentLayer (const std::string &name, int order, const std::string &parent={})
 Define a named back-to-front wear layer and its optional semantic parent.
 
EquipmentVisualChange addEquipmentLayerOcclusion (const std::string &outerLayer, const std::string &innerLayer)
 Record that an equipped outer layer fully hides an inner layer.
 
EquipmentVisualChange setEquipmentVisualLayer (const std::string &itemId, const std::string &equipmentSlot, const std::string &wearLayer, int withinLayerOrder=0)
 Assign an item visual to a wear layer and a stable order inside that layer.
 
EquipmentVisualChange syncEquipmentAppearance ()
 Rebuild visuals from the current authoritative slots when their signature changed.
 
std::string getEquipmentVisualItem (const std::string &equipmentSlot) const
 Return the currently projected item for a slot, or empty text when none is shown.
 
int getEquipmentRenderStackCount () const
 Number of active visuals in canonical back-to-front render order.
 
std::string getEquipmentRenderStackItem (int index) const
 Active item id at a render-stack index, or empty text.
 
std::string getEquipmentRenderStackLayer (int index) const
 Wear-layer name at a render-stack index, or empty text.
 
void bindTween (animation::Tween *tween)
 Drive x/y/sx/sy and matching parameters from a Tween each update().
 
void unbindTween ()
 Unbinds tween.
 
animation::Tween * getBoundTween () const
 Returns the bound tween.
 
- Public 成员函数 继承自 eve::IAttachmentPointSource
virtual ~IAttachmentPointSource ()=default
 Releases IAttachmentPointSource resources.
 
- Public 成员函数 继承自 eve::IAnimationEventSource
virtual ~IAnimationEventSource ()=default
 Releases IAnimationEventSource resources.
 

详细描述

Unified avatar instance. Kind is a string: "image" | "live2d" | "vroid". Script-facing API avoids overloads; kind-specific methods no-op / return false when unsupported.

在文件 AvatarInstance.h 第 112 行定义.

成员类型定义说明

◆ DestroyHook

Callback fired exactly once, when the instance is destroyed.

在文件 AvatarInstance.h 第 115 行定义.

构造及析构函数说明

◆ AvatarInstance() [1/2]

eve::avatar::AvatarInstance::AvatarInstance ( std::string  kind)
explicit

Avatar instance.

在文件 AvatarInstance.cpp 第 62 行定义.

◆ ~AvatarInstance()

eve::avatar::AvatarInstance::~AvatarInstance ( )

Avatar instance.

在文件 AvatarInstance.cpp 第 73 行定义.

引用了 release().

◆ AvatarInstance() [2/2]

eve::avatar::AvatarInstance::AvatarInstance ( const AvatarInstance &  )
delete

成员函数说明

◆ addDestroyHook()

size_t eve::avatar::AvatarInstance::addDestroyHook ( DestroyHook  hook)

Register a destruction hook; returns an id usable with removeDestroyHook().

在文件 AvatarInstance.cpp 第 119 行定义.

引用了 id.

被这些函数引用 eve::dialogue::Dialogue::bindAvatar().

◆ addEquipmentLayerOcclusion()

EquipmentVisualChange eve::avatar::AvatarInstance::addEquipmentLayerOcclusion ( const std::string &  outerLayer,
const std::string &  innerLayer 
)

Record that an equipped outer layer fully hides an inner layer.

在文件 AvatarInstance.cpp 第 295 行定义.

引用了 eve::avatar::Applied, eve::avatar::Rejected, syncEquipmentAppearance() , 以及 eve::avatar::Unchanged.

◆ addLayer()

bool eve::avatar::AvatarInstance::addLayer ( const std::string &  name,
graphics::Texture *  texture,
int  zIndex 
)

◆ animationEventCount()

std::size_t eve::avatar::AvatarInstance::animationEventCount ( ) const
overridevirtualnoexcept

Expose latest animation events through the backend-neutral consumer contract.

实现了 eve::IAnimationEventSource.

在文件 AvatarSkeletal.cpp 第 229 行定义.

引用了 count, getAnimationEventCount() , 以及 u.

◆ animationEventName()

std::string eve::avatar::AvatarInstance::animationEventName ( std::size_t  index) const
overridevirtual

Return one latest animation event name through the consumer contract.

实现了 eve::IAnimationEventSource.

在文件 AvatarSkeletal.cpp 第 234 行定义.

引用了 getAnimationEventName() , 以及 index.

◆ applyExpression()

bool eve::avatar::AvatarInstance::applyExpression ( const std::string &  name)

Applies expression.

在文件 AvatarInstance.cpp 第 836 行定义.

引用了 name, ok , 以及 setExpression().

被这些函数引用 setExpression() , 以及 transitionExpression().

◆ attachToBone()

bool eve::avatar::AvatarInstance::attachToBone ( const std::string &  name,
const std::string &  boneSemanticOrName,
graphics::Renderable3D *  renderable,
float  ox = 0.f,
float  oy = 0.f,
float  oz = 0.f 
)

Attach a non-owned Renderable3D to a mapped humanoid semantic or bone name.

参数
nameStable attachment name used by detachAttachment().
boneSemanticOrNameHumanoid semantic (for example "rightHand") or bone name.
renderableExisting renderable; Avatar does not own or destroy it.
oxLocal bone-space X offset.
oyLocal bone-space Y offset.
ozLocal bone-space Z offset.

在文件 AvatarSkeletal.cpp 第 121 行定义.

引用了 eve::animation::AnimSkeleton::findBone(), name, ox , 以及 oy.

被这些函数引用 syncEquipmentAppearance().

◆ autoMapHumanoidBones()

int eve::avatar::AvatarInstance::autoMapHumanoidBones ( )

Auto-map common VRM humanoid semantics from the currently bound skeleton.

在文件 AvatarSkeletal.cpp 第 43 行定义.

引用了 eve::animation::AnimSkeleton::findBone(), name , 以及 semantic.

◆ bakeMorphs()

bool eve::avatar::AvatarInstance::bakeMorphs ( )

Push parameter weights onto Mesh morphs and bake GPU verts when possible.

在文件 AvatarVroid.cpp 第 186 行定义.

引用了 eve::graphics::Mesh::isMorphDirty().

◆ bindAnimLayerMixer()

bool eve::avatar::AvatarInstance::bindAnimLayerMixer ( animation::AnimLayerMixer *  mixer)

Bind an override/additive layer mixer that the avatar advances each update.

在文件 AvatarInstance.cpp 第 562 行定义.

引用了 eve::animation::AnimLayerMixer::getBasePlayer() , 以及 eve::animation::AnimLayerMixer::getSkeleton().

◆ bindAnimPlayer()

bool eve::avatar::AvatarInstance::bindAnimPlayer ( animation::AnimPlayer *  player)

Bind a clip player that the avatar advances and skins each update.

在文件 AvatarInstance.cpp 第 534 行定义.

引用了 eve::animation::AnimPlayer::getSkeleton().

◆ bindAnimSkin()

bool eve::avatar::AvatarInstance::bindAnimSkin ( animation::AnimSkin *  skin)

Bind CPU skin data used to deform the avatar mesh from the active pose.

在文件 AvatarInstance.cpp 第 607 行定义.

◆ bindAnimStateMachine()

bool eve::avatar::AvatarInstance::bindAnimStateMachine ( animation::AnimStateMachine *  machine)

Bind an animation state machine that the avatar advances each update.

在文件 AvatarInstance.cpp 第 548 行定义.

引用了 eve::animation::AnimStateMachine::getSkeleton().

◆ bindEquipment()

EquipmentVisualChange eve::avatar::AvatarInstance::bindEquipment ( inventory::EquipmentSet *  equipment)

Bind the authoritative equipment set whose visual projection this Avatar rebuilds.

参数
equipmentNon-owned equipment state; it must outlive this binding and stay on the main thread.
返回
Applied after an immediate projection rebuild, or Removed when unbinding with nullptr.
注解
Avatar never mutates equipment. update()/sync() detects slot changes, including direct stack edits.

在文件 AvatarInstance.cpp 第 150 行定义.

引用了 syncEquipmentAppearance() , 以及 unbindEquipment().

◆ bindSkinnedPart()

EquipmentVisualChange eve::avatar::AvatarInstance::bindSkinnedPart ( int  partIndex,
const std::string &  partName,
graphics::Mesh *  mesh,
graphics::Material *  material,
animation::AnimSkin *  skin 
)

Bind an always-visible skinned mesh/material part to the shared Avatar pose.

返回
Applied, Unchanged, or Rejected when the slot/resources are invalid.
注解
Mesh, material, and skin are borrowed. Each mesh receives its own GPU skin palette.

在文件 AvatarInstance.cpp 第 614 行定义.

引用了 eve::avatar::Applied, eve::graphics::Renderable3D::MeshRenderer::kMaxParts, material, mesh, eve::avatar::Rejected, eve::graphics::Renderable3D::setPart() , 以及 eve::avatar::Unchanged.

◆ bindTween()

void eve::avatar::AvatarInstance::bindTween ( animation::Tween *  tween)

Drive x/y/sx/sy and matching parameters from a Tween each update().

在文件 AvatarSkeletal.cpp 第 446 行定义.

◆ bindVroidModelData()

bool eve::avatar::AvatarInstance::bindVroidModelData ( model3d::ModelData *  data)

Binds vroid model data.

在文件 AvatarVroid.cpp 第 114 行定义.

引用了 loadMorphNamesFromModel().

◆ clearLookAtTarget()

void eve::avatar::AvatarInstance::clearLookAtTarget ( )

Disable procedural head look-at.

在文件 AvatarSkeletal.cpp 第 119 行定义.

◆ collectLive2DDrawItems()

void eve::avatar::AvatarInstance::collectLive2DDrawItems ( std::vector< graphics::DrawItem2D > &  out)

Append this instance's Live2D drawables to a shared draw queue.

在文件 AvatarInstance.cpp 第 979 行定义.

引用了 eve::avatar::ILive2DBackend::collectDrawItems() , 以及 eve::avatar::Avatar::createLive2DBackend().

◆ defineEquipmentLayer()

EquipmentVisualChange eve::avatar::AvatarInstance::defineEquipmentLayer ( const std::string &  name,
int  order,
const std::string &  parent = {} 
)

Define a named back-to-front wear layer and its optional semantic parent.

在文件 AvatarInstance.cpp 第 280 行定义.

引用了 eve::avatar::Applied, found, layer, name, order, parent, eve::avatar::Rejected, syncEquipmentAppearance() , 以及 eve::avatar::Unchanged.

◆ defineEquipmentSkinnedVisual3D()

EquipmentVisualChange eve::avatar::AvatarInstance::defineEquipmentSkinnedVisual3D ( const std::string &  itemId,
const std::string &  equipmentSlot,
int  partIndex,
const std::string &  partName,
graphics::Mesh *  mesh,
graphics::Material *  material,
animation::AnimSkin *  skin 
)

Map wearable equipment to a skinned mesh/material part sharing the Avatar pose.

参数
partIndexStable Renderable3D material slot; different active wearables must use different slots.
skinSkin binding built for mesh against the same skeleton used by the Avatar animation source.
注解
The part is activated/deactivated by authoritative equipment state and wear-layer occlusion.

在文件 AvatarInstance.cpp 第 227 行定义.

引用了 eve::avatar::Applied, eve::graphics::Renderable3D::clearPartSortPriority(), detachAttachment(), itemId, eve::graphics::Renderable3D::MeshRenderer::kMaxParts, material, mesh, eve::avatar::Rejected, eve::graphics::Renderable3D::setPart(), syncEquipmentAppearance() , 以及 eve::avatar::Unchanged.

◆ defineEquipmentVisual2D()

EquipmentVisualChange eve::avatar::AvatarInstance::defineEquipmentVisual2D ( const std::string &  itemId,
const std::string &  equipmentSlot,
const std::string &  layerName,
graphics::Texture *  texture,
int  zIndex 
)

Map an item to a 2D Avatar layer. Texture is borrowed and must remain valid while registered.

返回
Applied, Unchanged, or Rejected for invalid identifiers/non-image Avatars.

在文件 AvatarInstance.cpp 第 166 行定义.

引用了 eve::avatar::Applied, itemId, eve::avatar::Rejected, syncEquipmentAppearance() , 以及 eve::avatar::Unchanged.

◆ defineEquipmentVisual3D()

EquipmentVisualChange eve::avatar::AvatarInstance::defineEquipmentVisual3D ( const std::string &  itemId,
const std::string &  equipmentSlot,
graphics::Renderable3D *  renderable,
const std::string &  boneSemanticOrName,
float  ox = 0.f,
float  oy = 0.f,
float  oz = 0.f 
)

Map an item to a borrowed 3D renderable, optionally following a humanoid semantic/bone.

返回
Applied, Unchanged, or Rejected for invalid identifiers/non-3D Avatars.
注解
An empty bone name makes a modular root part follow the Avatar transform; a non-empty name follows the evaluated skeleton pose. Avatar controls visibility/transform but never destroys the part.

在文件 AvatarInstance.cpp 第 193 行定义.

引用了 eve::avatar::Applied, itemId, ox, oy, eve::avatar::Rejected, eve::graphics::Renderable3D::setVisible(), syncEquipmentAppearance() , 以及 eve::avatar::Unchanged.

◆ defineExpression()

bool eve::avatar::AvatarInstance::defineExpression ( const std::string &  name,
const std::string &  spec 
)

Spec: "eyes=1;mouth=smile;blush=0" (semicolon-separated name=value).

在文件 AvatarInstance.cpp 第 781 行定义.

引用了 name.

◆ defineParameter()

bool eve::avatar::AvatarInstance::defineParameter ( const std::string &  name,
float  defaultValue,
float  minimum,
float  maximum 
)

Define reflected Avatar parameter metadata for project-built inspectors.

返回
False for an empty name or invalid range.

在文件 Avatar.cpp 第 38 行定义.

引用了 defaultValue, maximum, minimum , 以及 name.

◆ detachAttachment()

bool eve::avatar::AvatarInstance::detachAttachment ( const std::string &  name)

Remove an attachment without destroying its Renderable3D.

在文件 AvatarSkeletal.cpp 第 137 行定义.

被这些函数引用 defineEquipmentSkinnedVisual3D().

◆ getAnimationEventCount()

int eve::avatar::AvatarInstance::getAnimationEventCount ( ) const

Number of animation events emitted by the latest update.

在文件 AvatarSkeletal.cpp 第 223 行定义.

引用了 eve::animation::AnimLayerMixer::getEventCount() , 以及 eve::animation::AnimPlayer::getEventCount().

被这些函数引用 animationEventCount().

◆ getAnimationEventLayer()

std::string eve::avatar::AvatarInstance::getAnimationEventLayer ( int  index) const

Source layer for an animation event ("base" for the base player).

在文件 AvatarSkeletal.cpp 第 239 行定义.

引用了 eve::animation::AnimPlayer::getEventCount(), eve::animation::AnimLayerMixer::getEventLayer() , 以及 index.

◆ getAnimationEventName()

std::string eve::avatar::AvatarInstance::getAnimationEventName ( int  index) const

Animation event name, or empty for an invalid index.

在文件 AvatarSkeletal.cpp 第 244 行定义.

引用了 eve::animation::AnimLayerMixer::getEventName(), eve::animation::AnimPlayer::getEventName() , 以及 index.

被这些函数引用 animationEventName().

◆ getAnimationEventPayload()

std::string eve::avatar::AvatarInstance::getAnimationEventPayload ( int  index) const

Animation event payload, or empty for an invalid index.

在文件 AvatarSkeletal.cpp 第 249 行定义.

引用了 eve::animation::AnimLayerMixer::getEventPayload(), eve::animation::AnimPlayer::getEventPayload() , 以及 index.

◆ getAnimConstraintStack()

animation::AnimConstraintStack * eve::avatar::AvatarInstance::getAnimConstraintStack ( ) const
inline

Return the Avatar-owned constraint stack, or null. @ownership Borrowed from this Avatar. @lifetime Valid until replacement, disable, or Avatar destruction.

在文件 AvatarInstance.h 第 316 行定义.

◆ getApplyRootMotion()

bool eve::avatar::AvatarInstance::getApplyRootMotion ( ) const
inline

Return whether root motion is applied to the Avatar transform.

在文件 AvatarInstance.h 第 366 行定义.

◆ getAttachmentCount()

int eve::avatar::AvatarInstance::getAttachmentCount ( ) const
inline

Return the number of active bone attachments.

在文件 AvatarInstance.h 第 417 行定义.

◆ getBoundMesh()

graphics::Mesh * eve::avatar::AvatarInstance::getBoundMesh ( ) const

Borrow the first imported mesh, or the manually bound mesh.

返回
Non-owning pointer; nullptr when the imported graphics provider expired. @ownership Borrowed on the render thread. Import ownership stays with Avatar; lifetime ends on replacement, release or provider destruction. Manual mesh lifetime is caller-owned.

在文件 AvatarVroid.cpp 第 173 行定义.

◆ getBoundTween()

animation::Tween * eve::avatar::AvatarInstance::getBoundTween ( ) const
inline

Returns the bound tween.

在文件 AvatarInstance.h 第 493 行定义.

◆ getDynamicBoneSolver()

animation::DynamicBoneSolver * eve::avatar::AvatarInstance::getDynamicBoneSolver ( ) const
inline

Return the Avatar-owned solver, or null. @ownership Borrowed from this Avatar. @lifetime Valid until replacement, disable, or Avatar destruction.

在文件 AvatarInstance.h 第 336 行定义.

◆ getEquipmentRenderStackCount()

int eve::avatar::AvatarInstance::getEquipmentRenderStackCount ( ) const

Number of active visuals in canonical back-to-front render order.

在文件 AvatarInstance.cpp 第 417 行定义.

◆ getEquipmentRenderStackItem()

std::string eve::avatar::AvatarInstance::getEquipmentRenderStackItem ( int  index) const

Active item id at a render-stack index, or empty text.

在文件 AvatarInstance.cpp 第 421 行定义.

引用了 index , 以及 itemId.

◆ getEquipmentRenderStackLayer()

std::string eve::avatar::AvatarInstance::getEquipmentRenderStackLayer ( int  index) const

Wear-layer name at a render-stack index, or empty text.

在文件 AvatarInstance.cpp 第 427 行定义.

引用了 index.

◆ getEquipmentVisualItem()

std::string eve::avatar::AvatarInstance::getEquipmentVisualItem ( const std::string &  equipmentSlot) const

Return the currently projected item for a slot, or empty text when none is shown.

在文件 AvatarInstance.cpp 第 412 行定义.

引用了 found.

◆ getExpression()

std::string eve::avatar::AvatarInstance::getExpression ( ) const
inline

Returns the expression.

在文件 AvatarInstance.h 第 155 行定义.

◆ getExpressionCount()

int eve::avatar::AvatarInstance::getExpressionCount ( ) const

Return the number of imported and project-defined expressions.

在文件 Avatar.cpp 第 65 行定义.

引用了 count.

◆ getExpressionName()

std::string eve::avatar::AvatarInstance::getExpressionName ( int  index) const

Return a stable sorted expression name, or empty text.

在文件 Avatar.cpp 第 73 行定义.

引用了 index.

◆ getFootIKSolver()

animation::FootIKSolver * eve::avatar::AvatarInstance::getFootIKSolver ( ) const
inline

Return the Avatar-owned paired-foot IK solver, or null. @ownership Borrowed from this Avatar. @lifetime Valid until replacement, disable, or Avatar destruction.

在文件 AvatarInstance.h 第 324 行定义.

◆ getHumanoidBoneName()

std::string eve::avatar::AvatarInstance::getHumanoidBoneName ( const std::string &  semantic) const

Return the mapped skeleton bone name, or an empty string.

在文件 AvatarSkeletal.cpp 第 78 行定义.

引用了 semantic.

◆ getKind()

std::string eve::avatar::AvatarInstance::getKind ( ) const
inline

Returns the kind.

在文件 AvatarInstance.h 第 126 行定义.

◆ getLayer()

int eve::avatar::AvatarInstance::getLayer ( ) const
inline

Returns the layer.

在文件 AvatarInstance.h 第 150 行定义.

◆ getLayerCount()

int eve::avatar::AvatarInstance::getLayerCount ( ) const

Returns the layer count.

在文件 AvatarInstance.cpp 第 767 行定义.

◆ getLayerName()

std::string eve::avatar::AvatarInstance::getLayerName ( int  index) const

Returns the layer name.

在文件 AvatarInstance.cpp 第 769 行定义.

引用了 index.

◆ getLayerRenderable()

graphics::Renderable2D * eve::avatar::AvatarInstance::getLayerRenderable ( const std::string &  name)

Return the native Renderable2D owned by a named image layer.

在文件 AvatarInstance.cpp 第 776 行定义.

引用了 name.

◆ getLive2DBackendName()

std::string eve::avatar::AvatarInstance::getLive2DBackendName ( ) const

Returns the live 2 d backend name.

在文件 AvatarInstance.cpp 第 969 行定义.

引用了 eve::avatar::Avatar::getLive2DBackendName() , 以及 eve::avatar::ILive2DBackend::getName().

◆ getMotion()

std::string eve::avatar::AvatarInstance::getMotion ( ) const
inline

Returns the motion.

在文件 AvatarInstance.h 第 160 行定义.

◆ getMotionClip()

animation::AnimClip * eve::avatar::AvatarInstance::getMotionClip ( const std::string &  name) const

Return a registered non-owned motion clip, or nullptr.

在文件 Avatar.cpp 第 97 行定义.

引用了 found , 以及 name.

◆ getMotionCount()

int eve::avatar::AvatarInstance::getMotionCount ( ) const

Return the number of registered skeletal motions.

在文件 Avatar.cpp 第 87 行定义.

◆ getMotionName()

std::string eve::avatar::AvatarInstance::getMotionName ( int  index) const

Return a stable sorted motion name, or empty text.

在文件 Avatar.cpp 第 91 行定义.

引用了 index.

◆ getParameter()

float eve::avatar::AvatarInstance::getParameter ( const std::string &  name) const

Returns the parameter.

在文件 AvatarInstance.cpp 第 503 行定义.

引用了 eve::avatar::ILive2DBackend::getParameter() , 以及 name.

被这些函数引用 eve::avatar::VrmRuntime::gaze(), eve::avatar::VrmRuntime::morphs() , 以及 transitionExpression().

◆ getParameterCount()

int eve::avatar::AvatarInstance::getParameterCount ( ) const

Returns the parameter count.

在文件 AvatarInstance.cpp 第 516 行定义.

◆ getParameterDefault()

float eve::avatar::AvatarInstance::getParameterDefault ( const std::string &  name) const

Return a reflected parameter default, or zero for an unknown parameter.

在文件 Avatar.cpp 第 46 行定义.

引用了 found , 以及 name.

◆ getParameterMaximum()

float eve::avatar::AvatarInstance::getParameterMaximum ( const std::string &  name) const

Return a reflected parameter maximum, or one for an unknown parameter.

在文件 Avatar.cpp 第 56 行定义.

引用了 found , 以及 name.

◆ getParameterMinimum()

float eve::avatar::AvatarInstance::getParameterMinimum ( const std::string &  name) const

Return a reflected parameter minimum, or zero for an unknown parameter.

在文件 Avatar.cpp 第 51 行定义.

引用了 found , 以及 name.

◆ getParameterName()

std::string eve::avatar::AvatarInstance::getParameterName ( int  index) const

Returns the parameter name.

在文件 AvatarInstance.cpp 第 518 行定义.

引用了 index.

◆ getRenderable3D()

graphics::Renderable3D * eve::avatar::AvatarInstance::getRenderable3D ( ) const

Borrow the first imported render projection, or the manual projection.

返回
Non-owning pointer, or nullptr when no live projection exists. @lifetime Borrowed until replacement, release or ECS destruction; render thread only.

在文件 AvatarVroid.cpp 第 108 行定义.

◆ getRootMotionDeltaX()

float eve::avatar::AvatarInstance::getRootMotionDeltaX ( ) const
inline

Last evaluated root-motion X delta.

在文件 AvatarInstance.h 第 368 行定义.

◆ getRootMotionDeltaZ()

float eve::avatar::AvatarInstance::getRootMotionDeltaZ ( ) const
inline

Last evaluated root-motion Z delta.

在文件 AvatarInstance.h 第 370 行定义.

◆ getScaleX()

float eve::avatar::AvatarInstance::getScaleX ( ) const
inline

Returns the scale x.

在文件 AvatarInstance.h 第 138 行定义.

◆ getScaleY()

float eve::avatar::AvatarInstance::getScaleY ( ) const
inline

Returns the scale y.

在文件 AvatarInstance.h 第 140 行定义.

◆ getSkinnedPartUpdateMode()

SkinnedPartUpdateMode eve::avatar::AvatarInstance::getSkinnedPartUpdateMode ( int  partIndex) const

Return the latest GPU/CPU/unavailable update mode for a material slot.

在文件 AvatarInstance.cpp 第 661 行定义.

引用了 eve::avatar::Unavailable.

◆ getVroidMeshCount()

int eve::avatar::AvatarInstance::getVroidMeshCount ( ) const

Number of imported mesh primitives; zero before successful import.

在文件 AvatarVroid.cpp 第 105 行定义.

◆ getVroidModelPath()

std::string eve::avatar::AvatarInstance::getVroidModelPath ( ) const
inline

Returns the vroid model path.

在文件 AvatarInstance.h 第 298 行定义.

◆ getVroidSpringCount()

int eve::avatar::AvatarInstance::getVroidSpringCount ( ) const

Number of imported VRM spring chains.

在文件 AvatarVroid.cpp 第 106 行定义.

◆ getVroidVersion()

std::string eve::avatar::AvatarInstance::getVroidVersion ( ) const

Imported VRM specification version, or empty before import.

在文件 AvatarVroid.cpp 第 107 行定义.

◆ getX()

float eve::avatar::AvatarInstance::getX ( ) const
inline

Returns the x.

在文件 AvatarInstance.h 第 131 行定义.

◆ getY()

float eve::avatar::AvatarInstance::getY ( ) const
inline

Returns the y.

在文件 AvatarInstance.h 第 133 行定义.

◆ hasLayer()

bool eve::avatar::AvatarInstance::hasLayer ( const std::string &  name) const

True when layer.

在文件 AvatarInstance.cpp 第 774 行定义.

引用了 name.

被这些函数引用 syncEquipmentAppearance().

◆ hasLive2DBackend()

bool eve::avatar::AvatarInstance::hasLive2DBackend ( ) const

True when live 2 d backend.

在文件 AvatarInstance.cpp 第 974 行定义.

引用了 eve::avatar::Avatar::hasLive2DBackend() , 以及 eve::avatar::ILive2DBackend::isRuntimeAvailable().

◆ hasParameter()

bool eve::avatar::AvatarInstance::hasParameter ( const std::string &  name) const

True when parameter.

在文件 AvatarInstance.cpp 第 509 行定义.

引用了 name.

被这些函数引用 loadMorphNamesFromModel(), eve::avatar::VrmRuntime::morphs() , 以及 setViseme().

◆ isSceneLinked()

bool eve::avatar::AvatarInstance::isSceneLinked ( ) const
inline

Return whether this avatar is currently scene-driven.

在文件 AvatarInstance.h 第 424 行定义.

◆ isVisible()

bool eve::avatar::AvatarInstance::isVisible ( ) const
inline

True when visible.

在文件 AvatarInstance.h 第 145 行定义.

◆ linkSceneNode()

bool eve::avatar::AvatarInstance::linkSceneNode ( scene::Scene *  scene,
const std::string &  nodeId 
)

◆ loadLive2DModel()

bool eve::avatar::AvatarInstance::loadLive2DModel ( const std::string &  path)

Loads live 2 d model.

在文件 AvatarInstance.cpp 第 962 行定义.

引用了 eve::avatar::Avatar::createLive2DBackend(), eve::avatar::ILive2DBackend::loadModel() , 以及 path.

◆ loadMorphNamesFromModel()

int eve::avatar::AvatarInstance::loadMorphNamesFromModel ( int  meshIndex = 0)

Register morph target names from ModelData as parameters (weights default 0).

在文件 AvatarVroid.cpp 第 121 行定义.

引用了 eve::model3d::ModelData::getMorphTargetCount(), eve::model3d::ModelData::getMorphTargetName(), hasParameter(), n , 以及 name.

被这些函数引用 bindVroidModelData().

◆ loadVroidModel()

eve::Result< void > eve::avatar::AvatarInstance::loadVroidModel ( std::string_view  path)

Import and atomically replace a complete VRM avatar from a VFS path.

参数
pathBorrowed for the call; copied on success.
返回
Structured import/provider error; failure preserves the previous avatar. @ownership Avatar owns imported CPU state and releases its GPU resources on replacement/destruction. @thread Main/render thread before frame submission. Does not invoke callbacks or scripts.
注解
Explicit reload rebuilds the entire projection. Unknown VRM versions are rejected.

在文件 AvatarVroid.cpp 第 38 行定义.

引用了 eve::Diagnostic::error(), eve::Result< T >::failure(), eve::InvalidArgument, mesh, name, node, order, path, eve::avatar::VrmRuntime::prepare() , 以及 eve::Result< T >::success().

被这些函数引用 loadVroidModelPath().

◆ loadVroidModelPath()

bool eve::avatar::AvatarInstance::loadVroidModelPath ( const std::string &  path)

Compatibility-only bool projection of loadVroidModel; performs the real import.

在文件 AvatarVroid.cpp 第 104 行定义.

引用了 loadVroidModel(), eve::Result< void >::ok() , 以及 path.

◆ mapHumanoidBone()

bool eve::avatar::AvatarInstance::mapHumanoidBone ( const std::string &  semantic,
const std::string &  boneName 
)

Map a VRM humanoid semantic (for example "head") to a skeleton bone.

在文件 AvatarSkeletal.cpp 第 36 行定义.

引用了 eve::animation::AnimSkeleton::findBone() , 以及 semantic.

◆ mapViseme()

bool eve::avatar::AvatarInstance::mapViseme ( const std::string &  viseme,
const std::string &  morphName 
)

Map a VRM viseme/expression semantic to an existing mesh morph.

在文件 AvatarSkeletal.cpp 第 83 行定义.

引用了 eve::graphics::Mesh::hasMorph().

◆ operator=()

AvatarInstance & eve::avatar::AvatarInstance::operator= ( const AvatarInstance &  )
delete

◆ registerMotion()

bool eve::avatar::AvatarInstance::registerMotion ( const std::string &  name,
animation::AnimClip *  clip 
)

Register a motion name for setMotion(); the clip is not owned.

在文件 AvatarInstance.cpp 第 671 行定义.

引用了 clip , 以及 name.

◆ release()

void eve::avatar::AvatarInstance::release ( )

Release.

在文件 AvatarInstance.cpp 第 75 行定义.

被这些函数引用 ~AvatarInstance().

◆ removeDestroyHook()

void eve::avatar::AvatarInstance::removeDestroyHook ( size_t  id)

Remove a previously registered destruction hook.

在文件 AvatarInstance.cpp 第 127 行定义.

◆ removeExpression()

bool eve::avatar::AvatarInstance::removeExpression ( const std::string &  name)

Remove a project-defined expression.

在文件 Avatar.cpp 第 61 行定义.

引用了 name.

◆ sampleAttachmentPoint()

eve::Result< eve::AttachmentPoint > eve::avatar::AvatarInstance::sampleAttachmentPoint ( std::string_view  name,
eve::AttachmentPoint  localOffset = {} 
) const
overridevirtual

◆ setAnimConstraintStack()

void eve::avatar::AvatarInstance::setAnimConstraintStack ( animation::AnimConstraintStack *  stack)

Copy an IK/aim stack into Avatar-owned storage; null disables it.

在文件 AvatarInstance.cpp 第 576 行定义.

◆ setApplyRootMotion()

void eve::avatar::AvatarInstance::setApplyRootMotion ( bool  enabled)

Apply root-bone X/Z deltas to the Avatar transform while animating.

在文件 AvatarInstance.cpp 第 679 行定义.

引用了 enabled.

◆ setDynamicBoneSolver()

void eve::avatar::AvatarInstance::setDynamicBoneSolver ( animation::DynamicBoneSolver *  solver)

Copy dynamic-bone configuration into Avatar-owned storage.

参数
solverBorrowed only during this call; null disables the effect.
注解
Main-thread only. The getter is valid until replacement or Avatar destruction.

在文件 AvatarInstance.cpp 第 594 行定义.

◆ setEquipmentVisualLayer()

EquipmentVisualChange eve::avatar::AvatarInstance::setEquipmentVisualLayer ( const std::string &  itemId,
const std::string &  equipmentSlot,
const std::string &  wearLayer,
int  withinLayerOrder = 0 
)

Assign an item visual to a wear layer and a stable order inside that layer.

在文件 AvatarInstance.cpp 第 310 行定义.

引用了 eve::avatar::Applied, itemId, eve::avatar::Rejected, syncEquipmentAppearance() , 以及 eve::avatar::Unchanged.

◆ setExpression()

void eve::avatar::AvatarInstance::setExpression ( const std::string &  name)

◆ setFootIKSolver()

void eve::avatar::AvatarInstance::setFootIKSolver ( animation::FootIKSolver *  solver)

Copy paired-foot IK configuration into Avatar-owned storage; null disables it.

在文件 AvatarInstance.cpp 第 585 行定义.

◆ setHumanoidBoneRotation()

eve::Result< void > eve::avatar::AvatarInstance::setHumanoidBoneRotation ( std::string_view  semantic,
float  yaw,
float  pitch,
float  roll 
)

Set an imported humanoid bone's local rotation offset in radians.

参数
semanticVRM bone semantic, borrowed for the call.
yawLocal yaw offset in radians.
pitchLocal pitch offset in radians.
rollLocal roll offset in radians.
返回
Success or InvalidArgument/NotFound, preserving offsets on failure.
注解
Render thread only; applied before gaze and springs, without callbacks. Offsets are owned by this Avatar and cleared by model replacement.

在文件 AvatarVroid.cpp 第 92 行定义.

引用了 eve::Diagnostic::error(), eve::Result< T >::failure(), found, eve::InvalidArgument, eve::NotFound, pitch, roll, semantic, eve::Result< T >::success() , 以及 yaw.

◆ setLayer()

void eve::avatar::AvatarInstance::setLayer ( int  layer)

Sets the layer.

在文件 AvatarInstance.cpp 第 148 行定义.

引用了 layer.

◆ setLayerColor()

bool eve::avatar::AvatarInstance::setLayerColor ( const std::string &  name,
float  r,
float  g,
float  b,
float  a 
)

Sets the layer color.

在文件 AvatarInstance.cpp 第 745 行定义.

引用了 a, b, g, name , 以及 r.

◆ setLayerOffset()

bool eve::avatar::AvatarInstance::setLayerOffset ( const std::string &  name,
float  ox,
float  oy 
)

Sets the layer offset.

在文件 AvatarInstance.cpp 第 737 行定义.

引用了 name, ox , 以及 oy.

◆ setLayerSize()

bool eve::avatar::AvatarInstance::setLayerSize ( const std::string &  name,
float  w,
float  h 
)

Sets the layer size.

在文件 AvatarInstance.cpp 第 759 行定义.

引用了 h, name , 以及 w.

◆ setLayerTexture()

bool eve::avatar::AvatarInstance::setLayerTexture ( const std::string &  name,
graphics::Texture *  texture 
)

◆ setLayerVisible()

bool eve::avatar::AvatarInstance::setLayerVisible ( const std::string &  name,
bool  visible 
)

Sets the layer visible.

在文件 AvatarInstance.cpp 第 729 行定义.

引用了 name , 以及 visible.

被这些函数引用 syncEquipmentAppearance().

◆ setLayerZ()

bool eve::avatar::AvatarInstance::setLayerZ ( const std::string &  name,
int  zIndex 
)

Sets the layer z.

在文件 AvatarInstance.cpp 第 752 行定义.

引用了 name.

被这些函数引用 syncEquipmentAppearance().

◆ setLookAtTarget()

bool eve::avatar::AvatarInstance::setLookAtTarget ( float  x,
float  y,
float  z 
)

Set a world-space target tracked by the mapped humanoid head bone.

在文件 AvatarSkeletal.cpp 第 108 行定义.

引用了 x, y , 以及 z.

◆ setLookAtWeight()

void eve::avatar::AvatarInstance::setLookAtWeight ( float  weight)

Set VRM-style head look-at influence in the range 0..1.

在文件 AvatarSkeletal.cpp 第 117 行定义.

引用了 weight.

◆ setMesh()

void eve::avatar::AvatarInstance::setMesh ( graphics::Mesh *  mesh)

Sets the mesh.

在文件 AvatarVroid.cpp 第 136 行定义.

引用了 mesh, name , 以及 eve::graphics::Renderable3D::setMesh().

◆ setMotion()

◆ setMotionBlendTime()

void eve::avatar::AvatarInstance::setMotionBlendTime ( float  seconds)

Set the cross-fade duration used when switching registered motions.

在文件 AvatarInstance.cpp 第 677 行定义.

◆ setParameter()

void eve::avatar::AvatarInstance::setParameter ( const std::string &  name,
float  value 
)

◆ setPosition()

void eve::avatar::AvatarInstance::setPosition ( float  x,
float  y 
)

Sets the position.

在文件 AvatarInstance.cpp 第 136 行定义.

引用了 x , 以及 y.

◆ setPosition3D()

void eve::avatar::AvatarInstance::setPosition3D ( float  x,
float  y,
float  z 
)

Sets the position 3 d.

在文件 AvatarVroid.cpp 第 155 行定义.

引用了 x, y , 以及 z.

◆ setRotation3D()

void eve::avatar::AvatarInstance::setRotation3D ( float  yaw,
float  pitch,
float  roll 
)

Sets the rotation 3 d.

在文件 AvatarVroid.cpp 第 161 行定义.

引用了 pitch, roll , 以及 yaw.

◆ setScale()

void eve::avatar::AvatarInstance::setScale ( float  sx,
float  sy 
)

Sets the scale.

在文件 AvatarInstance.cpp 第 141 行定义.

引用了 sx , 以及 sy.

◆ setScale3D()

void eve::avatar::AvatarInstance::setScale3D ( float  sx,
float  sy,
float  sz 
)

Sets the scale 3 d.

在文件 AvatarVroid.cpp 第 167 行定义.

引用了 sx, sy , 以及 sz.

◆ setTexture()

void eve::avatar::AvatarInstance::setTexture ( graphics::Texture *  texture)

Sets the texture.

在文件 AvatarVroid.cpp 第 149 行定义.

引用了 eve::graphics::Renderable3D::setTexture().

◆ setViseme()

bool eve::avatar::AvatarInstance::setViseme ( const std::string &  viseme,
float  weight 
)

Set a mapped viseme weight and clear the previously active viseme.

在文件 AvatarSkeletal.cpp 第 90 行定义.

引用了 hasParameter(), previous, setParameter() , 以及 weight.

◆ setVisible()

void eve::avatar::AvatarInstance::setVisible ( bool  visible)

Sets the visible.

在文件 AvatarInstance.cpp 第 146 行定义.

引用了 visible.

◆ sync()

void eve::avatar::AvatarInstance::sync ( )

◆ syncEquipmentAppearance()

◆ transitionExpression()

bool eve::avatar::AvatarInstance::transitionExpression ( const std::string &  name,
float  duration 
)

Blend numeric/bool expression channels over duration seconds.

在文件 AvatarInstance.cpp 第 855 行定义.

引用了 applyExpression(), duration, end, eve::graphics::Mesh::getMorphCount(), eve::graphics::Mesh::getMorphName(), getParameter(), eve::graphics::Mesh::hasMorphData(), key, layer, name, target , 以及 value.

◆ unbindEquipment()

EquipmentVisualChange eve::avatar::AvatarInstance::unbindEquipment ( )

Remove the equipment binding and hide all registered equipment visuals.

在文件 AvatarInstance.cpp 第 157 行定义.

引用了 eve::avatar::Removed , 以及 eve::avatar::Unchanged.

被这些函数引用 bindEquipment().

◆ unbindSkinnedPart()

EquipmentVisualChange eve::avatar::AvatarInstance::unbindSkinnedPart ( int  partIndex)

Remove a shared-pose skinned part and clear its material slot.

在文件 AvatarInstance.cpp 第 650 行定义.

引用了 found, eve::avatar::Removed, eve::graphics::Renderable3D::setPart() , 以及 eve::avatar::Unchanged.

◆ unbindTween()

void eve::avatar::AvatarInstance::unbindTween ( )

Unbinds tween.

在文件 AvatarSkeletal.cpp 第 448 行定义.

◆ unregisterMotion()

bool eve::avatar::AvatarInstance::unregisterMotion ( const std::string &  name)

Remove a registered motion without destroying its clip.

在文件 Avatar.cpp 第 83 行定义.

引用了 name.

◆ update()

void eve::avatar::AvatarInstance::update ( float  dt)

该类的文档由以下文件生成: