PictureImage-class {grImport2} | R Documentation |
Class "PictureImage"
Description
A description of a raster image.
Slots
x
:-
Object of class
"numeric"
. A vector of length one representing the x-location of the top-left corner of the image. y
:-
Object of class
"numeric"
. A vector of length one representing the y-location of the top-left corner of the image. width
:-
Object of class
"numeric"
. A vector of length one representing the width of the image. height
:-
Object of class
"numeric"
. A vector of length one representing the height of the image. image
:-
Object of class
"nativeRaster"
. A description of the raster image as an array of integers representing pixel colours. Not intended to be created directly, but as a result of calling thejpeg
andpng
packagesread*()
functions. angle
:-
Object of class
"numeric"
. A vector of length one representing the angle applied to the image. Corresponds to grid's viewport angles. maskRef
:-
Object of class
"ANY"
. A character reference to an object that will mask this image. Not intended to be used directly (so can beNULL
. bbox
:-
Object of class
"numeric"
. Represented as[xmin, xmax, ymin, ymax]
. The bounding box of the image. Used for features such as clipping.
Extends
Class PictureContent
, directly.
Methods
- applyTransform
-
signature(object = "PictureImage", tm = "matrix")
: transforms each location described by the image by a 3x3 transformation matrix and returns a new"PictureImage"
object with the newly transformed locations. - grobify
-
signature(object = "PictureImage")
: converts the image description into a grid raster grob that represents the image. Typically used in conjunction with a pattern.While not intended to be used directly, this function contains a single optional argument,
ext
, which is a character vector. Seegrid.picture
for more information on what this extension selection parameter means, in addition to the valid values this argument takes.
Author(s)
Simon Potter