Filter.Pass
defaultPass, enabled, material, postRenderPasses, processor
Constructor and Description |
---|
CartoonEdgeFilter()
Creates a CartoonEdgeFilter
|
Modifier and Type | Method and Description |
---|---|
protected void |
cleanUpFilter(Renderer r)
override this method if you have some cleanup to do
|
float |
getDepthSensitivity()
Return the depth sensitivity
for more details see setDepthSensitivity(float depthSensitivity) |
float |
getDepthThreshold()
returns the depth threshold
for more details see setDepthThreshold(float depthThreshold) |
ColorRGBA |
getEdgeColor()
returns the edge color
|
float |
getEdgeIntensity()
returns the edge intensity
for more details see setEdgeIntensity(float edgeIntensity) |
float |
getEdgeWidth()
returns the width of the edges
|
protected Material |
getMaterial()
Must return the material used for this filter.
|
float |
getNormalSensitivity()
returns the normals sensitivity
form more details see setNormalSensitivity(float normalSensitivity) |
float |
getNormalThreshold()
returns the normal threshold
for more details see setNormalThreshold(float normalThreshold) |
protected void |
initFilter(AssetManager manager,
RenderManager renderManager,
ViewPort vp,
int w,
int h)
Initialization of sub classes filters
This method is called once when the filter is added to the FilterPostProcessor
It should contain Material initializations and extra passes initialization
|
protected boolean |
isRequiresDepthTexture()
Override this method and return true if your Filter needs the depth texture
|
protected void |
postQueue(RenderQueue queue)
Override this method if you want to make a pre pass, before the actual rendering of the frame
|
void |
setDepthSensitivity(float depthSensitivity)
sets the depth sensitivity
defines how much depth will influence edges, default is 10 |
void |
setDepthThreshold(float depthThreshold)
sets the depth threshold
Defines at what threshold of difference of depth an edge is outlined default is 0.1f |
void |
setEdgeColor(ColorRGBA edgeColor)
Sets the edge color, default is black
|
void |
setEdgeIntensity(float edgeIntensity)
sets the edge intensity
Defineshow visible will be the outlined edges |
void |
setEdgeWidth(float edgeWidth)
sets the witdh of the edge in pixels default is 1
|
void |
setNormalSensitivity(float normalSensitivity)
sets the normals sensitivity default is 1
|
void |
setNormalThreshold(float normalThreshold)
sets the normal threshold default is 0.5
|
cleanup, getDefaultPassDepthFormat, getDefaultPassTextureFormat, getName, getPostRenderPasses, getRenderedTexture, getRenderFrameBuffer, init, isEnabled, isRequiresBilinear, isRequiresSceneTexture, postFilter, postFrame, preFrame, read, setDepthTexture, setEnabled, setName, setProcessor, setRenderedTexture, setRenderFrameBuffer, write
protected boolean isRequiresDepthTexture()
Filter
isRequiresDepthTexture
in class Filter
protected void postQueue(RenderQueue queue)
Filter
protected Material getMaterial()
Filter
getMaterial
in class Filter
protected void initFilter(AssetManager manager, RenderManager renderManager, ViewPort vp, int w, int h)
Filter
initFilter
in class Filter
manager
- the assetManagerrenderManager
- the renderManagervp
- the viewPort where this filter is renderedw
- the width of the filterh
- the height of the filterprotected void cleanUpFilter(Renderer r)
Filter
cleanUpFilter
in class Filter
r
- the rendererpublic float getDepthSensitivity()
setDepthSensitivity(float depthSensitivity)
public void setDepthSensitivity(float depthSensitivity)
depthSensitivity
- public float getDepthThreshold()
setDepthThreshold(float depthThreshold)
public void setDepthThreshold(float depthThreshold)
depthThreshold
- public float getEdgeIntensity()
setEdgeIntensity(float edgeIntensity)
public void setEdgeIntensity(float edgeIntensity)
edgeIntensity
- public float getEdgeWidth()
public void setEdgeWidth(float edgeWidth)
edgeWidth
- public float getNormalSensitivity()
setNormalSensitivity(float normalSensitivity)
public void setNormalSensitivity(float normalSensitivity)
normalSensitivity
- public float getNormalThreshold()
setNormalThreshold(float normalThreshold)
public void setNormalThreshold(float normalThreshold)
normalThreshold
- public ColorRGBA getEdgeColor()
public void setEdgeColor(ColorRGBA edgeColor)
edgeColor
-