solid_blobs: Find solid color connected areas in the image

Description Usage Arguments Details Value

View source: R/shapes.R

Description

Turns the image object into a logical image (pixset) of blobs of pixels of the same color

Usage

1
2
solid_blobs(img, stencil = NULL, cr_n = max(min(dim(img)[1:2])%/%100, 5),
  ...)

Arguments

img

- the cimg imager object

stencil

- a stencil dataframe which defines the neighbourhood we use. Must have a dx and dy columns, like for the imager package

cr_n

- if set, the stencil becomes a "n x n" cross (+) neighbourhood, centered at current pixel. Should be an odd number.

...

- unused arguments

Details

Each pixel maps to TRUE if every pixel in the stencil neighbourhood is the same color, otherwise it becomes FALSE.

Some erosion will happen because of the square neighbourhood

Value

A pixset where every pixel is TRUE if the neighbourhood is of the same color as the pixel


Blaza/ssoftveR documentation built on May 6, 2019, 11:19 a.m.