public class ImageFrame extends Object
Constructor and Description |
---|
ImageFrame(ImageStorage.ImageType imageType,
ByteBuffer imageData,
int width,
int height,
int stride,
byte[][] palette,
float pixelScale,
ImageMetadata metadata)
Create an
ImageFrame . |
ImageFrame(ImageStorage.ImageType imageType,
ByteBuffer imageData,
int width,
int height,
int stride,
byte[][] palette,
ImageMetadata metadata)
Create an
ImageFrame with a default 72DPI pixel scale. |
Modifier and Type | Method and Description |
---|---|
int |
getHeight() |
Buffer |
getImageData() |
ImageStorage.ImageType |
getImageType() |
ImageMetadata |
getMetadata() |
byte[][] |
getPalette() |
float |
getPixelScale() |
int |
getStride() |
int |
getWidth() |
void |
setPixelScale(float pixelScale) |
public ImageFrame(ImageStorage.ImageType imageType, ByteBuffer imageData, int width, int height, int stride, byte[][] palette, ImageMetadata metadata)
ImageFrame
with a default 72DPI pixel scale.imageType
- The type of image data. The value of this field also
implies the number of bands.imageData
- The image data.width
- The image width.height
- The image height.stride
- The stride from a pixel position in one row to the same
horizontal position in the next row.palette
- The image palette. This is ignored unless the type is
one of the palette types.metadata
- The image metadata.public ImageFrame(ImageStorage.ImageType imageType, ByteBuffer imageData, int width, int height, int stride, byte[][] palette, float pixelScale, ImageMetadata metadata)
ImageFrame
.imageType
- The type of image data. The value of this field also
implies the number of bands.imageData
- The image data.width
- The image width.height
- The image height.stride
- The stride from a pixel position in one row to the same
horizontal position in the next row.palette
- The image palette. This is ignored unless the type is
one of the palette types.pixelScale
- The scale of a 72DPI virtual pixel in the resolution
of the image (1.0f for 72DPI images, 2.0f for 144DPI images, etc.).metadata
- The image metadata.public ImageStorage.ImageType getImageType()
public Buffer getImageData()
public int getWidth()
public int getHeight()
public int getStride()
public byte[][] getPalette()
public void setPixelScale(float pixelScale)
public float getPixelScale()
public ImageMetadata getMetadata()
Copyright © 2020. All rights reserved.