SamuelScheit / puppeteer-stream

A Library for puppeteer to retrieve audio and/or video streams
MIT License
358 stars 114 forks source link

Can 'highWaterMark' support configuration #111

Closed dingqiaolin closed 1 year ago

dingqiaolin commented 1 year ago

image The pages I record sometimes lose frames, and I suspect that the 'highWaterMark' configuration is too small. Can this parameter be released to support configuration?

nivhsay commented 1 year ago

I experience the same at times. Did it help when you increased it?

dingqiaolin commented 1 year ago

I tried it, but it didn't have much effect. I need to see if it's affected by other factors

dingqiaolin commented 1 year ago

image I found that there is a problem with sending data through udp. Changing udp to a method of registering and sending data would be much more stable.

SamuelScheit commented 1 year ago

Yes we need to change the data transmission method, what do you suggest to use instead?

nivhsay commented 1 year ago

I recently patched the module on my setup to use tcp and it's working well.

I think it depends on the use-case.

When reliability is needed, the browser extension should switch to TCP instead.

SamuelScheit commented 1 year ago

Awesome @nivhsay can you create a PR?