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

Image::rotate90() と関連するメンバ関数の性能を改善 #1225

Merged
merged 1 commit into from
May 1, 2024

Conversation

Raclamusi
Copy link
Member

#1182 の実装の pull request です。

アクセス順の工夫(ブロック化)によるキャッシュの効率的な利用、および正方形画像に対する in-place 実装により、 Image::rotate90()Image::rotated90()Image::rotate270()Image::rotated270() の実行時性能を改善しました。

@Raclamusi
Copy link
Member Author

ブロックサイズが最適かどうかは、しっかり調べていません。
手元の環境で 4, 8, 16 辺りを試したところ、 8 がよさそうでした。

@Reputeless
Copy link
Member

v0.8 に組み込んでテストしたところ、Windows 版は 8, macOS (Apple Silicon) M2 は 16 が良さそうでした。
v0.6 へは 8 で導入しましょう。このまま進めて OK です!

v0.8 への移植時には、マクロで 8 / 16 切り替えるようにしておきます。

@Raclamusi Raclamusi marked this pull request as ready for review April 25, 2024 15:54
@Raclamusi
Copy link
Member Author

調査ありがとうございます!
よろしくお願いします。

@Reputeless Reputeless merged commit 3727bee into Siv3D:v6_develop May 1, 2024
2 checks passed
@Reputeless
Copy link
Member

Merged. Great work!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

2 participants