org.apache.batik.ext.awt.image.rendered

Class PadRed

public class PadRed extends AbstractRed

This is an implementation of a Pad operation as a RenderedImage.
Nested Class Summary
protected static classPadRed.ZeroRecter
protected static classPadRed.ZeroRecter_INT_PACK
Constructor Summary
PadRed(CachableRed src, Rectangle bounds, PadMode padMode, RenderingHints hints)
Construct A Rendered Pad operation.
Method Summary
WritableRastercopyData(WritableRaster wr)
protected static SampleModelfixSampleModel(CachableRed src, 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.
protected voidhandleReplicate(WritableRaster wr)
protected voidhandleWrap(WritableRaster wr)
protected voidhandleZero(WritableRaster wr)

Constructor Detail

PadRed

public PadRed(CachableRed src, Rectangle bounds, PadMode padMode, 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 WritableRaster copyData(WritableRaster wr)

fixSampleModel

protected static SampleModel fixSampleModel(CachableRed src, 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.

handleReplicate

protected void handleReplicate(WritableRaster wr)

handleWrap

protected void handleWrap(WritableRaster wr)

handleZero

protected void handleZero(WritableRaster wr)
Copyright B) 2007 Apache Software Foundation. All Rights Reserved.