Skip to content

Commit

Permalink
Fix #1237 markers: update opacity of imageLayer and videoLayer
Browse files Browse the repository at this point in the history
  • Loading branch information
mistic100 committed Feb 14, 2024
1 parent f382d5f commit 8377781
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion packages/markers-plugin/src/markers/Marker3D.ts
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ export class Marker3D extends Marker {
this.state.size = this.config.size;

mesh.position.set(0.5 - this.state.anchor.x, this.state.anchor.y - 0.5, 0);
mesh.rotation.set(0, 0, -this.config.rotation ?? 0);
mesh.rotation.set(0, 0, -(this.config.rotation ?? 0));
this.viewer.dataHelper.sphericalCoordsToVector3(this.state.position, group.position);

group.lookAt(0, group.position.y, 0);
Expand Down Expand Up @@ -193,6 +193,8 @@ export class Marker3D extends Marker {
video.play();

this.definition = this.config.videoLayer;
} else {
material.alpha = this.config.opacity;
}
break;

Expand Down Expand Up @@ -223,6 +225,8 @@ export class Marker3D extends Marker {
});

this.definition = this.config.imageLayer;
} else {
material.alpha = this.config.opacity;
}
break;

Expand Down

0 comments on commit 8377781

Please sign in to comment.