提交 7102ec54 编写于 作者: M Mr.doob 提交者: GitHub

Merge pull request #11982 from dhritzkiv/patch-18

reference `FlatShading` directly; Use comparison result directly
......@@ -5,7 +5,7 @@
import { Audio } from './audio/Audio.js';
import { AudioAnalyser } from './audio/AudioAnalyser.js';
import { PerspectiveCamera } from './cameras/PerspectiveCamera.js';
import { CullFaceFront, CullFaceBack } from './constants.js';
import { CullFaceFront, CullFaceBack, FlatShading } from './constants.js';
import {
Float64BufferAttribute,
Float32BufferAttribute,
......@@ -1047,7 +1047,7 @@ Object.defineProperties( Material.prototype, {
set: function ( value ) {
console.warn( 'THREE.' + this.type + ': .shading has been removed. Use the boolean .flatShading instead.' );
this.flatShading = ( value === THREE.FlatShading ) ? true : false;
this.flatShading = ( value === FlatShading );
}
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册