public class HDRImage extends ImageMap
PREVIEW_HEIGHT, PREVIEW_WIDTH
Constructor and Description |
---|
HDRImage(byte[] r,
byte[] g,
byte[] b,
byte[] e,
int xres,
int yres)
Create an HDRImage from the r, g, b, and e components.
|
HDRImage(java.io.DataInputStream in)
Reconstruct an image from its serialized representation.
|
Modifier and Type | Method and Description |
---|---|
float |
getAverageComponent(int component)
Get the average value for a particular component, over the entire image.
|
void |
getColor(RGBColor theColor,
boolean wrapx,
boolean wrapy,
double x,
double y,
double xsize,
double ysize)
Get the color at a particular location.
|
float |
getComponent(int component,
boolean wrapx,
boolean wrapy,
double x,
double y,
double xsize,
double ysize)
Get the value of a single component at a particular location in the image.
|
int |
getComponentCount()
Get the number of components in the image.
|
void |
getGradient(Vec2 grad,
int component,
boolean wrapx,
boolean wrapy,
double x,
double y,
double xsize,
double ysize)
Get the gradient of a single component at a particular location in the image.
|
int |
getHeight()
Get the height of the image.
|
ImageData |
getImageData()
Get the
ImageData of this image.Plaease note that this image data is no longer a High Dynamic Range image, as it is scaled down to 24 bits! |
java.awt.Image |
getPreview()
Get a scaled down copy of the image, to use for previews.
|
int |
getWidth()
Get the width of the image.
|
void |
writeToStream(java.io.DataOutputStream out)
Serialize an image to an output stream.
|
public HDRImage(byte[] r, byte[] g, byte[] b, byte[] e, int xres, int yres)
public HDRImage(java.io.DataInputStream in) throws java.io.IOException, java.io.InvalidObjectException
java.io.IOException
java.io.InvalidObjectException
public int getHeight()
public int getComponentCount()
getComponentCount
in class ImageMap
public float getComponent(int component, boolean wrapx, boolean wrapy, double x, double y, double xsize, double ysize)
getComponent
in class ImageMap
public float getAverageComponent(int component)
getAverageComponent
in class ImageMap
public void getColor(RGBColor theColor, boolean wrapx, boolean wrapy, double x, double y, double xsize, double ysize)
public void getGradient(Vec2 grad, int component, boolean wrapx, boolean wrapy, double x, double y, double xsize, double ysize)
getGradient
in class ImageMap
public java.awt.Image getPreview()
getPreview
in class ImageMap
public ImageData getImageData()
ImageData
of this image.public void writeToStream(java.io.DataOutputStream out) throws java.io.IOException
writeToStream
in class ImageMap
java.io.IOException