26 #ifndef MLN_WIN_OCTAGON2D_HH
27 # define MLN_WIN_OCTAGON2D_HH
33 # include <mln/core/internal/classical_window_base.hh>
34 # include <mln/core/alias/dpoint2d.hh>
88 unsigned area()
const;
90 void print_(std::ostream& ostr)
const;
98 # ifndef MLN_INCLUDE_ONLY
104 mln_precondition(length % 6 == 1);
107 x = static_cast<def::coord>(y * 2),
115 _b = static_cast<def::coord>(-b);
126 b_max = static_cast<def::coord>(2 * x - a);
131 _b = static_cast<def::coord>(-b);
159 unsigned l = (
length_ - 1) / 6;
160 return l * (28 * l + 8) + 4;
166 ostr <<
"[octagon2d: length=" <<
length_ <<
']';
169 # endif // ! MLN_INCLUDE_ONLY
178 # include <mln/win/hline2d.hh>
179 # include <mln/win/vline2d.hh>
180 # include <mln/win/diag2d.hh>
181 # include <mln/win/backdiag2d.hh>
183 #endif // ! MLN_WIN_OCTAGON2D_HH