mirror of
https://github.com/thorvg/thorvg.git
synced 2025-06-08 13:43:43 +00:00
web: Improve the performance.
Compared the FPS with ThorVG viewer at 1664x1664 resolution. This minor tweak improves the performance by 2 to 5 FPS.
This commit is contained in:
parent
24cdbc7369
commit
7e721e8ba7
1 changed files with 1 additions and 1 deletions
|
@ -360,7 +360,7 @@ export class LottiePlayer extends LitElement {
|
|||
}
|
||||
|
||||
const buffer = this._TVG.render();
|
||||
const clampedBuffer = Uint8ClampedArray.from(buffer);
|
||||
const clampedBuffer = new Uint8ClampedArray(buffer.buffer, buffer.byteOffset, buffer.byteLength);
|
||||
if (clampedBuffer.length < 1) {
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue