From aa1cc88de27980764647a829a8a8261aee4aa873 Mon Sep 17 00:00:00 2001
From: luxiaotao1123 <t1341870251@63.com>
Date: 星期三, 06 四月 2022 17:05:34 +0800
Subject: [PATCH] #
---
static/js/object/StoreShelf.js | 14 +++++++++-----
1 files changed, 9 insertions(+), 5 deletions(-)
diff --git a/static/js/object/StoreShelf.js b/static/js/object/StoreShelf.js
index fcf42b0..b1761e0 100644
--- a/static/js/object/StoreShelf.js
+++ b/static/js/object/StoreShelf.js
@@ -13,15 +13,16 @@
this.positionZ = option.position.z||0;//搴撲綅浣嶇疆
this.rackLengh = 3;//鏀灦鐨勯暱搴︼紝榛樿璁惧姩涓�3
this.rackWidth = 3;//鏀灦鐨勫搴︼紝榛樿璁惧畾涓�3
+ this.mesh = null;
// 鏉愯川
- let shelfMat = new THREE.MeshLambertMaterial({
+ let shelfMat = new THREE.MeshPhysicalMaterial({
color: 0x175EC0,
- transparent: true,
- opacity: 0.6
+ transparent: false,
+ opacity: 0.7
});
//瀹氫箟涓�涓粍鍚堜綋
- let group = new THREE.Group();
+ // let group = new THREE.Group();
// 璐ф灦鎬婚珮
let shelfHeight=this.bottomHight+(this.binYNum)*this.binHeight;
@@ -92,7 +93,10 @@
}
let mergedGeometry = BufferGeometryUtils.mergeBufferGeometries(geometries);
- return new THREE.Mesh(mergedGeometry, shelfMat);
+ let mesh = new THREE.Mesh(mergedGeometry, shelfMat);
+ mesh.castShadow = true;
+ this.mesh = mesh;
+ return this;
}
export {StoreShelf}
--
Gitblit v1.9.1