mirror of https://github.com/OpenVidu/openvidu.git
openvidu-browser: bug fix (unmirror existing video if mirror = false)
parent
7f3248f628
commit
686d6699c9
|
@ -338,7 +338,10 @@ export class StreamManager implements EventDispatcher {
|
|||
}
|
||||
if (!this.remote && !this.stream.displayMyRemote()) {
|
||||
video.muted = true;
|
||||
if (this.stream.outboundStreamOpts.publisherProperties.mirror) {
|
||||
if (video.style.transform === 'rotateY(180deg)' && this.stream.outboundStreamOpts.publisherProperties.mirror) {
|
||||
// If the video was already rotated and now is set to not mirror
|
||||
this.removeMirrorVideo(video);
|
||||
} else if (this.stream.outboundStreamOpts.publisherProperties.mirror) {
|
||||
this.mirrorVideo(video);
|
||||
}
|
||||
}
|
||||
|
@ -424,4 +427,9 @@ export class StreamManager implements EventDispatcher {
|
|||
video.style.webkitTransform = 'rotateY(180deg)';
|
||||
}
|
||||
|
||||
private removeMirrorVideo(video): void {
|
||||
video.style.transform = 'unset';
|
||||
video.style.webkitTransform = 'unset';
|
||||
}
|
||||
|
||||
}
|
Loading…
Reference in New Issue