-
-
Notifications
You must be signed in to change notification settings - Fork 82
dtl::retouch::Average (修正クラス)
Kasugaccho edited this page Aug 17, 2019
·
2 revisions
namespace dtl::retouch {
template <typename T>
class Average;
}
※ 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, 7>, 7> matrix{ {} };
dtl::shape::SimplePyramid<shape_t>(99, 10).draw(matrix);
dtl::console::OutputNumber<shape_t>(",").draw(matrix);
dtl::console::OutputStringBool<shape_t>("##", "//").drawOperator(matrix, [](const shape_t value) {return value > 50; });
dtl::retouch::Average<shape_t>().draw(matrix);
dtl::console::OutputNumber<shape_t>(",").draw(matrix);
dtl::console::OutputStringBool<shape_t>("##", "//").drawOperator(matrix, [](const shape_t value) {return value > 50; });
return 0;
}
10,10,10,10,10,10,10,
10,39,39,39,39,39,10,
10,39,69,69,69,39,10,
10,39,69,99,69,39,10,
10,39,69,69,69,39,10,
10,39,39,39,39,39,10,
10,10,10,10,10,10,10,
//////////////
//////////////
////######////
////######////
////######////
//////////////
//////////////
30,30,30,30,30,30,30,
30,30,30,30,30,30,30,
30,30,30,30,30,30,30,
30,30,30,30,30,30,30,
30,30,30,30,30,30,30,
30,30,30,30,30,30,30,
30,30,30,30,30,30,30,
//////////////
//////////////
//////////////
//////////////
//////////////
//////////////
//////////////
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)