| Prev Class | Next Class | Frames | No Frames |
| Summary: Nested | Field | Method | Constr | Detail: Nested | Field | Method | Constr |
java.lang.Objectjava.awt.image.Rasterjava.awt.image.WritableRasterpublic class WritableRasterextends RasterField Summary |
Fields inherited from class java.awt.image.Raster | |
dataBuffer, height, minX, minY, numBands, numDataElements, parent, sampleModel, sampleModelTranslateX, sampleModelTranslateY, width | |
Constructor Summary | |
| |
| |
| |
Method Summary | |
Raster |
|
WritableRaster |
|
WritableRaster |
|
WritableRaster |
|
void |
|
void |
|
void |
|
void |
|
void |
|
void |
|
void |
|
void |
|
void |
|
void | |
void | |
void |
|
void |
|
void |
|
void |
|
void |
|
void |
|
Methods inherited from class java.lang.Object | |
clone, equals, extends Object> getClass, finalize, hashCode, notify, notifyAll, toString, wait, wait, wait | |
protected WritableRaster(SampleModel sampleModel, Point origin)
Creates a newWritableRaster.
- Parameters:
sampleModel- the sample model.origin- the origin.
protected WritableRaster(SampleModel sampleModel, DataBuffer dataBuffer, Point origin)
Creates a newWritableRasterinstance.
- Parameters:
sampleModel- the sample model.dataBuffer- the data buffer.origin- the origin.
protected WritableRaster(SampleModel sampleModel, DataBuffer dataBuffer, Rectangle aRegion, Point sampleModelTranslate, WritableRaster parent)
Creates a newWritableRasterinstance.
- Parameters:
sampleModel- the sample model.dataBuffer- the data buffer.aRegion- the raster's bounds.sampleModelTranslate- the translation.parent- the parent.
public Raster createChild(int parentX, int parentY, int width, int height, int childMinX, int childMinY, int[] bandList)
- Overrides:
- createChild in interface Raster
public WritableRaster createWritableChild(int parentX, int parentY, int w, int h, int childMinX, int childMinY, int[] bandList)
- Parameters:
parentX-parentY-w-h-childMinX-childMinY-bandList-
- Returns:
public WritableRaster createWritableTranslatedChild(int childMinX, int childMinY)
- Parameters:
childMinX-childMinY-
- Returns:
public WritableRaster getWritableParent()
Returns the raster's parent, cast as aWritableRaster.
- Returns:
- The raster's parent.
public void setPixel(int x, int y, double[] dArray)
Sets the samples for the pixel at (x, y) in the raster to the specified values.
- Parameters:
x- the x-coordinate of the pixel.y- the y-coordinate of the pixel.dArray- the sample values (nullnot permitted).
- Throws:
NullPointerException- ifdArrayisnull.
public void setPixel(int x, int y, float[] fArray)
Sets the samples for the pixel at (x, y) in the raster to the specified values.
- Parameters:
x- the x-coordinate of the pixel.y- the y-coordinate of the pixel.fArray- the sample values (nullnot permitted).
- Throws:
NullPointerException- iffArrayisnull.
public void setPixel(int x, int y, int[] iArray)
Sets the samples for the pixel at (x, y) in the raster to the specified values.
- Parameters:
x- the x-coordinate of the pixel.y- the y-coordinate of the pixel.iArray- the sample values (nullnot permitted).
- Throws:
NullPointerException- ifiArrayisnull.
public void setPixels(int x, int y, int w, int h, double[] dArray)
Sets the sample values for the pixels in the region specified by (x, y, w, h) in the raster. The array is ordered by pixels (that is, all the samples for the first pixel are grouped together, followed by all the samples for the second pixel, and so on).
- Parameters:
x- the x-coordinate of the top-left pixel.y- the y-coordinate of the top-left pixel.w- the width of the region of pixels.h- the height of the region of pixels.dArray- the pixel sample values (nullnot permitted).
- Throws:
NullPointerException- ifdArrayisnull.
public void setPixels(int x, int y, int w, int h, float[] fArray)
Sets the sample values for the pixels in the region specified by (x, y, w, h) in the raster. The array is ordered by pixels (that is, all the samples for the first pixel are grouped together, followed by all the samples for the second pixel, and so on).
- Parameters:
x- the x-coordinate of the top-left pixel.y- the y-coordinate of the top-left pixel.w- the width of the region of pixels.h- the height of the region of pixels.fArray- the pixel sample values (nullnot permitted).
- Throws:
NullPointerException- iffArrayisnull.
public void setPixels(int x, int y, int w, int h, int[] iArray)
Sets the sample values for the pixels in the region specified by (x, y, w, h) in the raster. The array is ordered by pixels (that is, all the samples for the first pixel are grouped together, followed by all the samples for the second pixel, and so on).
- Parameters:
x- the x-coordinate of the top-left pixel.y- the y-coordinate of the top-left pixel.w- the width of the region of pixels.h- the height of the region of pixels.iArray- the pixel sample values (nullnot permitted).
- Throws:
NullPointerException- ifiArrayisnull.
public void setSample(int x, int y, int b, double s)
Sets the sample value for a band for the pixel at (x, y) in the raster.
- Parameters:
x- the x-coordinate of the pixel.y- the y-coordinate of the pixel.b- the band (in the range0togetNumBands() - 1).s- the sample value.
public void setSample(int x, int y, int b, float s)
Sets the sample value for a band for the pixel at (x, y) in the raster.
- Parameters:
x- the x-coordinate of the pixel.y- the y-coordinate of the pixel.b- the band (in the range0togetNumBands() - 1).s- the sample value.
public void setSample(int x, int y, int b, int s)
Sets the sample value for a band for the pixel at (x, y) in the raster.
- Parameters:
x- the x-coordinate of the pixel.y- the y-coordinate of the pixel.b- the band (in the range0togetNumBands() - 1).s- the sample value.
public void setSamples(int x, int y, int w, int h, int b, double[] dArray)
Sets the sample values for one band for the pixels in the region specified by (x, y, w, h) in the raster.
- Parameters:
x- the x-coordinate of the top-left pixel.y- the y-coordinate of the top-left pixel.w- the width of the region of pixels.h- the height of the region of pixels.b- the band (in the range0to getNumBands() - 1).dArray- the sample values (nullnot permitted).
- Throws:
NullPointerException- ifdArrayisnull.
public void setSamples(int x, int y, int w, int h, int b, float[] fArray)
Sets the sample values for one band for the pixels in the region specified by (x, y, w, h) in the raster.
- Parameters:
x- the x-coordinate of the top-left pixel.y- the y-coordinate of the top-left pixel.w- the width of the region of pixels.h- the height of the region of pixels.b- the band (in the range0to getNumBands() - 1).fArray- the sample values (nullnot permitted).
- Throws:
NullPointerException- iffArrayisnull.
public void setSamples(int x, int y, int w, int h, int b, int[] iArray)
Sets the sample values for one band for the pixels in the region specified by (x, y, w, h) in the raster.
- Parameters:
x- the x-coordinate of the top-left pixel.y- the y-coordinate of the top-left pixel.w- the width of the region of pixels.h- the height of the region of pixels.b- the band (in the range0to getNumBands() - 1).iArray- the sample values (nullnot permitted).
- Throws:
NullPointerException- ifiArrayisnull.