|
| 1 | +# XATHavokInterop |
| 2 | + |
| 3 | +This tool interacts with Havok files. |
| 4 | +It is not intended to be used directly by humans but should be wrapped by higher level libraries/tools. |
| 5 | + |
| 6 | +If you need to interpret Havok files you should use the XAT.Common library or write your own implementation. |
| 7 | + |
| 8 | +This tool is only intended to do the bare minimum and leave higher level logic to other libraries. |
| 9 | +For example, it assumes when converting animations that the container has already been combined even though this is never the case for animations from paps. |
| 10 | +The goal is to expose the minimum level of functionality that can then be composed by other tools for more convenience. |
| 11 | + |
| 12 | +Input is defined by arguments on the command line. |
| 13 | +Human readable output is piped to stdout. Machine readable output is piped to stderr. |
| 14 | +The tool never overrwrites any files used as source unless they are specified as the output. |
| 15 | + |
| 16 | +## API |
| 17 | +Get stats about the container - getStats(string container) -> (int skeletonCount / int animCount / int bindingCount) |
| 18 | +Create a blank animation container - createContainer(string outputPath) -> null |
| 19 | +Add animation and associated binding to container - addAnimation(string targetContainer, string sourceContainer, int sourceAnimIdx, string outputContainer) -> (int newAnimIdx / int newBindingIdx) |
| 20 | +Replace an animation and associated binding in container - replaceAnimation(string targetContainer, int targetAnimIdx, string sourceContainer, int sourceAnimIdx, string outputContainer) -> (int newAnimIdx / int newBindingIdx) |
| 21 | +Remove animation and associated binding from container - removeAnimation(string targetContainer, int animIdx, string outputContainer) -> (int newAnimAcount / int newBindingCount) |
| 22 | +Remove skeleton from container - removeSkeleton(string targetContainer, int skeletonIdx, string outputContainer) -> (int newSkeleCount) |
| 23 | +Add skeleton to container - addSkeleton(string targetContainer, string sourceContainer, int skeletonIdx, string outputContainer) -> (int newSkeleCount) |
| 24 | +Get list of bones in index order - listBones(string container, int skeletonIdx) -> (list<string />) |
| 25 | +Convert havok container to binary tagfile - toTagFile(string sourceContainer, string outputContainer) -> null |
| 26 | +Convert havok container to xml tagfile - toXMLFile(string sourceContainer, string outputContainer) -> null |
| 27 | +Convert havok container to packfile (HavokMax compatible) - toPackFile(string sourceContainer, string outputContainer) -> null |
| 28 | +Convert havok skeleton to fbx - toFbxSkeleton(string container, int skeletonIdx, string outputPath) -> (int bonesConverted) |
| 29 | +Convert havok animation to fbx - toFbxAnimation(string container, int skeletonIdx, int animIdx, string outputPath) -> (int boneConverted, int framesConverted) |
| 30 | +Get list of FBX anim stacks in order - listFbxStacks(string fbxPath) -> (list<string />) |
| 31 | +Convert FBX skeleton to havok - fromFbxSkeleton(string fbxPath, string boneOrder, string outputPath) -> (int bonesConverted) |
| 32 | +Convert FBX to havok animation - fromFbxAnimation(string fbxPath, int animStackIdx, string sourceSkeleton, int skeletonIdx, string excludeBones, string outputPath) -> (int framesConverted, int bonesBound) |
| 33 | +Get list of FBX bones in index order - listFbxBones(string container) -> (list<string />) |
| 34 | +Quanitized compression - compress(const quantized, string sourceContainerPath, int sourceAnimIdx, int sourceSkeletonIdx, float floatingTolerance, float translationTolerance, float rotationTolerance, float scaleTolerance, string outputContainerPath) -> null |
| 35 | +Predictive compression - compress(const predictive, string sourceContainerPath, int sourceAnimIdx, int sourceSkeletonIdx, float staticFloatingTolerance, float staticTranslationTolerance, float staticRotationTolerance, float staticScaleTolerance, float dynamicFloatingTolerance, float dynamicTranslationTolerance, float dynamicRotationTolerance, float dynamicScaleTolerance, string outputContainerPath) -> null |
0 commit comments