|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface AlphaMask
Bit-mask interface with alpha-channel capability (representation of pixel set in 2D plane).
Field Summary |
---|
Fields inherited from interface cz.cuni.jagrlib.iface.BitMask |
---|
HEIGHT, WIDTH |
Fields inherited from interface cz.cuni.jagrlib.iface.Property |
---|
LOGGING, STATISTICS, TEXT_DESCRIPTION |
Method Summary | |
---|---|
double |
getAlpha(int x,
int y)
Returns the pixel's value. |
void |
getHLine(int x1,
int x2,
int y,
double[] alpha)
Returns the pixels' values for the given horizontal line. |
void |
getRectangle(int x1,
int y1,
int x2,
int y2,
double[][] alpha)
Returns the pixels' values for the given rectangle. |
void |
putHLine(int x1,
int x2,
int y,
double[] alpha)
Sets the horizontal line's values. |
void |
putPixel(int x,
int y,
double alpha)
Sets the given pixel's value to alpha. |
void |
putRectangle(int x1,
int y1,
int x2,
int y2,
double[][] alpha)
Sets the rectangle's values. |
void |
setAlpha(double alpha)
Sets the current default alpha - for inherited methods. |
int |
setAlphaOperation(int _op)
Sets the alpha-channel operation (used in all set*() methods). |
void |
setHLine(int x1,
int x2,
int y,
double alpha)
Sets the horizontal line from [min(x1,x2),y] to [max(x1,x2)-1,y-1]. |
void |
setRectangle(int x1,
int y1,
int x2,
int y2,
double alpha)
Sets the rectangle from [min(x1,x2),min(y1,y2)] to [max(x1,x2)-1,max(y1,y2)-1]. |
Methods inherited from interface cz.cuni.jagrlib.iface.BitMask |
---|
bitBlt, getHLine, getRectangle, putHLine, putPixel, putRectangle, setOperation, setRectangle |
Methods inherited from interface cz.cuni.jagrlib.iface.BitMaskCore |
---|
enumerator, getPixel, init, init, setHLine, setPixel |
Methods inherited from interface cz.cuni.jagrlib.iface.Property |
---|
commit, get, set |
Method Detail |
---|
int setAlphaOperation(int _op)
_op
- Alpha-channel operation (AlphaOperation.ALPHA_* constant).
Alpha-channel operations
void setAlpha(double alpha)
alpha
- Opacity factor (between 0.0 and 1.0).void putPixel(int x, int y, double alpha)
x
- X coordinate of a pixel.y
- Y coordinate of a pixel.alpha
- Opacity factor (between 0.0 and 1.0).double getAlpha(int x, int y)
x
- X coordinate of a pixel.y
- Y coordinate of a pixel.
void setHLine(int x1, int x2, int y, double alpha)
x1
- X coordinate of the starting pixel.x2
- X coordinate of the first pixel after the line.y
- Common Y coordinate of the line.alpha
- Opacity factor (between 0.0 and 1.0).void putHLine(int x1, int x2, int y, double[] alpha)
x1
- X coordinate of the starting pixel.x2
- X coordinate of the first pixel after the line.y
- Common Y coordinate of the line.alpha
- Opacity factors (between 0.0 and 1.0).void getHLine(int x1, int x2, int y, double[] alpha)
x1
- X coordinate of the starting pixel.x2
- X coordinate of the first pixel after the line.y
- Common Y coordinate of the line.alpha
- Returned values in double[] array (0.0 for
off-canvas access).void setRectangle(int x1, int y1, int x2, int y2, double alpha)
x1
- X coordinate of the upper left corner.y1
- Y coordinate of the upper left corner.x2
- X coordinate of the lower right corner (outside pixel).y2
- Y coordinate of the upper left corner (outside pixel).alpha
- Opacity factor (between 0.0 and 1.0).void putRectangle(int x1, int y1, int x2, int y2, double[][] alpha)
x1
- X coordinate of the upper left corner.y1
- Y coordinate of the upper left corner.x2
- X coordinate of the lower right corner (outside pixel).y2
- Y coordinate of the upper left corner (outside pixel).alpha
- Opacity factors (between 0.0 and 1.0).void getRectangle(int x1, int y1, int x2, int y2, double[][] alpha)
x1
- X coordinate of the upper left corner.y1
- Y coordinate of the upper left corner.x2
- X coordinate of the lower right corner (outside pixel).y2
- Y coordinate of the upper left corner (outside pixel).alpha
- Returned values in double[][] array (0.0 for
off-canvas access).
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |