gives the fixed point of the geodesic dilation of the marker constrained by the mask.

Details and Options

  • GeodesicDilation works with binary, grayscale, and multichannel images, operating on each channel separately.
  • GeodesicDilation works with 3D as well as 2D images, and also with data arrays of any rank.
  • GeodesicDilation[marker,mask] effectively starts with marker then repeatedly dilates it, masking with mask until the result no longer changes. For symbolic data, the geodesic dilation is done only once.
  • GeodesicDilation[marker,mask,n] iterates the dilation process at most n times.
  • GeodesicDilation effectively performs a morphological reconstruction by dilation.
  • The following options can be given:
  • CornerNeighborsTruewhether to include corner neighbors
    PaddingNonepadding method to use
  • The default setting Padding->None considers smaller neighborhoods at the edges of an image.


open allclose all

Basic Examples  (2)

Reconstruct the marked foreground objects:

Reconstruct the marked foreground objects in a 3D image:

Scope  (1)

Geodesic dilation of a vector:

Interactive Examples  (1)

Iteratively apply geodesic dilation:

Wolfram Research (2008), GeodesicDilation, Wolfram Language function, (updated 2012).


Wolfram Research (2008), GeodesicDilation, Wolfram Language function, (updated 2012).


Wolfram Language. 2008. "GeodesicDilation." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2012.


Wolfram Language. (2008). GeodesicDilation. Wolfram Language & System Documentation Center. Retrieved from


@misc{reference.wolfram_2024_geodesicdilation, author="Wolfram Research", title="{GeodesicDilation}", year="2012", howpublished="\url{}", note=[Accessed: 23-June-2024 ]}


@online{reference.wolfram_2024_geodesicdilation, organization={Wolfram Research}, title={GeodesicDilation}, year={2012}, url={}, note=[Accessed: 23-June-2024 ]}