排钻显示改成实体显示.

This commit is contained in:
ChenX
2018-05-31 21:01:30 +08:00
parent f72bb04ff5
commit fa20fa5f48
8 changed files with 26 additions and 15 deletions

View File

@@ -1,10 +1,11 @@
import * as THREE from "three";
import { Mesh } from "three";
import { CameraControls, PointPick, boardMaterial, selectMaterial } from ".";
import { CameraUpdate } from "./CameraUpdate";
import { ColorMaterial } from "./ColorPalette";
import { GetBox, GetBoxArr, cZeroVec } from "./GeUtils";
import { PlaneExt } from "./PlaneExt";
import { PointPick, boardMaterial, CameraControls, selectMaterial } from ".";
import { MeshBasicMaterial, Color, Mesh } from "three";
export class Viewer
{
@@ -38,7 +39,7 @@ export class Viewer
let mesh = PointPick(this, e.offsetX, e.offsetY);
if (oldMesh)
oldMesh.material = boardMaterial;
if (mesh)
if (mesh && mesh.material !== ColorMaterial.GetLineMaterial(1))
{
oldMesh = mesh;
mesh.material = selectMaterial;