romm icon indicating copy to clipboard operation
romm copied to clipboard

misc: Optimized covers storing them as webp format

Open zurdi15 opened this issue 7 months ago • 4 comments

Description Now any kind of new artowrk (uploaded or fetched) will be converted to .webp format to improve performance

Checklist Please check all that apply.

  • [x] I've tested the changes locally
  • [x] I've updated relevant comments
  • [x] I've assigned reviewers for this PR

zurdi15 avatar May 29 '25 11:05 zurdi15

Running Code Quality on PRs by uploading data to Trunk will soon be removed. You can still run checks on your PRs using trunk-action - see the migration guide for more information.

trunk-io[bot] avatar May 29 '25 11:05 trunk-io[bot]

Test Results

93 tests  ±0   92 ✅ ±0   29s ⏱️ -1s  1 suites ±0    0 💤 ±0   1 files   ±0    1 ❌ ±0 

For more details on these failures, see this check.

Results for commit 2f683138. ± Comparison against base commit cf575cc9.

:recycle: This comment has been updated with latest results.

github-actions[bot] avatar May 29 '25 11:05 github-actions[bot]

what kind of "performance" are you seeking by switching to webp, loading times in the browser or smaller file sizes?

gantoine avatar May 29 '25 16:05 gantoine

what kind of "performance" are you seeking by switching to webp, loading times in the browser or smaller file sizes?

I want to reduce the load on large libraries both in network loading times since files are smaller but also increase performance in the interactivity. I am still testing but seems like browsers handle better webp and it feels smoother than with png.

We will also need to build some kind of virtual DOM/virtual scrolling for large collections also in order to REALLY improve performance in large libraries, but that's for another PR

zurdi15 avatar May 29 '25 16:05 zurdi15

Thinking about this more it's likely webp images won't be supported on muos or playnite, for when we decide to fetch cover art for this plugins. Going to close this PR given that case, and I'm sure there are other image perf changes we can make in the future.

gantoine avatar Aug 02 '25 14:08 gantoine