org.apache.batik.refimpl.gvt.filter
Class PadRed

java.lang.Object
  |
  +--org.apache.batik.refimpl.gvt.filter.AbstractRed
        |
        +--org.apache.batik.refimpl.gvt.filter.PadRed
All Implemented Interfaces:
CachableRed, java.awt.image.RenderedImage

public class PadRed
extends AbstractRed

This is an implementation of a Pad operation as a RenderedImage.


Fields inherited from class org.apache.batik.refimpl.gvt.filter.AbstractRed
bounds, cm, minTileX, minTileY, numXTiles, numYTiles, props, sm, srcs, tileGridXOff, tileGridYOff, tileHeight, tileWidth
 
Constructor Summary
PadRed(CachableRed src, java.awt.Rectangle bounds, PadMode padMode, java.awt.RenderingHints hints)
          Construct A Rendered Pad operation.
 
Method Summary
 java.awt.image.WritableRaster copyData(java.awt.image.WritableRaster wr)
           
protected static java.awt.image.SampleModel fixSampleModel(CachableRed src, java.awt.Rectangle bounds)
          This function 'fixes' the source's sample model.
 
Methods inherited from class org.apache.batik.refimpl.gvt.filter.AbstractRed
copyBand, copyToRaster, getBounds, getColorModel, getData, getData, getDependencyRegion, getDirtyRegion, getHeight, getMinTileX, getMinTileY, getMinX, getMinY, getNumXTiles, getNumYTiles, getProperty, getPropertyNames, getSampleModel, getSources, getTile, getTileGridXOffset, getTileGridYOffset, getTileHeight, getTileWidth, getWidth, getXTile, getYTile, init, init, makeTile, updateTileGridInfo
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PadRed

public PadRed(CachableRed src,
              java.awt.Rectangle bounds,
              PadMode padMode,
              java.awt.RenderingHints hints)
Construct A Rendered Pad operation. If the pad is smaller than the original image size then this devolves to a Crop.
Parameters:
src - The image to pad/crop
bounds - The bounds of the result (same coord system as src).
padMode - The pad mode to use (currently ignored).
hints - The hints to use for drawing 'pad' area.
Method Detail

copyData

public java.awt.image.WritableRaster copyData(java.awt.image.WritableRaster wr)

fixSampleModel

protected static java.awt.image.SampleModel fixSampleModel(CachableRed src,
                                                           java.awt.Rectangle bounds)
This function 'fixes' the source's sample model. right now it just ensures that the sample model isn't much larger than my width.


Copyright © 2000 Apache Software Foundation. All Rights Reserved.