Explorar o código

Merge branch 'patch-1' into dev

Brian A MacIntosh %!s(int64=8) %!d(string=hai) anos
pai
achega
4d1f66474b
Modificáronse 1 ficheiros con 29 adicións e 29 borrados
  1. 29 29
      docs/api/math/Color.html

+ 29 - 29
docs/api/math/Color.html

@@ -54,12 +54,12 @@ var color = new THREE.Color( 1, 0, 0 );
 		Note that standard method of specifying color in three.js is with a [link:https://en.wikipedia.org/wiki/Web_colors#Hex_triplet hexadecimal triplet], and that method is used
 		Note that standard method of specifying color in three.js is with a [link:https://en.wikipedia.org/wiki/Web_colors#Hex_triplet hexadecimal triplet], and that method is used
 		throughout the rest of the documentation.<br /><br />
 		throughout the rest of the documentation.<br /><br />
 
 
-		When all arguments are defined then r is the red component, g is the green component and b is the blue component of the color.<br />
-		When only r is defined:<br />
+		When all arguments are defined then [page:Multi r] is the red component, [page:Float g] is the green component and [page:Float b] is the blue component of the color.<br />
+		When only [page:Multi r] is defined:<br />
 		<ul>
 		<ul>
 			<li>It can be a [link:https://en.wikipedia.org/wiki/Web_colors#Hex_triplet hexadecimal triplet] representing the color (recommended).</li>
 			<li>It can be a [link:https://en.wikipedia.org/wiki/Web_colors#Hex_triplet hexadecimal triplet] representing the color (recommended).</li>
 			<li>It can be an another Color instance.</li>
 			<li>It can be an another Color instance.</li>
-			<li>It can be a CSS style string. For Instance:
+			<li>It can be a CSS-style string. For example:
 				<ul>
 				<ul>
 					<li>'rgb(250, 0,0)'</li>
 					<li>'rgb(250, 0,0)'</li>
 					<li>'rgb(100%,0%,0%)'</li>
 					<li>'rgb(100%,0%,0%)'</li>
@@ -114,7 +114,7 @@ var color = new THREE.Color( 1, 0, 0 );
 		<div>Adds [page:Number s] to the RGB values of this color.</div>
 		<div>Adds [page:Number s] to the RGB values of this color.</div>
 
 
 		<h3>[method:Color clone]() </h3>
 		<h3>[method:Color clone]() </h3>
-		<div>Returns a new Color with the same  [page:.r r], [page:.g g] and [page:.b b] parameters a this one.</div>
+		<div>Returns a new Color with the same [page:.r r], [page:.g g] and [page:.b b] values as this one.</div>
 
 
 		<h3>[method:Color copy]( [page:Color color] ) </h3>
 		<h3>[method:Color copy]( [page:Color color] ) </h3>
 		<div>
 		<div>
@@ -122,17 +122,17 @@ var color = new THREE.Color( 1, 0, 0 );
 		</div>
 		</div>
 
 
 		<h3>[method:Color convertGammaToLinear]() </h3>
 		<h3>[method:Color convertGammaToLinear]() </h3>
-		<div>Converts this color from gamma to linear space (squares the values of [page:.r r], [page:.g g] and [page:.b b] ).</div>
+		<div>Converts this color from gamma to linear space by squaring the values of [page:.r r], [page:.g g] and [page:.b b] ).</div>
 
 
 		<h3>[method:Color convertLinearToGamma]() </h3>
 		<h3>[method:Color convertLinearToGamma]() </h3>
-		<div>Converts this color from linear to gamma space (takes the squareroot of [page:.r r], [page:.g g] and [page:.b b]).</div>
+		<div>Converts this color from linear to gamma space by taking the square root of [page:.r r], [page:.g g] and [page:.b b]).</div>
 
 
 		<h3>[method:Color copyGammaToLinear]( [page:Color color], [page:Float gammaFactor] ) </h3>
 		<h3>[method:Color copyGammaToLinear]( [page:Color color], [page:Float gammaFactor] ) </h3>
 		<div>
 		<div>
 		[page:Color color] — Color to copy.<br />
 		[page:Color color] — Color to copy.<br />
 		[page:Float gammaFactor] - (optional). Default is *2.0*.<br /><br />
 		[page:Float gammaFactor] - (optional). Default is *2.0*.<br /><br />
 
 
-		Copies given color making conversion from gamma to linear space,
+		Copies the given color into this color while converting it from gamma to linear space
 		by taking [page:.r r], [page:.g g] and [page:.b b] to the power of [page:Float gammaFactor].
 		by taking [page:.r r], [page:.g g] and [page:.b b] to the power of [page:Float gammaFactor].
 		</div>
 		</div>
 
 
@@ -141,16 +141,16 @@ var color = new THREE.Color( 1, 0, 0 );
 		[page:Color color] — Color to copy.<br />
 		[page:Color color] — Color to copy.<br />
 		[page:Float gammaFactor] - (optional). Default is *2.0*.<br /><br />
 		[page:Float gammaFactor] - (optional). Default is *2.0*.<br /><br />
 
 
-		Copies given color making conversion from linear to gamma space,
+		Copies the given color into this color while converting it from linear to gamma space
 		by taking [page:.r r], [page:.g g] and [page:.b b] to the power of 1 / [page:Float gammaFactor].
 		by taking [page:.r r], [page:.g g] and [page:.b b] to the power of 1 / [page:Float gammaFactor].
 		</div>
 		</div>
 
 
 		<h3>[method:Boolean equals]( [page:Color color] ) </h3>
 		<h3>[method:Boolean equals]( [page:Color color] ) </h3>
-		<div>Compares [page:Color color] with this one and returns true if they are the same, false otherwise.</div>
+		<div>Compares the RGB values of [page:Color color] with those of this object. Returns true if they are the same, false otherwise.</div>
 
 
 		<h3>[method:Color fromArray]( [page:Array array], [page:Integer offset] ) </h3>
 		<h3>[method:Color fromArray]( [page:Array array], [page:Integer offset] ) </h3>
 		<div>
 		<div>
-		[page:Array array] - [page:Array] of float in the form [ [page:Float r], [page:Float g], [page:Float b] ].<br />
+		[page:Array array] - [page:Array] of floats in the form [ [page:Float r], [page:Float g], [page:Float b] ].<br />
 		[page:Integer offset] - An optional offset into the array.<br /><br />
 		[page:Integer offset] - An optional offset into the array.<br /><br />
 
 
 		Sets this color's components based on an array formatted like [ [page:Float r], [page:Float g], [page:Float b] ].
 		Sets this color's components based on an array formatted like [ [page:Float r], [page:Float g], [page:Float b] ].
@@ -160,14 +160,14 @@ var color = new THREE.Color( 1, 0, 0 );
 		<div>Returns the hexadecimal value of this color.</div>
 		<div>Returns the hexadecimal value of this color.</div>
 
 
 		<h3>[method:String getHexString]()</h3>
 		<h3>[method:String getHexString]()</h3>
-		<div>Returns the string formatted hexadecimal value of this color.</div>
+		<div>Returns the hexadecimal value of this color as a string (for example, 'FFFFFF').</div>
 
 
 		<h3>[method:Object getHSL]( [page:Object optionalTarget] )</h3>
 		<h3>[method:Object getHSL]( [page:Object optionalTarget] )</h3>
 		<div>
 		<div>
-			[page:Object optionalTarget] — (optional) if specified, adds h, s and l keys to object (if not already present)
-			and sets the results there, otherwise a new Object will be created. <br /><br />
+			[page:Object optionalTarget] — (optional) if specified, adds h, s and l keys to the object (if not already present)
+			and sets the results there. Otherwise, a new Object will be created. <br /><br />
 
 
-			Convert the values [page:.r r], [page:.g g] and [page:.b b] to [link:https://en.wikipedia.org/wiki/HSL_and_HSV HSL]
+			Convert this Color's [page:.r r], [page:.g g] and [page:.b b] values to [link:https://en.wikipedia.org/wiki/HSL_and_HSV HSL]
 			format and returns an object of the form:
 			format and returns an object of the form:
 
 
 			<code>
 			<code>
@@ -177,29 +177,29 @@ var color = new THREE.Color( 1, 0, 0 );
 		</div>
 		</div>
 
 
 		<h3>[method:String getStyle]()</h3>
 		<h3>[method:String getStyle]()</h3>
-		<div>Returns the value of this color as a CSS-style string. Example: 'rgb(255,0,0)'.</div>
+		<div>Returns the value of this color as a CSS style string. Example: 'rgb(255,0,0)'.</div>
 
 
 		<h3>[method:Color lerp]( [page:Color color], [page:Float alpha] ) </h3>
 		<h3>[method:Color lerp]( [page:Color color], [page:Float alpha] ) </h3>
 		<div>
 		<div>
 		[page:Color color] - color to converge on.<br />
 		[page:Color color] - color to converge on.<br />
 		[page:Float alpha] - interpolation factor in the closed interval [0, 1].<br /><br />
 		[page:Float alpha] - interpolation factor in the closed interval [0, 1].<br /><br />
 
 
-		Linear interpolation of this colors RGB values and the RGB values of the passed argument.
-		The alpha argument can be thought of as the percent between the two colors, where 0 is
-		this color and 1 is the first argument.
+		Linearly interpolates this color's RGB values toward the RGB values of the passed argument.
+		The alpha argument can be thought of as the ratio between the two colors, where 0.0 is
+		this color and 1.0 is the first argument.
 		</div>
 		</div>
 
 
 		<h3>[method:Color multiply]( [page:Color color] ) </h3>
 		<h3>[method:Color multiply]( [page:Color color] ) </h3>
-		<div>Multiplies this color's RGB values by given [page:Color color]'s RGB values.</div>
+		<div>Multiplies this color's RGB values by the given [page:Color color]'s RGB values.</div>
 
 
 		<h3>[method:Color multiplyScalar]( [page:Number s] ) </h3>
 		<h3>[method:Color multiplyScalar]( [page:Number s] ) </h3>
 		<div>Multiplies this color's RGB values by [page:Number s].</div>
 		<div>Multiplies this color's RGB values by [page:Number s].</div>
 
 
 		<h3>[method:Color offsetHSL]( [page:Float h], [page:Float s], [page:Float l] ) </h3>
 		<h3>[method:Color offsetHSL]( [page:Float h], [page:Float s], [page:Float l] ) </h3>
 		<div>
 		<div>
-			Adds given [page:Float h], [page:Float s], and [page:Float l] to this color's existing values.
-			Internally this converts the [page:.r r], [page:.g g] and [page:.b b] values to HSL, adds
-			[page:Float h], [page:Float s], and [page:Float l] and then converts back to RGB.
+			Adds the given [page:Float h], [page:Float s], and [page:Float l] to this color's values.
+			Internally, this converts the color's [page:.r r], [page:.g g] and [page:.b b] values to HSL, adds
+			[page:Float h], [page:Float s], and [page:Float l], and then converts the color back to RGB.
 		</div>
 		</div>
 
 
 		<h3>[method:Color set]( [page:Multi value] ) </h3>
 		<h3>[method:Color set]( [page:Multi value] ) </h3>
@@ -207,7 +207,7 @@ var color = new THREE.Color( 1, 0, 0 );
 		[page:Multi value] - Value to set this color to.<br /><br />
 		[page:Multi value] - Value to set this color to.<br /><br />
 
 
 		See the Constructor above for full details of what [page:Multi value] can be.
 		See the Constructor above for full details of what [page:Multi value] can be.
-		Delegates to [page:.copy], .setStyle, or .setHex depending on input type.
+		Delegates to [page:.copy], [page:.setStyle], or [page:.setHex] depending on input type.
 		</div>
 		</div>
 
 
 		<h3>[method:Color setHex]( [page:Integer hex] ) </h3>
 		<h3>[method:Color setHex]( [page:Integer hex] ) </h3>
@@ -228,9 +228,9 @@ var color = new THREE.Color( 1, 0, 0 );
 
 
 		<h3>[method:Color setRGB]( [page:Float r], [page:Float g], [page:Float b] ) </h3>
 		<h3>[method:Color setRGB]( [page:Float r], [page:Float g], [page:Float b] ) </h3>
 		<div>
 		<div>
-		[page:Float r] — Red channel value between 0 and 1.<br />
-		[page:Float g] — Green channel value between 0 and 1.<br />
-		[page:Float b] — Blue channel value between 0 and 1.<br /><br />
+		[page:Float r] — Red channel value between 0.0 and 1.0.<br />
+		[page:Float g] — Green channel value between 0.0 and 1.0.<br />
+		[page:Float b] — Blue channel value between 0.0 and 1.0.<br /><br />
 
 
 		Sets this color from RGB values.
 		Sets this color from RGB values.
 		</div>
 		</div>
@@ -255,7 +255,7 @@ var color = new THREE.Color( 1, 0, 0 );
 		"red" ( or any [link:https://en.wikipedia.org/wiki/X11_color_names#Color_name_chart X11 color name]
 		"red" ( or any [link:https://en.wikipedia.org/wiki/X11_color_names#Color_name_chart X11 color name]
 		- all 140 color names are supported ).<br />
 		- all 140 color names are supported ).<br />
 
 
-		Transluent colors such as "rgba(255, 0, 0, 0.5)" and "hsla(0, 100%, 50%, 0.5)" are also accepted,
+		Translucent colors such as "rgba(255, 0, 0, 0.5)" and "hsla(0, 100%, 50%, 0.5)" are also accepted,
 		but the alpha-channel coordinate will be discarded.<br /><br />
 		but the alpha-channel coordinate will be discarded.<br /><br />
 
 
 		Note that for X11 color names, multiple words such as Dark Orange become the string 'darkorange' (all lowercase).
 		Note that for X11 color names, multiple words such as Dark Orange become the string 'darkorange' (all lowercase).
@@ -263,8 +263,8 @@ var color = new THREE.Color( 1, 0, 0 );
 
 
 		<h3>[method:Color sub]( [page:Color color] ) </h3>
 		<h3>[method:Color sub]( [page:Color color] ) </h3>
 		<div>
 		<div>
-		Subtracts RGB components of the given color from the RGB components of this color.
-		If a component is negative, it is set to zero.
+		Subtracts the RGB components of the given color from the RGB components of this color.
+		If this results in a negative component, that component is set to zero.
 		</div>
 		</div>
 
 
 		<h3>[method:Array toArray]( [page:Array array], [page:Integer offset] ) </h3>
 		<h3>[method:Array toArray]( [page:Array array], [page:Integer offset] ) </h3>