|
@@ -16,23 +16,14 @@
|
|
|
|
|
|
<h2>Methods</h2>
|
|
<h2>Methods</h2>
|
|
|
|
|
|
- <h3>[method:Float clamp]( [page:Float x], [page:Float a], [page:Float b] )</h3>
|
|
|
|
|
|
+ <h3>[method:Float clamp]( [page:Float value], [page:Float min], [page:Float max] )</h3>
|
|
<div>
|
|
<div>
|
|
- x — Value to be clamped.<br />
|
|
|
|
- a — Minimum value<br />
|
|
|
|
- b — Maximum value.
|
|
|
|
|
|
+ value — Value to be clamped.<br />
|
|
|
|
+ min — Minimum value<br />
|
|
|
|
+ max — Maximum value.
|
|
</div>
|
|
</div>
|
|
<div>
|
|
<div>
|
|
- Clamps the *x* to be between *a* and *b*.
|
|
|
|
- </div>
|
|
|
|
-
|
|
|
|
- <h3>[method:Float clampBottom]( [page:Float x], [page:Float a] )</h3>
|
|
|
|
- <div>
|
|
|
|
- x — Value to be clamped.<br />
|
|
|
|
- a — Minimum value
|
|
|
|
- </div>
|
|
|
|
- <div>
|
|
|
|
- Clamps the *x* to be larger than *a*.
|
|
|
|
|
|
+ Clamps the *value* to be between *min* and *max*.
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<h3>[method:Float mapLinear]( [page:Float x], [page:Float a1], [page:Float a2], [page:Float b1], [page:Float b2] )</h3>
|
|
<h3>[method:Float mapLinear]( [page:Float x], [page:Float a1], [page:Float a2], [page:Float b1], [page:Float b2] )</h3>
|
|
@@ -97,7 +88,7 @@
|
|
</div>
|
|
</div>
|
|
<div>
|
|
<div>
|
|
Returns a value between 0-1 that represents the percentage that x has moved between min and max, but smoothed or slowed down the closer X is to the min and max.<br/><br/>
|
|
Returns a value between 0-1 that represents the percentage that x has moved between min and max, but smoothed or slowed down the closer X is to the min and max.<br/><br/>
|
|
-
|
|
|
|
|
|
+
|
|
[link:http://en.wikipedia.org/wiki/Smoothstep Wikipedia]
|
|
[link:http://en.wikipedia.org/wiki/Smoothstep Wikipedia]
|
|
</div>
|
|
</div>
|
|
|
|
|
|
@@ -110,7 +101,7 @@
|
|
<div>
|
|
<div>
|
|
Returns a value between 0-1. It works the same as smoothstep, but more smooth.
|
|
Returns a value between 0-1. It works the same as smoothstep, but more smooth.
|
|
</div>
|
|
</div>
|
|
-
|
|
|
|
|
|
+
|
|
<h2>Source</h2>
|
|
<h2>Source</h2>
|
|
|
|
|
|
[link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
|
|
[link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
|