26 #ifndef MLN_MORPHO_ELEMENTARY_DILATION_HH
27 # define MLN_MORPHO_ELEMENTARY_DILATION_HH
31 # include <mln/morpho/elementary/like_ero_fun.hh>
32 # include <mln/morpho/elementary/like_ero_set.hh>
45 template <
typename I,
typename N>
47 dilation(const Image<I>& input, const Neighborhood<N>&
nbh);
50 # ifndef MLN_INCLUDE_ONLY
57 template <
typename I,
typename N>
59 dilation_dispatch(trait::image::kind::any,
60 const Image<I>& input, const Neighborhood<N>& nbh)
65 template <
typename I,
typename N>
67 dilation_dispatch(trait::image::kind::logic,
68 const Image<I>& input, const Neighborhood<N>& nbh)
81 template <
typename I,
typename N>
83 dilation_dispatch(const Image<I>& input, const Neighborhood<N>& nbh)
85 return dilation_dispatch(mln_trait_image_kind(I)(),
94 template <
typename I,
typename N>
96 dilation(const Image<I>& input, const Neighborhood<N>& nbh)
98 mln_trace(
"morpho::elementary::dilation");
100 mln_precondition(
exact(input).is_valid());
101 mln_precondition(
exact(nbh).is_valid());
103 mln_concrete(I) output = internal::dilation_dispatch(input, nbh);
105 mln_postcondition(output >= input);
109 # endif // ! MLN_INCLUDE_ONLY
118 #endif // ! MLN_MORPHO_ELEMENTARY_DILATION_HH