OpenSiv3D
OpenSiv3D copied to clipboard
SevenSegment の機能強化
-
SevenSegment::DrawChar()
が 'A', 'B', 'C', 'D', 'E', 'F' も描画できるようにする
テスト用コード
# include <Siv3D.hpp>
# include <Siv3D/Experimental/SevenSegment.hpp>
void Main()
{
while (System::Update())
{
SevenSegment::DrawText(U"-0123456789", Vec2{ 40, 40 }, 40, 4, 1, 20, ColorF{ 1, 0.5, 0 }, ColorF{ 0, 0.2, 0.2 });
SevenSegment::DrawText(U" ABCDEF", Vec2{ 40, 160 }, 40, 4, 1, 20, ColorF{ 1, 0.5, 0 }, ColorF{ 0, 0.2, 0.2 });
}
}
- 作者の @hota1024 さんに問い合わせ
- この関数の修正だけで済むはず https://github.com/Siv3D/OpenSiv3D/blob/v6_winmac_develop/Siv3D/include/Siv3D/Experimental/detail/SevenSegment.ipp#L108
-
v6_winmac_develop
ブランチへ Pull-req - 参考: https://github.com/Siv3D/OpenSiv3D/blob/v6_winmac_develop/Siv3D/include/Siv3D/Experimental/SevenSegment.hpp