Siv3D / OpenSiv3D

C++20 framework for creative coding 🎮🎨🎹 / Cross-platform support (Windows, macOS, Linux, and the Web)
https://siv3d.github.io/
MIT License
1k stars 138 forks source link

RoundRect::drawShadow(), blur が大きいときの描画の乱れを修正 #1164

Closed Reputeless closed 8 months ago

Reputeless commented 9 months ago
# include <Siv3D.hpp> // Siv3D v0.6.13

void Main()
{
    Scene::SetBackground(ColorF{ 1.0 });

    while (System::Update())
    {
        {
            const RoundRect roundRect{ 50, 100, 300, 100, 5 };
            roundRect.rect.drawShadow(Vec2{ 0, 0 }, 5);
        }

        {
            const RoundRect roundRect{ 400, 100, 300, 100, 5 };
            roundRect.drawShadow(Vec2{ 0, 0 }, 20);
        }
    }
}
image