diffusionstudio / core

The Video Creation Engine: Edit videos with code, featuring the fastest WebCodecs renderer for in-browser video processing.
https://examples.diffusion.studio/
Mozilla Public License 2.0
336 stars 25 forks source link

The video is laggy on Linux. #18

Open thanhnhahuynh1509 opened 1 month ago

thanhnhahuynh1509 commented 1 month ago

Hi, I'm using your library for my project, and it's fantastic! It works well on Mac, but on Linux (Chrome), it seems to be laggy.

I've tested with another library, like etro-js, and the video doesn't seem to lag.

Here is a recording of my video. I compared the diffusion-core canvas player with the etro-js canvas player on Chrome for Linux. https://drive.google.com/file/d/1meLRmNlQudg82W4sRChOvCXQGmTrfaih/view?usp=sharing

And here are all the supported features in my Linux browser. image

Thank you very much.

k9p5 commented 1 month ago

We are using pixijs' video implementation in the background, which apparently is not as performant as an implementation using the HTMLVideoElement and a 2D context. There's not really much we can do about it at the moment. In the long run, we will provide our own video implementation based on the VideoDecoder and get rid of the HTMLVideoElement.