KASM-5720 - Fix artifacts on secondary screens with high resolution (#104)
* increase buffer size, track drops, change pop to shift * match rect limit elsewhere --------- Co-authored-by: mattmcclaskey <matt@kasmweb.com>
This commit is contained in:
parent
bf7a417ab7
commit
bbc685aa0f
|
@ -910,8 +910,9 @@ export default class Display {
|
||||||
this._syncFrameQueue.push(rect);
|
this._syncFrameQueue.push(rect);
|
||||||
|
|
||||||
//if the secondary display is not in focus, the browser may not call requestAnimationFrame, thus we need to limit our buffer
|
//if the secondary display is not in focus, the browser may not call requestAnimationFrame, thus we need to limit our buffer
|
||||||
if (this._syncFrameQueue.length > 500) {
|
if (this._syncFrameQueue.length > 5000) {
|
||||||
this._syncFrameQueue.pop();
|
this._syncFrameQueue.shift();
|
||||||
|
this._droppedRects++;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case 'frameComplete':
|
case 'frameComplete':
|
||||||
|
@ -953,7 +954,7 @@ export default class Display {
|
||||||
if (a.img.complete) {
|
if (a.img.complete) {
|
||||||
this.drawImage(a.img, pos.x, pos.y, a.width, a.height);
|
this.drawImage(a.img, pos.x, pos.y, a.width, a.height);
|
||||||
} else {
|
} else {
|
||||||
if (this._syncFrameQueue.length > 1000) {
|
if (this._syncFrameQueue.length > 5000) {
|
||||||
this._syncFrameQueue.shift();
|
this._syncFrameQueue.shift();
|
||||||
this._droppedRects++;
|
this._droppedRects++;
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in New Issue