|
PulpCore | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectpulpcore.image.filter.Filter
pulpcore.image.filter.Blur
pulpcore.image.filter.DropShadow
public class DropShadow
A simple drop shadow.
| Field Summary | |
|---|---|
Color |
color
The shadow color. |
Int |
shadowOffsetX
The shadow x offset. |
Int |
shadowOffsetY
The shadow y offset. |
| Fields inherited from class pulpcore.image.filter.Blur |
|---|
quality, radius |
| Constructor Summary | |
|---|---|
DropShadow()
Creates a Shadow filter with an offset of (3,3), the default shadow color (black with 50% alpha) and the default Blur values. |
|
DropShadow(DropShadow filter)
Copy constructor. |
|
DropShadow(int offsetX,
int offsetY)
Creates a Shadow filter with the specified X and Y offset, the default shadow color (black with 50% alpha) and the default Blur values. |
|
DropShadow(int offsetX,
int offsetY,
int shadowColor)
Creates a Shadow filter with the specified X and Y offset and shadow color, and the default Blur values. |
|
DropShadow(int offsetX,
int offsetY,
int shadowColor,
float radius)
Creates a Shadow filter with the specified X and Y offset, shadow color, and shadow radius. |
|
DropShadow(int offsetX,
int offsetY,
int shadowColor,
float radius,
int quality)
Creates a Shadow filter with the specified X and Y offset, shadow color, shadow radius and shadow quality, from 1 (fastes) to 3 (Guassian approximation). |
|
| Method Summary | |
|---|---|
Filter |
copy()
Creates a copy of the Filter for another Sprite to use. |
protected void |
filter(CoreImage src,
CoreImage dst)
Performs this filter on the input image onto the specified output image. |
int |
getHeight()
Gets the height of the output of this filter. |
int |
getWidth()
Gets the width of the output of this filter. |
int |
getX()
Gets the x offset the output image should display relative to the input. |
int |
getY()
Gets the y offset the output image should display relative to the input. |
boolean |
isOpaque()
Returns true if the output of this filter is opaque. |
void |
update(int elapsedTime)
Updates the filter. |
| Methods inherited from class pulpcore.image.filter.Blur |
|---|
filter, getClampEdges, setClampEdges |
| Methods inherited from class pulpcore.image.filter.Filter |
|---|
filter, getInput, getOutput, isDirty, setDirty, setInput |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public final Int shadowOffsetX
public final Int shadowOffsetY
public final Color color
| Constructor Detail |
|---|
public DropShadow()
Blur values.
public DropShadow(int offsetX,
int offsetY)
Blur values.
public DropShadow(int offsetX,
int offsetY,
int shadowColor)
Blur values.
public DropShadow(int offsetX,
int offsetY,
int shadowColor,
float radius)
public DropShadow(int offsetX,
int offsetY,
int shadowColor,
float radius,
int quality)
public DropShadow(DropShadow filter)
copy().
| Method Detail |
|---|
public Filter copy()
FilterThis method is used by the Sprite class. Most apps will not need to call this method.
Subclasses should bind all properties of the cloned object using bindWithInverse(). For example, for the HSBAdjust filter:
public Filter copy() {
HSBAdjust copy = new HSBAdjust();
copy.hue.bindWithInverse(hue);
copy.brightness.bindWithInverse(brightness);
copy.saturation.bindWithInverse(saturation);
return copy;
}
copy in class Blurpublic void update(int elapsedTime)
Filter
update in class Blurpublic boolean isOpaque()
Filter
isOpaque in class Blurpublic int getX()
Filter
getX in class Blurpublic int getY()
Filter
getY in class Blurpublic int getWidth()
Filter
getWidth in class Blurpublic int getHeight()
Filter
getHeight in class Blur
protected void filter(CoreImage src,
CoreImage dst)
Filter
This method is called from Filter.getOutput() if Filter.isDirty() returns true.
The output image will be the same dimensions as
(Filter.getWidth() x Filter.getHeight(). Implementors must ensure
that every pixel in output is drawn.
filter in class Blur
|
PulpCore | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||