virtual-background icon indicating copy to clipboard operation
virtual-background copied to clipboard

Huge memory consumption (meet+WebGL2)

Open jibon57 opened this issue 2 years ago • 1 comments

First of all thanks for excellent solution. I was checking the demo site as well my implementation in Plug-N-Meet. If I choose meet + WebGL2 in Firefox it use huge memory. If I continue using like almost 20~25 minutes, it used up 12GB+ of RAM & browser got crashed. With meet + Canvas 2D + CPU doesn't have this problem. Is this normal or is there any memory leaks somewhere?

jibon57 avatar May 08 '22 08:05 jibon57

I guess the root cause is from https://github.com/Volcomix/virtual-background/blob/2adb3a95bcee4c42509c31ef1ecbb967ad9aa27f/src/pipelines/webgl2/webgl2Pipeline.ts#L164. I tried using ImageData instead of HTMLVideoElement, the problem did not occur but the quality is worse. I don't know if we have other solution to make sure this problem doesn't happen and keep good quality?

HauHuu060988 avatar Sep 20 '22 03:09 HauHuu060988