three-cad-viewer 2.2.0 → 2.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/three-cad-viewer.js
CHANGED
|
@@ -58527,7 +58527,7 @@ void main() {
|
|
|
58527
58527
|
: this.alpha;
|
|
58528
58528
|
}
|
|
58529
58529
|
for (var child of this.children) {
|
|
58530
|
-
if (!child.name.startsWith("clipping")){
|
|
58530
|
+
if (!child.name.startsWith("clipping")) {
|
|
58531
58531
|
// turn depth write off for transparent objects
|
|
58532
58532
|
child.material.depthWrite = this.alpha < 1.0 ? false : !flag;
|
|
58533
58533
|
// but keep depth test
|
|
@@ -58566,6 +58566,12 @@ void main() {
|
|
|
58566
58566
|
|
|
58567
58567
|
setShapeVisible(flag) {
|
|
58568
58568
|
this.types.front.material.visible = flag;
|
|
58569
|
+
for (var t of ["clipping-0", "clipping-1", "clipping-2"]) {
|
|
58570
|
+
if (this.types[t]) {
|
|
58571
|
+
this.types[t].children[0].material.visible = flag;
|
|
58572
|
+
this.types[t].children[1].material.visible = flag;
|
|
58573
|
+
}
|
|
58574
|
+
}
|
|
58569
58575
|
if (this.types.back && this.renderback) {
|
|
58570
58576
|
this.types.back.material.visible = flag;
|
|
58571
58577
|
}
|
|
@@ -58908,9 +58914,7 @@ void main() {
|
|
|
58908
58914
|
const backColor =
|
|
58909
58915
|
group.subtype === "solid"
|
|
58910
58916
|
? color
|
|
58911
|
-
: new Color(
|
|
58912
|
-
Math.round(Math.min(0xffffff, this.edgeColor * 1.25)),
|
|
58913
|
-
);
|
|
58917
|
+
: new Color(this.edgeColor).lerp(new Color(1, 1, 1), 0.15);
|
|
58914
58918
|
|
|
58915
58919
|
const backMaterial = new MeshBasicMaterial({
|
|
58916
58920
|
color: backColor,
|
|
@@ -62862,7 +62866,7 @@ void main() {
|
|
|
62862
62866
|
}
|
|
62863
62867
|
}
|
|
62864
62868
|
|
|
62865
|
-
const version = "2.2.
|
|
62869
|
+
const version = "2.2.1";
|
|
62866
62870
|
|
|
62867
62871
|
class Viewer {
|
|
62868
62872
|
/**
|