Browse Source

Merge pull request #6101 from TatumCreative/specular-bounds

Fixes to small miscellaneous docs issues
Mr.doob 10 years ago
parent
commit
0f7e38e7ed

+ 1 - 1
docs/api/cameras/CubeCamera.html

@@ -24,7 +24,7 @@
 		scene.add( cubeCamera );
 		
 		//Create car
-		var chromeMaterial = new THREE.MeshLambertMaterial( { color: 0xffffff, ambient: 0xffffff, envMap: cubeCamera.renderTarget } );
+		var chromeMaterial = new THREE.MeshLambertMaterial( { color: 0xffffff, envMap: cubeCamera.renderTarget } );
 		var car = new Mesh( carGeometry, chromeMaterial );
 		scene.add( car );
 		

+ 1 - 1
docs/api/loaders/OBJMTLLoader.html

@@ -47,7 +47,7 @@
 		</div>
 		<div>
 		Parse an <em>obj</em> text structure and return an [page:Object3D].<br />
-		Found objects are converted to [page:Mesh] with a [page:BufferGeometry] and materials are converted to [page:MeshLambertMaterial].
+		Found objects are converted to a [page:Mesh] and materials are converted to [page:MeshLambertMaterial].
 		</div>
 
 		<h2>Example</h2>

+ 0 - 5
docs/api/materials/MeshLambertMaterial.html

@@ -49,11 +49,6 @@
 		Diffuse color of the material. Default is white.<br />
 		</div>
 
-		<h3>[property:Color ambient]</h3>
-		<div>
-		Ambient color of the material, multiplied by the color of the [page:AmbientLight]. Default is white.<br />
-		</div>
-
 		<h3>[property:Color emissive]</h3>
 		<div>
 		Emissive (light) color of the material, essentially a solid color unaffected by other lighting. Default is black.<br />

+ 2 - 7
docs/api/materials/MeshPhongMaterial.html

@@ -41,7 +41,7 @@
 		</div>
 		<div>
 		Example:<br>
-		materials.push( new THREE.MeshPhongMaterial( { ambient: 0x030303, color: 0xdddddd, specular: 0x009900, shininess: 30, shading: THREE.FlatShading } ) );
+		materials.push( new THREE.MeshPhongMaterial( { color: 0xdddddd, specular: 0x009900, shininess: 30, shading: THREE.FlatShading } ) );
 	
 		</div>
 
@@ -54,11 +54,6 @@
 		Diffuse color of the material. Default is white.<br />
 		</div>
 
-		<h3>[property:Color ambient]</h3>
-		<div>
-		Ambient color of the material, multiplied by the color of the [page:AmbientLight]. Default is white.<br />
-		</div>
-
 		<h3>[property:Color emissive]</h3>
 		<div>
 		Emissive (light) color of the material, essentially a solid color unaffected by other lighting. Default is black.<br />
@@ -70,7 +65,7 @@
 		</div>
 
 		<h3>[property:Float shininess]</h3>
-		<div>How shiny the specular highlight is; a higher value gives a sharper highlight. Default is *30*.</div>
+		<div>How shiny the specular highlight is; a higher value gives a sharper highlight. Default is *30*. It should not be set to 0.</div>
 
 		<h3>[property:boolean metal]</h3>
 		<div>

+ 1 - 5
docs/scenes/js/material.js

@@ -393,7 +393,6 @@ function guiMeshLambertMaterial ( gui, mesh, material, geometry ) {
 
 	var data = {
 		color : material.color.getHex(),
-		ambient : material.ambient.getHex(),
 		emissive : material.emissive.getHex(),
 		envMaps : envMapKeys,
 		map : textureMapKeys,
@@ -407,7 +406,6 @@ function guiMeshLambertMaterial ( gui, mesh, material, geometry ) {
 	var folder = gui.addFolder('THREE.MeshLambertMaterial');
 
 	folder.addColor( data, 'color' ).onChange( handleColorChange( material.color ) );
-	folder.addColor( data, 'ambient' ).onChange( handleColorChange( material.ambient ) );
 	folder.addColor( data, 'emissive' ).onChange( handleColorChange( material.emissive ) );
 
 	folder.add( material, 'shading', constants.shading ).onChange( needsUpdate( material, geometry ) );
@@ -433,7 +431,6 @@ function guiMeshPhongMaterial ( gui, mesh, material, geometry ) {
 
 	var data = {
 		color : material.color.getHex(),
-		ambient : material.ambient.getHex(),
 		emissive : material.emissive.getHex(),
 		specular : material.specular.getHex(),
 		envMaps : envMapKeys,
@@ -446,11 +443,10 @@ function guiMeshPhongMaterial ( gui, mesh, material, geometry ) {
 	var folder = gui.addFolder('THREE.MeshPhongMaterial');
 
 	folder.addColor( data, 'color' ).onChange( handleColorChange( material.color ) );
-	folder.addColor( data, 'ambient' ).onChange( handleColorChange( material.ambient ) );
 	folder.addColor( data, 'emissive' ).onChange( handleColorChange( material.emissive ) );
 	folder.addColor( data, 'specular' ).onChange( handleColorChange( material.specular ) );
 
-	folder.add( material, 'shininess', 0, 100);
+	folder.add( material, 'shininess', 1, 100);
 	folder.add( material, 'shading', constants.shading).onChange( needsUpdate( material, geometry ) );
 	folder.add( material, 'wireframe' );
 	folder.add( material, 'wireframeLinewidth', 0, 10 );