drawRotatedRectangle
draws rotated rectangles over an
Image
object. This operation is destructive: it changes
irreversibly the Image
object and cannot be undone.
Arguments
- image
An
Image
object.- x
A numeric value or vector representing the x coordinates of the center of each rectangle.
- y
A numeric value or vector representing the y coordinates of the center of each rectangle.
- axis1
A numeric value or vector representing the length of the first axis of each rectangle.
- axis2
A numeric value or vector representing the length of the second axis of each rectangle.
- angle
A numeric value or vector representing the angle in degrees between
axis1
and the horizontal.- color
A value or vector of any kind of R color specification compatible with
col2bgr
representing the color of each rectangle's outline (default: "red").- thickness
A numeric value or vector representing the thickness in pixels of each rectangle's outline (default: 1). If negative, then a filled rectangle is drawn.
Author
Simon Garnier, garnier@njit.edu
Examples
balloon <- image(system.file("sample_img/balloon1.png", package = "Rvision"))
drawRotatedRectangle(balloon, 290, 170, 440, 325, 60, thickness = 3)
#> NULL