Class AnimGraphModelInfo
Namespace: ValveResourceFormat.IO
Assembly: ValveResourceFormat.dll
Resolves human-readable names (bones, sequences, weight lists, IK chains, feet, attachments, look-at chains) for an animation graph from its referenced model. Shared by the extractor and the GUI graph viewer.
public sealed class AnimGraphModelInfoInheritance
object ← AnimGraphModelInfo
Remarks
The referenced model Resource is supplied lazily through a provider so each owner keeps control of its loading and disposal; this type only reads from it.
Constructors
AnimGraphModelInfo(IFileLoader, Func<Resource?>)
Initializes a new instance of the AnimGraphModelInfo class.
public AnimGraphModelInfo(IFileLoader fileLoader, Func<Resource?> resourceProvider)Parameters
fileLoader IFileLoader
Loader used to resolve animations referenced by the model.
resourceProvider Func<Resource?>
Lazily returns the referenced model resource (or null).
Methods
FindMatchingAttachmentName(KVObject)
Resolves the model attachment that matches a compiled attachment, by name when available or otherwise by comparing bone influences. Returns empty when no match is found.
public string FindMatchingAttachmentName(KVObject compiledAttachment)Parameters
compiledAttachment KVObject
Returns
string
FindMatchingLookAtChainName(KVObject)
Finds the model look-at chain whose bones match the compiled m_bones collection.
public string FindMatchingLookAtChainName(KVObject compiledBones)Parameters
compiledBones KVObject
Returns
string
GetBoneName(int)
Returns the bone name at the given skeleton index, or empty when out of range.
public string GetBoneName(int boneIndex)Parameters
boneIndex int
Returns
string
GetBoneNamesFromIndices(KVObject)
Returns the bone names referenced by a compiled m_bones collection.
public string[] GetBoneNamesFromIndices(KVObject compiledBones)Parameters
compiledBones KVObject
Returns
string[]
GetFootName(int)
Returns the foot name at the given index, or empty when out of range.
public string GetFootName(int footIndex)Parameters
footIndex int
Returns
string
GetIKChainName(int)
Returns the IK chain name at the given index, or empty when out of range.
public string GetIKChainName(int ikChainIndex)Parameters
ikChainIndex int
Returns
string
GetIKChainNameByBoneIndices(int, int, int)
Finds the IK chain whose three joints match the given fixed/middle/end bone indices.
public string GetIKChainNameByBoneIndices(int fixedBoneIndex, int middleBoneIndex, int endBoneIndex)Parameters
fixedBoneIndex int
middleBoneIndex int
endBoneIndex int
Returns
string
GetSequenceName(long)
Returns the sequence name, falling back to a generated placeholder.
public string GetSequenceName(long sequenceIndex)Parameters
sequenceIndex long
Returns
string
GetWeightListName(long)
Returns the weight list (bone mask) name, falling back to a generated placeholder.
public string GetWeightListName(long weightListIndex)Parameters
weightListIndex long
Returns
string

