
Last chance! 50% off unlimited learning
Sale ends in
Image
drawEllipse
draws ellipses (or part of) over an
Image
object. This operation is destructive: it changes
irreversibly the Image
object and cannot be undone.
drawEllipse(
image,
x,
y,
axis1,
axis2,
angle,
start_angle = 0,
end_angle = 360,
color = "red",
thickness = 1
)
An Image
object.
A numeric value or vector representing the x coordinates of the centers of each ellipse
A numeric value or vector representing the y coordinates of the centers of each ellipse
A numeric value or vector representing the half-length of the first axis of each ellipse.
A numeric value or vector representing the half-length of the second axis of each ellipse.
A numeric value or vector representing the angle in degrees
between axis1
and the horizontal.
A numeric value or vector representing the start angle in degrees of each elliptic arc (default: 0).
A numeric value or vector representing the end angle in degrees of each elliptic arc (default: 360).
A value or vector of any kind of R color specification compatible
with col2bgr
representing the color of each ellipse's outline
(default: "red").
A numeric value or vector representing the thickness in pixels of each ellipse's outline (default: 1). If negative, then a filled ellipse is drawn.
This function does not return anything. It modifies image
in
place.
# NOT RUN {
balloon <- image(system.file("sample_img/balloon1.png", package = "Rvision"))
drawEllipse(balloon, 365, 245, 120, 90, angle = 45, thickness = 3)
# }
Run the code above in your browser using DataLab