Performance improvement: dispatch audiolevel-events only on step changes 1-10
parent
417f7ec3e8
commit
bbb3095577
|
|
@ -797,7 +797,7 @@ export default class RoomClient
|
||||||
|
|
||||||
if (volume === 1)
|
if (volume === 1)
|
||||||
volume = 0;
|
volume = 0;
|
||||||
|
volume = Math.round(volume);
|
||||||
if (volume !== this._micProducer.volume)
|
if (volume !== this._micProducer.volume)
|
||||||
{
|
{
|
||||||
this._micProducer.volume = volume;
|
this._micProducer.volume = volume;
|
||||||
|
|
@ -1503,7 +1503,7 @@ export default class RoomClient
|
||||||
|
|
||||||
if (volume === 1)
|
if (volume === 1)
|
||||||
volume = 0;
|
volume = 0;
|
||||||
|
volume = Math.round(volume);
|
||||||
if (volume !== producer.volume)
|
if (volume !== producer.volume)
|
||||||
{
|
{
|
||||||
producer.volume = volume;
|
producer.volume = volume;
|
||||||
|
|
@ -1939,7 +1939,7 @@ export default class RoomClient
|
||||||
|
|
||||||
if (volume === 1)
|
if (volume === 1)
|
||||||
volume = 0;
|
volume = 0;
|
||||||
|
volume = Math.round(volume);
|
||||||
if (volume !== consumer.volume)
|
if (volume !== consumer.volume)
|
||||||
{
|
{
|
||||||
consumer.volume = volume;
|
consumer.volume = volume;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue