AnimationUtils.html 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8" />
  5. <base href="../../../" />
  6. <script src="list.js"></script>
  7. <script src="page.js"></script>
  8. <link type="text/css" rel="stylesheet" href="page.css" />
  9. </head>
  10. <body>
  11. <h1>[name]</h1>
  12. <p class="desc">
  13. An object with various functions to assist with animations, used internally.
  14. </p>
  15. <h2>Methods</h2>
  16. <h3>[method:Array arraySlice]( array, from, to )</h3>
  17. <p>
  18. This is the same as Array.prototype.slice, but also works on typed arrays.
  19. </p>
  20. <h3>[method:Array convertArray]( array, type, forceClone )</h3>
  21. <p>
  22. Converts an array to a specific type.
  23. </p>
  24. <h3>[method:Array flattenJSON]( jsonKeys, times, values, valuePropertyName )</h3>
  25. <p>
  26. Used for parsing AOS keyframe formats.
  27. </p>
  28. <h3>[method:Array getKeyframeOrder]( times )</h3>
  29. <p>
  30. Returns an array by which times and values can be sorted.
  31. </p>
  32. <h3>[method:Number insertKeyframe]( [param:KeyframeTrack track], [param:Number time] )</h3>
  33. <p>
  34. Inserts a new keyframe into the track at the given time, if it doesn't already exist. Keyframe
  35. values are interpolated from existing keyframes. Returns the keyframe index.
  36. </p>
  37. <h3>[method:Boolean isTypedArray]( object )</h3>
  38. <p>
  39. Returns *true* if the object is a typed array.
  40. </p>
  41. <h3>[method:AnimationClip mergeMorphTargetTracks]( [param:AnimationClip clip], [param:Object3D root] )</h3>
  42. <p>
  43. Merges all KeyframeTracks that animate morph targets on a single mesh. The clip provided will
  44. be modified and returned.
  45. </p>
  46. <p>
  47. If a clip contains three tracks each controlling one of an object's five morph targets, those
  48. three tracks will be merged and two empty tracks created for the remaining morph targets, so
  49. that all morph targets are controlled by a single track.
  50. </p>
  51. <h3>[method:Array sortedArray]( values, stride, order )</h3>
  52. <p>
  53. Sorts the array previously returned by [page:AnimationUtils.getKeyframeOrder getKeyframeOrder].
  54. </p>
  55. <h2>Source</h2>
  56. [link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
  57. </body>
  58. </html>