Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

enhance(backend): blurhash生成時、リサイズしてからRawに変換するように #15155

Conversation

kakkokari-gtyih
Copy link
Contributor

What

書いてあるとおり

Why

軽くなるかもしれない?

Additional info (optional)

Checklist

  • Read the contribution guide
  • Test working in a local environment
  • (If needed) Add story of storybook
  • (If needed) Update CHANGELOG.md
  • (If possible) Add tests

@github-actions github-actions bot added the packages/backend Server side specific issue/PR label Dec 19, 2024
Copy link
Contributor

github-actions bot commented Dec 19, 2024

このPRによるapi.jsonの差分
差分はありません。
Get diff files from Workflow Page

Copy link

codecov bot commented Dec 19, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 40.32%. Comparing base (13439e0) to head (7e0c19d).

Additional details and impacted files
@@           Coverage Diff            @@
##           develop   #15155   +/-   ##
========================================
  Coverage    40.31%   40.32%           
========================================
  Files         1564     1564           
  Lines       198083   198083           
  Branches      3837     3842    +5     
========================================
+ Hits         79863    79872    +9     
- Misses      117617   117640   +23     
+ Partials       603      571   -32     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@samunohito
Copy link
Member

misskey-dev/sharp-read-bmpsharpの初期化を行っているだけのようなので、sharpのソースを見に行きました。

https://github.com/lovell/sharp/blob/main/lib/channel.js#L61-L72
https://github.com/lovell/sharp/blob/main/lib/resize.js#L254
https://github.com/lovell/sharp/blob/main/lib/output.js#L1207-L1220
https://github.com/lovell/sharp/blob/main/lib/output.js#L156-L165

上記を見る限り、builderのような感じになっていて自身が持っているoptionsを書き換えているだけのようです。
なので、toBufferより前のメソッドの呼び出し順序を変えても効果は見込めないかと考えます。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
packages/backend Server side specific issue/PR
Projects
Development

Successfully merging this pull request may close these issues.

3 participants