public class FixedCutProvider extends Object implements CutProvider
| Modifier and Type | Field and Description |
|---|---|
protected int |
footer |
protected int |
header |
protected int |
left |
protected Logger |
logger |
protected int |
right |
| Constructor and Description |
|---|
FixedCutProvider(int header,
int footer,
int left,
int right) |
| Modifier and Type | Method and Description |
|---|---|
BufferedImage |
cut(BufferedImage image) |
int |
getFooter() |
int |
getHeader() |
int |
getLeft() |
int |
getRight() |
CutProvider |
scale(double scaleRatio)
Get a scaled version of the cut provider.
|
void |
setLogger(Logger logger) |
Region |
toRegion(RectangleSize size) |
protected Logger logger
protected final int header
protected final int footer
protected final int left
protected final int right
public FixedCutProvider(int header,
int footer,
int left,
int right)
header - The header to cut in pixels.footer - The footer to cut in pixels.left - The left to cut in pixels.right - The right to cut in pixels.public BufferedImage cut(BufferedImage image)
cut in interface CutProviderimage - The image to cut.public CutProvider scale(double scaleRatio)
CutProviderscale in interface CutProviderscaleRatio - The ratio by which to scale the current cut parameters.public void setLogger(Logger logger)
setLogger in interface CutProviderpublic Region toRegion(RectangleSize size)
toRegion in interface CutProviderpublic int getHeader()
public int getFooter()
public int getLeft()
public int getRight()
Copyright © 2023. All rights reserved.