| | |
| | | import {OrbitControls} from './lib/OrbitControls.js'; |
| | | import { PointerLockControls } from './lib/PointerLockControls.js'; |
| | | import Stats from './lib/stats.module.js'; |
| | | import { OutlinePass } from './lib/OutlinePass.js'; |
| | | import { EffectComposer } from './lib/EffectComposer.js'; |
| | | import { RenderPass } from './lib/postprocessing/RenderPass.js'; |
| | | import { ShaderPass } from './lib/postprocessing/ShaderPass.js'; |
| | | import { OutlinePass } from './lib/postprocessing/OutlinePass.js'; |
| | | import {MTLLoader} from './lib/MTLLoader.js'; |
| | | import {OBJLoader} from './lib/OBJLoader.js'; |
| | | import {StoreShelf} from './object/StoreShelf.js'; |
| | |
| | | this.initLight(); |
| | | this.initReSize(this); |
| | | this.initOutLine(); |
| | | this.initComposer(); |
| | | this.initObjectSelect(); |
| | | this.initPointLockControl(this); |
| | | this.initFloor(); |
| | |
| | | this.outlinePass.visibleEdgeColor.set('#B31985');//包围线颜色 |
| | | this.outlinePass.hiddenEdgeColor.set('#190a05');//被遮挡的边界线颜色 |
| | | } |
| | | this.initComposer = function(){ |
| | | this.composer = new EffectComposer(this.renderer); |
| | | const renderPass = new RenderPass( this.scene, this.camera ); |
| | | this.composer.addPass( renderPass ); |
| | | this.composer.addPass(this.outlinePass); |
| | | } |
| | | this.initObjectSelect = function(){ |
| | | new ObjectSelect(this.scene, this.camera, this.outlinePass); |
| | | } |