Draw circle on image
Add circle or circles to an image. Like other native CImg drawing functions, this is meant to be basic but fast. Use implot for flexible drawing.
draw_circle(im, x, y, radius, color = "white", opacity = 1, filled = TRUE)
im |
an image |
x |
x coordinates |
y |
y coordinates |
radius |
radius (either a single value or a vector of length equal to length(x)) |
color |
either a string ("red"), a character vector of length equal to x, or a matrix of dimension length(x) times spectrum(im) |
opacity |
scalar or vector of length equal to length(x). 0: transparent 1: opaque. |
filled |
fill circle (default TRUE) |
an image
Simon Barthelme
implot
draw_circle(boats,c(50,100),c(150,200),30,"darkgreen") %>% plot draw_circle(boats,125,60,radius=30,col=c(0,1,0),opacity=.2,filled=TRUE) %>% plot
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.