Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.sun.jimi.core.raster
Interface ChanneledIntRasterImage

All Known Implementing Classes:
  MemoryIntRasterImage, StampedIntRasterImage

public abstract interface ChanneledIntRasterImage
extends IntRasterImage

Extension of IntRasterImage to support setting individual channels, in the same way IntRasterImage allows getting them.

Fields inherited from class com.sun.jimi.core.raster.IntRasterImage
`CHANNEL_ALPHA, CHANNEL_BLUE, CHANNEL_GREEN, CHANNEL_RED`

Fields inherited from class com.sun.jimi.core.raster.JimiRasterImage
`CHANNEL_ALPHA, CHANNEL_BLUE, CHANNEL_GREEN, CHANNEL_RED, UNKNOWN`

Method Summary
`void` | `setChannelPixel(int channel, int x, int y, byte value)` Set a channel of data for a pixel.
`void` | `setChannelRectangle(int channel, int x, int y, int width, int height, byte[] pixels, int offset, int scansize)` Set a rectangular area of pixel data for a single byte channel of the image.
`void` | `setChannelRow(int channel, int y, byte[] pixels, int offset)`

Methods inherited from interface com.sun.jimi.core.raster.IntRasterImage
`asIntArray, getChannelRectangle, getChannelRow, getPixel, getRectangle, getRow, setPixel, setRectangle, setRow`

Methods inherited from interface com.sun.jimi.core.raster.JimiRasterImage
`getColorModel, getCroppedImageProducer, getHeight, getPixelRGB, getProperties, getRectangleARGBChannels, getRectangleRGB, getRectangleRGBAChannels, getRectangleRGBChannels, getRowRGB, getWidth, waitInfoAvailable`

Methods inherited from interface com.sun.jimi.core.MutableJimiImage
`mustWaitForOptions, setDecodingController, setError, setFinished, setImageConsumerHints, setOptions, setWaitForOptions`

Method Detail

### setChannelRectangle

    public void setChannelRectangle(int channel,
                                    int x,
                                    int y,
                                    int width,
                                    int height,
                                    byte[] pixels,
                                    int offset,
                                    int scansize)
                             throws ImageAccessException

  Set a rectangular area of pixel data for a single byte channel of the image. Channels use the standard AARRGGBB mask, where ALPHA/RED/GREEN/BLUE represent the position of the data though the actual ARGB interpretation if handled by the ColorModel. The channel of data thus may not represent the color component suggested by the channel label.
  Parameters:
    `channel` - the channel to set, either CHANNEL_ALPHA, CHANNEL_RED, CHANNEL_GREEN, or CHANNEL_BLUE
    `x` - x-coordinate
    `y` - y-coordinate
    `width` - rectangle width
    `height` - rectangle height
    `pixels` - pixel data
    `offset` - offset in pixels to start reading from
    `scansize` - length from the start of one row to the start of the next in pixels
  Throws:
    ImageAccessException - if an error prevents image from being accessed

### setChannelRow

    public void setChannelRow(int channel,
                              int y,
                              byte[] pixels,
                              int offset)
                       throws ImageAccessException

### setChannelPixel

    public void setChannelPixel(int channel,
                                int x,
                                int y,
                                byte value)
                         throws ImageAccessException

  Set a channel of data for a pixel.
  Parameters:
    `channel` - the channel to set, either CHANNEL_ALPHA, CHANNEL_RED, CHANNEL_GREEN, or CHANNEL_BLUE
    `x` - x-coordinate
    `y` - y-coordinate
    `value` - channel value
  Throws:
    ImageAccessException - if an error prevents image from being accessed

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD