Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

boundary

Find the boundary of a shape in a pixel set


Description

Find the boundary of a shape in a pixel set

Usage

boundary(px, depth = 1, high_connexity = FALSE)

Arguments

px

pixel set

depth

boundary depth (default 1)

high_connexity

if FALSE, use 4-point neighbourhood. If TRUE, use 8-point. (default FALSE)

Examples

px.diamond(10,30,30) %>% boundary %>% plot
px.square(10,30,30) %>% boundary %>% plot
px.square(10,30,30) %>% boundary(depth=3) %>% plot
px <- (px.square(10,30,30) | px.circle(12,30,30))
boundary(px,high=TRUE) %>% plot(int=TRUE,main="8-point neighbourhood")
boundary(px,high=TRUE) %>% plot(int=FALSE,main="4-point neighbourhood")

imager

Image Processing Library Based on 'CImg'

v0.42.10
LGPL-3
Authors
Simon Barthelme [aut], David Tschumperle [ctb], Jan Wijffels [ctb], Haz Edine Assemlal [ctb], Shota Ochi [cre]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.