26 #ifndef MLN_MORPHO_ELEMENTARY_TOP_HAT_HH
27 # define MLN_MORPHO_ELEMENTARY_TOP_HAT_HH
35 # include <mln/morpho/elementary/opening.hh>
36 # include <mln/morpho/elementary/closing.hh>
37 # include <mln/morpho/minus.hh>
53 template <
typename I,
typename N>
55 top_hat_white(const Image<I>& input, const Neighborhood<N>& nbh);
62 template <typename I, typename N>
64 top_hat_black(const Image<I>& input, const Neighborhood<N>& nbh);
74 template <typename I, typename N>
79 # ifndef MLN_INCLUDE_ONLY
82 template <
typename I,
typename N>
87 trace::entering(
"morpho::elementary::top_hat_white");
89 mln_precondition(exact(input).is_valid());
90 mln_precondition(exact(nbh).is_valid());
97 trace::exiting(
"morpho::elementary::top_hat_white");
102 template <
typename I,
typename N>
107 trace::entering(
"morpho::elementary::top_hat_black");
109 mln_precondition(exact(input).is_valid());
110 mln_precondition(exact(nbh).is_valid());
117 trace::exiting(
"morpho::elementary::top_hat_black");
122 template <
typename I,
typename N>
127 trace::entering(
"morpho::elementary::top_hat_self_complementary");
128 mln_precondition(exact(input).is_valid());
129 mln_precondition(exact(nbh).is_valid());
137 trace::exiting(
"morpho::elementary::top_hat_self_complementary");
142 # endif // ! MLN_INCLUDE_ONLY
151 #endif // ! MLN_MORPHO_ELEMENTARY_TOP_HAT_HH