|
@@ -303,7 +303,12 @@ function WebGLPrograms( renderer, environments, extensions, capabilities, bindin
|
|
|
useFog: material.fog === true,
|
|
useFog: material.fog === true,
|
|
|
fogExp2: ( !! fog && fog.isFogExp2 ),
|
|
fogExp2: ( !! fog && fog.isFogExp2 ),
|
|
|
|
|
|
|
|
- flatShading: ( material.flatShading === true && material.wireframe === false ),
|
|
|
|
|
|
|
+ flatShading: material.wireframe === false && (
|
|
|
|
|
+ material.flatShading === true ||
|
|
|
|
|
+ ( geometry.attributes.normal === undefined && HAS_NORMALMAP === false &&
|
|
|
|
|
+ ( material.isMeshLambertMaterial || material.isMeshPhongMaterial || material.isMeshStandardMaterial || material.isMeshPhysicalMaterial )
|
|
|
|
|
+ )
|
|
|
|
|
+ ),
|
|
|
|
|
|
|
|
sizeAttenuation: material.sizeAttenuation === true,
|
|
sizeAttenuation: material.sizeAttenuation === true,
|
|
|
logarithmicDepthBuffer: logarithmicDepthBuffer,
|
|
logarithmicDepthBuffer: logarithmicDepthBuffer,
|