diff --git a/docs/api/materials/MeshPhongMaterial.html b/docs/api/materials/MeshPhongMaterial.html
index f61c04f2e87dec45c869e019e2e04486e9c5691a..dcfb4ea9e7d3939c020ab37fd416b7151fc3da63 100644
--- a/docs/api/materials/MeshPhongMaterial.html
+++ b/docs/api/materials/MeshPhongMaterial.html
@@ -70,13 +70,6 @@
[property:Float shininess]
How shiny the specular highlight is; a higher value gives a sharper highlight. Default is *30*.
- [property:boolean metal]
-
- If set to true the shader multiplies the specular highlight by the underlying color of the object, making
- it appear to be more metal-like and darker. If set to false the specular highlight is added ontop of the
- underlying colors.
-
-
[property:Texture map]
Set color texture map. Default is null. The texture map color is modulated by the diffuse color.
diff --git a/src/Three.Legacy.js b/src/Three.Legacy.js
index 938e68327aad85730ca0f039c52a17f3a7fe4cb4..b99f072fac53ea949e3fa736a9a35be7b58ca3a3 100644
--- a/src/Three.Legacy.js
+++ b/src/Three.Legacy.js
@@ -348,10 +348,22 @@ Object.defineProperties( THREE, {
}
} );
+Object.defineProperties( THREE.MeshPhongMaterial.prototype, {
+ metal: {
+ get: function () {
+ console.warn( 'THREE.MeshPhongMaterial: .metal has been removed. Use THREE.MeshPhysicalMaterial instead.' );
+ return false;
+ },
+ set: function ( value ) {
+ console.warn( 'THREE.MeshPhongMaterial: .metal has been removed. Use THREE.MeshPhysicalMaterial instead' );
+ }
+ }
+} );
+
Object.defineProperties( THREE.ShaderMaterial.prototype, {
derivatives: {
get: function () {
- console.warn( 'THREE. ShaderMaterial: .derivatives has been moved to .extensions.derivatives.' );
+ console.warn( 'THREE.ShaderMaterial: .derivatives has been moved to .extensions.derivatives.' );
return this.extensions.derivatives;
},
set: function ( value ) {
diff --git a/src/materials/MeshPhongMaterial.js b/src/materials/MeshPhongMaterial.js
index 2940d3a16484edf105a9f9a17631aaa4d1c75e3e..94b067cf8eb2303e016acf1d49a58b56a26863b2 100644
--- a/src/materials/MeshPhongMaterial.js
+++ b/src/materials/MeshPhongMaterial.js
@@ -67,8 +67,6 @@ THREE.MeshPhongMaterial = function ( parameters ) {
this.specular = new THREE.Color( 0x111111 );
this.shininess = 30;
- this.metal = false;
-
this.map = null;
this.lightMap = null;
@@ -129,8 +127,6 @@ THREE.MeshPhongMaterial.prototype.copy = function ( source ) {
this.specular.copy( source.specular );
this.shininess = source.shininess;
- this.metal = source.metal;
-
this.map = source.map;
this.lightMap = source.lightMap;
diff --git a/src/renderers/shaders/ShaderLib.js b/src/renderers/shaders/ShaderLib.js
index ed234c3863bf4434f105e28c73ecee799408788c..5c5227cd838b660d8854abde0bcc3641ac6e0ab5 100644
--- a/src/renderers/shaders/ShaderLib.js
+++ b/src/renderers/shaders/ShaderLib.js
@@ -395,15 +395,7 @@ THREE.ShaderLib = {
"reflectedLight.directDiffuse *= shadowMask;",
"reflectedLight.directSpecular *= shadowMask;",
- "#ifdef METAL",
-
- " vec3 outgoingLight = ( reflectedLight.directDiffuse + reflectedLight.indirectDiffuse ) * specular + reflectedLight.directSpecular + reflectedLight.indirectSpecular + totalEmissiveLight;",
-
- "#else",
-
- " vec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + reflectedLight.directSpecular + reflectedLight.indirectSpecular + totalEmissiveLight;",
-
- "#endif",
+ "vec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + reflectedLight.directSpecular + reflectedLight.indirectSpecular + totalEmissiveLight;",
THREE.ShaderChunk[ "envmap_fragment" ],
THREE.ShaderChunk[ "linear_to_gamma_fragment" ],
diff --git a/src/renderers/webgl/WebGLProgram.js b/src/renderers/webgl/WebGLProgram.js
index ba7acab2938c7305ac80afb6fd847c0dbd6c3112..6c768e0390a8f4881e0cf3cef7f73d76dd67b821 100644
--- a/src/renderers/webgl/WebGLProgram.js
+++ b/src/renderers/webgl/WebGLProgram.js
@@ -391,7 +391,6 @@ THREE.WebGLProgram = ( function () {
parameters.flatShading ? '#define FLAT_SHADED' : '',
- parameters.metal ? '#define METAL' : '',
parameters.doubleSided ? '#define DOUBLE_SIDED' : '',
parameters.flipSided ? '#define FLIP_SIDED' : '',
diff --git a/src/renderers/webgl/WebGLPrograms.js b/src/renderers/webgl/WebGLPrograms.js
index bd99ed65c5cd74223ad73b913a9fb57c22b96a6b..eac00e2e4f73070143ac20c598709b4cfd436ed3 100644
--- a/src/renderers/webgl/WebGLPrograms.js
+++ b/src/renderers/webgl/WebGLPrograms.js
@@ -23,7 +23,7 @@ THREE.WebGLPrograms = function ( renderer, capabilities ) {
"maxBones", "useVertexTexture", "morphTargets", "morphNormals",
"maxMorphTargets", "maxMorphNormals", "maxDirLights", "maxPointLights",
"maxSpotLights", "maxHemiLights", "maxShadows", "shadowMapEnabled", "pointLightShadows",
- "shadowMapType", "shadowMapDebug", "alphaTest", "metal", "doubleSided",
+ "shadowMapType", "shadowMapDebug", "alphaTest", "doubleSided",
"flipSided"
];
@@ -144,7 +144,6 @@ THREE.WebGLPrograms = function ( renderer, capabilities ) {
shadowMapDebug: renderer.shadowMap.debug,
alphaTest: material.alphaTest,
- metal: material.metal,
doubleSided: material.side === THREE.DoubleSide,
flipSided: material.side === THREE.BackSide