-
-
Notifications
You must be signed in to change notification settings - Fork 81
dtl::shape::MixRect (形状クラス)
Kasugaccho edited this page Aug 17, 2019
·
7 revisions
namespace dtl::shape {
template <typename T>
class MixRect;
}
※ T
は1bit以上の型
機能名 | 対応 |
---|---|
非長方形Matrix | 可能✅ |
#include <DTL.hpp>
#include <cstdint>
#include <array>
int main() {
using shape_t = std::uint_fast8_t;
std::array<std::array<shape_t, 16>, 12> matrix{ {} };
dtl::shape::MixRect<shape_t>(0, 1, 2, 3, 4, 5).draw(matrix);
dtl::console::OutputNumber<shape_t>(",").draw(matrix);
dtl::console::OutputString<shape_t>("AA", "BB", "CC", "DD", "EE", "FF").draw(matrix);
return 0;
}
3,3,4,0,3,1,2,0,5,1,5,3,2,0,0,1,
1,3,3,3,1,2,5,3,0,0,1,0,2,5,3,2,
5,4,1,5,2,2,4,1,3,3,1,2,1,4,4,1,
2,0,1,4,2,1,5,4,2,3,5,0,2,2,4,0,
1,2,3,5,2,0,2,1,3,1,2,1,2,3,5,3,
5,2,1,2,0,5,1,0,2,5,1,4,3,4,3,0,
0,5,3,4,3,3,2,0,0,0,4,3,3,2,2,4,
2,5,2,1,4,5,5,4,4,1,4,1,3,5,4,5,
5,5,0,3,3,1,0,1,3,1,4,3,2,2,4,1,
3,1,0,4,5,5,1,0,1,3,4,5,4,2,2,2,
5,5,5,2,3,1,3,3,3,4,3,3,0,3,4,5,
1,4,5,3,0,3,2,1,5,3,1,5,4,5,4,1,
DDDDEEAADDBBCCAAFFBBFFDDCCAAAABB
BBDDDDDDBBCCFFDDAAAABBAACCFFDDCC
FFEEBBFFCCCCEEBBDDDDBBCCBBEEEEBB
CCAABBEECCBBFFEECCDDFFAACCCCEEAA
BBCCDDFFCCAACCBBDDBBCCBBCCDDFFDD
FFCCBBCCAAFFBBAACCFFBBEEDDEEDDAA
AAFFDDEEDDDDCCAAAAAAEEDDDDCCCCEE
CCFFCCBBEEFFFFEEEEBBEEBBDDFFEEFF
FFFFAADDDDBBAABBDDBBEEDDCCCCEEBB
DDBBAAEEFFFFBBAABBDDEEFFEECCCCCC
FFFFFFCCDDBBDDDDDDEEDDDDAADDEEFF
BBEEFFDDAADDCCBBFFDDBBFFEEFFEEBB
なし
Copyright (c) 2018-2021 As Project.
Distributed under the Boost Software License, Version 1.0.(See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)