
Bucket fill
bucketfill(im, x, y, z = 1, color, opacity = 1, sigma = 0,
high_connexity = FALSE)
an image
X-coordinate of the starting point of the region to fill.
Y-coordinate of the starting point of the region to fill.
Z-coordinate of the starting point of the region to fill.
Pointer to spectrum() consecutive values, defining the drawing color. If missing, use value at location (x,y,z)
Opacity of the drawing.
Tolerance concerning neighborhood values.
Use 8-connexity (only for 2d images, default FALSE).
px.flood
# NOT RUN {
#Change the colour of a sail
boats.new <- bucketfill(boats,x=169,y=179,color=c(125,0,125),sigma=20)
layout(t(1:2))
plot(boats,main="Original")
plot(boats.new,main="New sails")
# }
Run the code above in your browser using DataLab