修复双面编号问题

This commit is contained in:
xief 2023-07-18 09:19:03 +08:00
parent 27dd548309
commit e5b944539e
2 changed files with 3 additions and 3 deletions

View File

@ -1,5 +1,5 @@
import * as THREE from 'three'; import * as THREE from 'three';
import { LineBasicMaterial, MeshBasicMaterial, Color } from 'three'; import { Color, LineBasicMaterial, MeshBasicMaterial } from 'three';
const ColorPalette = [ const ColorPalette = [
[255, 0, 0, 255], //----- 0 - lets make it red for an example [255, 0, 0, 255], //----- 0 - lets make it red for an example
//[255, 255, 255, 255],//----- 0 - ByBlock - White //[255, 255, 255, 255],//----- 0 - ByBlock - White
@ -284,7 +284,7 @@ export class ColorMaterial
{ {
if (this.m_BasicMaterialMap.has(index)) if (this.m_BasicMaterialMap.has(index))
return this.m_BasicMaterialMap.get(index); return this.m_BasicMaterialMap.get(index);
let mat = new MeshBasicMaterial({ color: this.GetColor(index) }); let mat = new MeshBasicMaterial({ color: this.GetColor(index), side: THREE.DoubleSide });
this.m_BasicMaterialMap.set(index, mat); this.m_BasicMaterialMap.set(index, mat);
return mat; return mat;
} }

View File

@ -178,7 +178,7 @@ export class SimpleBoard
text.applyMatrix4(new Matrix4().setPosition(position)); text.applyMatrix4(new Matrix4().setPosition(position));
} }
text.CreateDoubleMesh(this._BoardType === BoardType.Layer); // text.CreateDoubleMesh(this._BoardType === BoardType.Layer);
return text; return text;
} }