Traces the boundary of an object in a binary mask using Moore-Neighbor chain code algorithm. Outline starts at rightmost point and traces counter-clockwise (positive/mathematical direction).
Examples
if (FALSE) { # \dontrun{
# From mask matrix
mask <- img_mask("leaf.png")
outline <- trace_outline(mask)
} # }
