public class CGImage extends CFType
Modifier and Type | Method and Description |
---|---|
static CGImage |
createWithImageInRect(CGImage image,
CGRect rect)
Constructs and returns a CGImage using the data of specified image that
are contained within the given rectangle.
|
static CGImage |
createWithPNGDataProvider(CGDataProvider provider,
double[] decode,
boolean shouldInterpolate,
int CGColorRenderingIntent)
Constructs and returns a CGImage from the specified PNG image.
|
int |
getHeight()
Returns the height of this image in pixels.
|
int |
getWidth()
Returns the width of this image in pixels.
|
String |
toString() |
public static CGImage createWithImageInRect(CGImage image, CGRect rect)
image
- The image that is used.rect
- The rectangle that specifies which part of the image to use.public static CGImage createWithPNGDataProvider(CGDataProvider provider, double[] decode, boolean shouldInterpolate, int CGColorRenderingIntent)
provider
- The PNG image that is used for the CGImage.decode
- The decode array to use, usually null.shouldInterpolate
- WHether interpolation is desired.CGColorRenderingIntent
- The way color is handled.public int getWidth()
public int getHeight()
Copyright © 2020. All rights reserved.