Browse Source

Created docs for animation / keyframes (#10073)

* Added tracks to list.js

* Created docs for animation tracks

* Update list.js

* Fixed error in list.js caused by pull request
Lewy Blue 8 years ago
parent
commit
9ef93f299d

+ 72 - 0
docs/api/animation/tracks/BooleanKeyframeTrack.html

@@ -0,0 +1,72 @@
+<!DOCTYPE html>
+<html lang="en">
+  <head>
+    <meta charset="utf-8" />
+    <base href="../../../" />
+    <script src="list.js"></script>
+    <script src="page.js"></script>
+    <link type="text/css" rel="stylesheet" href="page.css" />
+  </head>
+  <body>
+
+		[page:KeyframeTrack] &rarr;
+
+    <h1>[name]</h1>
+
+    <div class="desc">
+     A Track of Boolean keyframe values.
+    </div>
+
+
+    <h2>Constructor</h2>
+
+
+    <h3>[name]( [page:String name], [page:Array times], [page:Array values] )</h3>
+    <div>
+      -- [page:String name] (required) identifier for the KeyframeTrack.<br />
+      -- [page:Array times] (required) array of keyframe times<br />
+      -- [page:Array values] values for the keyframes at the times specified.<br />
+    </div>
+
+    <h2>Properties</h2>
+
+		See [page:KeyframeTrack] for inherited properties.
+
+
+    <h3>[property:String ValueTypeName]</h3>
+    <div>
+    String 'bool'.
+    </div>
+
+    <h3>[property:Constant DefaultInterpolation]</h3>
+    <div>
+    The default interpolation type to use, [page:Animation InterpolateDiscrete].
+    </div>
+
+
+    <h2>Methods</h2>
+
+		See [page:KeyframeTrack] for inherited methods.
+
+    <h3>[method:null InterpolantFactoryMethodLinear ](  )</h3>
+    <div>
+      The value of this method here is 'undefined', as it does not make sense for discrete properties.
+    </div>
+
+    <h3>[method:null InterpolantFactoryMethodSmooth ](  )</h3>
+    <div>
+      The value of this method here is 'undefined', as it does not make sense for discrete properties.
+    </div>
+
+    <h3>[method:null ValueBufferType ](  )</h3>
+    <div>
+      Used to convert the values array passed in the constructor to an Array.
+			Note: In this case this does nothing, other Track types may convert the array to a Typed Array.
+    </div>
+
+    <h2>Source</h2>
+
+
+    [link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
+  </body>
+</html>

+ 52 - 0
docs/api/animation/tracks/ColorKeyframeTrack.html

@@ -0,0 +1,52 @@
+<!DOCTYPE html>
+<html lang="en">
+  <head>
+    <meta charset="utf-8" />
+    <base href="../../../" />
+    <script src="list.js"></script>
+    <script src="page.js"></script>
+    <link type="text/css" rel="stylesheet" href="page.css" />
+  </head>
+  <body>
+
+		[page:KeyframeTrack] &rarr;
+
+    <h1>[name]</h1>
+
+    <div class="desc">
+     A Track of keyframe values that represent color.
+    </div>
+
+
+    <h2>Constructor</h2>
+
+
+    <h3>[name]( [page:String name], [page:Array times], [page:Array values] )</h3>
+    <div>
+      -- [page:String name] (required) identifier for the KeyframeTrack.<br />
+      -- [page:Array times] (required) array of keyframe times<br />
+      -- [page:Array values] values for the keyframes at the times specified.<br />
+			-- [page:Constant interpolation] the type of interpolation to use. See [page:Animation Animation Constants] for possible values.
+      Default is [page:Animation InterpolateLinear].
+    </div>
+
+    <h2>Properties</h2>
+
+		See [page:KeyframeTrack] for inherited properties.
+
+    <h3>[property:String ValueTypeName]</h3>
+    <div>
+    String 'color'.
+    </div>
+
+    <h2>Methods</h2>
+
+		See [page:KeyframeTrack] for inherited methods.
+
+
+    <h2>Source</h2>
+
+
+    [link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
+  </body>
+</html>

+ 52 - 0
docs/api/animation/tracks/NumberKeyframeTrack.html

@@ -0,0 +1,52 @@
+<!DOCTYPE html>
+<html lang="en">
+  <head>
+    <meta charset="utf-8" />
+    <base href="../../../" />
+    <script src="list.js"></script>
+    <script src="page.js"></script>
+    <link type="text/css" rel="stylesheet" href="page.css" />
+  </head>
+  <body>
+
+		[page:KeyframeTrack] &rarr;
+
+    <h1>[name]</h1>
+
+    <div class="desc">
+     A Track of numeric keyframe values.
+    </div>
+
+
+    <h2>Constructor</h2>
+
+
+    <h3>[name]( [page:String name], [page:Array times], [page:Array values] )</h3>
+    <div>
+      -- [page:String name] (required) identifier for the KeyframeTrack.<br />
+      -- [page:Array times] (required) array of keyframe times<br />
+      -- [page:Array values] values for the keyframes at the times specified.<br />
+			-- [page:Constant interpolation] the type of interpolation to use. See [page:Animation Animation Constants] for possible values.
+      Default is [page:Animation InterpolateLinear].
+    </div>
+
+    <h2>Properties</h2>
+
+		See [page:KeyframeTrack] for inherited properties.
+
+
+    <h3>[property:String ValueTypeName]</h3>
+    <div>
+    String 'number'.
+    </div>
+
+    <h2>Methods</h2>
+
+		See [page:KeyframeTrack] for inherited methods.
+
+    <h2>Source</h2>
+
+
+    [link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
+  </body>
+</html>

+ 69 - 0
docs/api/animation/tracks/QuaternionKeyframeTrack.html

@@ -0,0 +1,69 @@
+<!DOCTYPE html>
+<html lang="en">
+  <head>
+    <meta charset="utf-8" />
+    <base href="../../../" />
+    <script src="list.js"></script>
+    <script src="page.js"></script>
+    <link type="text/css" rel="stylesheet" href="page.css" />
+  </head>
+  <body>
+
+		[page:KeyframeTrack] &rarr;
+
+    <h1>[name]</h1>
+
+    <div class="desc">
+     A Track of quaternion keyframe values.
+    </div>
+
+
+    <h2>Constructor</h2>
+
+
+    <h3>[name]( [page:String name], [page:Array times], [page:Array values] )</h3>
+    <div>
+      -- [page:String name] (required) identifier for the KeyframeTrack.<br />
+      -- [page:Array times] (required) array of keyframe times<br />
+      -- [page:Array values] values for the keyframes at the times specified.<br />
+			-- [page:Constant interpolation] the type of interpolation to use. See [page:Animation Animation Constants] for possible values.
+      Default is [page:Animation InterpolateLinear].
+    </div>
+
+    <h2>Properties</h2>
+
+		See [page:KeyframeTrack] for inherited properties.
+
+
+    <h3>[property:String ValueTypeName]</h3>
+    <div>
+    String 'quaternion'.
+    </div>
+
+    <h3>[property:Constant DefaultInterpolation]</h3>
+    <div>
+    The default interpolation type to use, [page:Animation InterpolateLinear].
+    </div>
+
+
+    <h2>Methods</h2>
+
+		See [page:KeyframeTrack] for inherited methods.
+
+    <h3>[method:Number getValueSize ](  )</h3>
+    <div>
+      The the size of each value (length of the values array divied by length of times array).
+    </div>
+
+    <h3>[method:null InterpolantFactoryMethodLinear ](  )</h3>
+    <div>
+      Returns a new [page:QuaternionLinearInterpolant QuaternionLinearInterpolant] based on the [page:KeyframeTrack.values values],
+			[page:KeyframeTrack.times times] and [page:KeyframeTrack.valueSize valueSize] of the keyframes.
+    </div>
+
+
+    <h2>Source</h2>
+
+    [link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
+  </body>
+</html>

+ 74 - 0
docs/api/animation/tracks/StringKeyframeTrack.html

@@ -0,0 +1,74 @@
+<!DOCTYPE html>
+<html lang="en">
+  <head>
+    <meta charset="utf-8" />
+    <base href="../../../" />
+    <script src="list.js"></script>
+    <script src="page.js"></script>
+    <link type="text/css" rel="stylesheet" href="page.css" />
+  </head>
+  <body>
+
+		[page:KeyframeTrack] &rarr;
+
+    <h1>[name]</h1>
+
+    <div class="desc">
+     A Track of String keyframe values.
+    </div>
+
+
+    <h2>Constructor</h2>
+
+
+    <h3>[name]( [page:String name], [page:Array times], [page:Array values] )</h3>
+    <div>
+      -- [page:String name] (required) identifier for the KeyframeTrack.<br />
+      -- [page:Array times] (required) array of keyframe times<br />
+      -- [page:Array values] values for the keyframes at the times specified.<br />
+			-- [page:Constant interpolation] the type of interpolation to use. See [page:Animation Animation Constants] for possible values.
+      Default is [page:Animation InterpolateDiscrete].
+    </div>
+
+    <h2>Properties</h2>
+
+		See [page:KeyframeTrack] for inherited properties.
+
+
+    <h3>[property:String ValueTypeName]</h3>
+    <div>
+    String 'string'.
+    </div>
+
+    <h3>[property:Constant DefaultInterpolation]</h3>
+    <div>
+    The default interpolation type to use, [page:Animation InterpolateDiscrete].
+    </div>
+
+
+    <h2>Methods</h2>
+
+		See [page:KeyframeTrack] for inherited methods.
+
+    <h3>[method:null InterpolantFactoryMethodLinear ](  )</h3>
+    <div>
+      The value of this method here is 'undefined', as it does not make sense for discrete properties.
+    </div>
+
+    <h3>[method:null InterpolantFactoryMethodSmooth ](  )</h3>
+    <div>
+      The value of this method here is 'undefined', as it does not make sense for discrete properties.
+    </div>
+
+    <h3>[method:null ValueBufferType ](  )</h3>
+    <div>
+      Used to convert the values array passed in the constructor to an Array.
+			Note: In this case this does nothing, other Track types may convert the array to a Typed Array.
+    </div>
+
+    <h2>Source</h2>
+
+
+    [link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
+  </body>
+</html>

+ 51 - 0
docs/api/animation/tracks/VectorKeyframeTrack.html

@@ -0,0 +1,51 @@
+<!DOCTYPE html>
+<html lang="en">
+  <head>
+    <meta charset="utf-8" />
+    <base href="../../../" />
+    <script src="list.js"></script>
+    <script src="page.js"></script>
+    <link type="text/css" rel="stylesheet" href="page.css" />
+  </head>
+  <body>
+
+		[page:KeyframeTrack] &rarr;
+
+    <h1>[name]</h1>
+
+    <div class="desc">
+     A Track of Vector keyframe values.
+    </div>
+
+
+    <h2>Constructor</h2>
+
+
+    <h3>[name]( [page:String name], [page:Array times], [page:Array values] )</h3>
+    <div>
+      -- [page:String name] (required) identifier for the KeyframeTrack.<br />
+      -- [page:Array times] (required) array of keyframe times<br />
+      -- [page:Array values] values for the keyframes at the times specified.<br />
+			-- [page:Constant interpolation] the type of interpolation to use. See [page:Animation Animation Constants] for possible values.
+      Default is [page:Animation InterpolateLinear].
+    </div>
+
+    <h2>Properties</h2>
+
+		See [page:KeyframeTrack] for inherited properties.
+
+    <h3>[property:String ValueTypeName]</h3>
+    <div>
+    String 'vector'.
+    </div>
+
+    <h2>Methods</h2>
+
+		See [page:KeyframeTrack] for inherited methods.
+
+    <h2>Source</h2>
+
+
+    [link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
+  </body>
+</html>

+ 9 - 0
docs/list.js

@@ -20,6 +20,15 @@ var list = {
 			[ "PropertyMixer", "api/animation/PropertyMixer" ]
 		],
 
+		"Animation / Tracks": [
+		  [ "BooleanKeyframeTrack", "api/animation/tracks/BooleanKeyframeTrack" ],
+		  [ "ColorKeyframeTrack", "api/animation/tracks/ColorKeyframeTrack" ],
+		  [ "NumberKeyframeTrack", "api/animation/tracks/NumberKeyframeTrack" ],
+		  [ "QuaternionKeyframeTrack", "api/animation/tracks/QuaternionKeyframeTrack" ],
+		  [ "StringKeyframeTrack", "api/animation/tracks/StringKeyframeTrack" ],
+		  [ "VectorKeyframeTrack", "api/animation/tracks/VectorKeyframeTrack" ]
+		],
+
 		"Audio": [
 			[ "Audio", "api/audio/Audio" ],
 			[ "AudioAnalyser", "api/audio/AudioAnalyser" ],