Package | away3d.materials.methods |
Class | public class SimpleShadowMapMethodBase |
Inheritance | SimpleShadowMapMethodBase ShadowMapMethodBase ShadingMethodBase NamedAssetBase flash.events.EventDispatcher |
Subclasses | DitheredShadowMapMethod, FilteredShadowMapMethod, HardShadowMapMethod, NearShadowMapMethod, SoftShadowMapMethod, TripleFilteredShadowMapMethod |
Property | Defined By | ||
---|---|---|---|
_alpha : Number = 1 | ShadowMapMethodBase | ||
_castingLight : LightBase | ShadowMapMethodBase | ||
_depthMapCoordReg : ShaderRegisterElement | SimpleShadowMapMethodBase | ||
_epsilon : Number = .02 | ShadowMapMethodBase | ||
_passes : Vector.<MaterialPassBase> | ShadingMethodBase | ||
_shadowMapper : ShadowMapperBase | ShadowMapMethodBase | ||
_sharedRegisters : ShaderRegisterData | ShadingMethodBase | ||
_usePoint : Boolean | SimpleShadowMapMethodBase |
Method | Defined By | ||
---|---|---|---|
SimpleShadowMapMethodBase(castingLight:LightBase)
Creates a new SimpleShadowMapMethodBase object. | SimpleShadowMapMethodBase | ||
assetPathEquals(name:String, ns:String):Boolean | NamedAssetBase | ||
copyFrom(method:ShadingMethodBase):void
Copies the state from a ShadingMethodBase object into the current object. | ShadingMethodBase | ||
dispose():void
Cleans up any resources used by the current object. | ShadingMethodBase | ||
resetAssetPath(name:String, ns:String = null, overrideOriginal:Boolean = true):void | NamedAssetBase |
Method | Defined By | ||
---|---|---|---|
getPlanarFragmentCode(vo:MethodVO, regCache:ShaderRegisterCache, targetReg:ShaderRegisterElement):String
Gets the fragment code for shadow mapping with a planar shadow map. | SimpleShadowMapMethodBase | ||
Gets the vertex code for shadow mapping with a planar shadow map (fe: directional lights). | SimpleShadowMapMethodBase | ||
getPointFragmentCode(vo:MethodVO, regCache:ShaderRegisterCache, targetReg:ShaderRegisterElement):String
Gets the fragment code for shadow mapping with a point light. | SimpleShadowMapMethodBase | ||
Gets the vertex code for shadow mapping with a point light. | SimpleShadowMapMethodBase | ||
getTex2DSampleCode(vo:MethodVO, targetReg:ShaderRegisterElement, inputReg:ShaderRegisterElement, texture:TextureProxyBase, uvReg:ShaderRegisterElement = null, forceWrap:String = null):String
A helper method that generates standard code for sampling from a texture using the normal uv coordinates. | ShadingMethodBase | ||
getTexCubeSampleCode(vo:MethodVO, targetReg:ShaderRegisterElement, inputReg:ShaderRegisterElement, texture:TextureProxyBase, uvReg:ShaderRegisterElement):String
A helper method that generates standard code for sampling from a cube texture. | ShadingMethodBase | ||
invalidateShaderProgram():void
Marks the shader program as invalid, so it will be recompiled before the next render. | ShadingMethodBase |
_depthMapCoordReg | property |
protected var _depthMapCoordReg:ShaderRegisterElement
_usePoint | property |
protected var _usePoint:Boolean
depthMapCoordReg | property |
depthMapCoordReg:ShaderRegisterElement
Wrappers that override the vertex shader need to set this explicitly
arcane function get depthMapCoordReg():ShaderRegisterElement
arcane function set depthMapCoordReg(value:ShaderRegisterElement):void
SimpleShadowMapMethodBase | () | Constructor |
public function SimpleShadowMapMethodBase(castingLight:LightBase)
Creates a new SimpleShadowMapMethodBase object.
ParameterscastingLight:LightBase — The light used to cast shadows.
|
activate | () | method |
override arcane function activate(vo:MethodVO, stage3DProxy:Stage3DProxy):void
Parameters
vo:MethodVO | |
stage3DProxy:Stage3DProxy |
activateForCascade | () | method |
arcane function activateForCascade(vo:MethodVO, stage3DProxy:Stage3DProxy):void
Sets the method state for cascade shadow mapping.
Parameters
vo:MethodVO | |
stage3DProxy:Stage3DProxy |
cleanCompilationData | () | method |
override arcane function cleanCompilationData():void
getCascadeFragmentCode | () | method |
arcane function getCascadeFragmentCode(vo:MethodVO, regCache:ShaderRegisterCache, decodeRegister:ShaderRegisterElement, depthTexture:ShaderRegisterElement, depthProjection:ShaderRegisterElement, targetRegister:ShaderRegisterElement):String
Gets the fragment code for combining this method with a cascaded shadow map method.
Parameters
vo:MethodVO — The MethodVO object linking this method with the pass currently being compiled.
| |
regCache:ShaderRegisterCache — The register cache used during the compilation.
| |
decodeRegister:ShaderRegisterElement — The register containing the data to decode the shadow map depth value.
| |
depthTexture:ShaderRegisterElement — The texture containing the shadow map.
| |
depthProjection:ShaderRegisterElement — The projection of the fragment relative to the light.
| |
targetRegister:ShaderRegisterElement — The register to contain the shadow coverage
|
String — |
getFragmentCode | () | method |
override arcane function getFragmentCode(vo:MethodVO, regCache:ShaderRegisterCache, targetReg:ShaderRegisterElement):String
Parameters
vo:MethodVO | |
regCache:ShaderRegisterCache | |
targetReg:ShaderRegisterElement |
String |
getPlanarFragmentCode | () | method |
protected function getPlanarFragmentCode(vo:MethodVO, regCache:ShaderRegisterCache, targetReg:ShaderRegisterElement):String
Gets the fragment code for shadow mapping with a planar shadow map.
Parameters
vo:MethodVO — The MethodVO object linking this method with the pass currently being compiled.
| |
regCache:ShaderRegisterCache — The register cache used during the compilation.
| |
targetReg:ShaderRegisterElement — The register to contain the shadow coverage
|
String — |
getPlanarVertexCode | () | method |
protected function getPlanarVertexCode(vo:MethodVO, regCache:ShaderRegisterCache):String
Gets the vertex code for shadow mapping with a planar shadow map (fe: directional lights).
Parameters
vo:MethodVO — The MethodVO object linking this method with the pass currently being compiled.
| |
regCache:ShaderRegisterCache — The register cache used during the compilation.
|
String |
getPointFragmentCode | () | method |
protected function getPointFragmentCode(vo:MethodVO, regCache:ShaderRegisterCache, targetReg:ShaderRegisterElement):String
Gets the fragment code for shadow mapping with a point light.
Parameters
vo:MethodVO — The MethodVO object linking this method with the pass currently being compiled.
| |
regCache:ShaderRegisterCache — The register cache used during the compilation.
| |
targetReg:ShaderRegisterElement — The register to contain the shadow coverage
|
String — |
getPointVertexCode | () | method |
protected function getPointVertexCode(vo:MethodVO, regCache:ShaderRegisterCache):String
Gets the vertex code for shadow mapping with a point light.
Parameters
vo:MethodVO — The MethodVO object linking this method with the pass currently being compiled.
| |
regCache:ShaderRegisterCache — The register cache used during the compilation.
|
String |
getVertexCode | () | method |
override arcane function getVertexCode(vo:MethodVO, regCache:ShaderRegisterCache):String
Parameters
vo:MethodVO | |
regCache:ShaderRegisterCache |
String |
initConstants | () | method |
override arcane function initConstants(vo:MethodVO):void
Initializes unchanging shader constants using the data from a MethodVO.
Parameters
vo:MethodVO — The MethodVO object linking this method with the pass currently being compiled.
|
initVO | () | method |
override arcane function initVO(vo:MethodVO):void
Initializes the properties for a MethodVO, including register and texture indices.
Parameters
vo:MethodVO — The MethodVO object linking this method with the pass currently being compiled.
|
setRenderState | () | method |
override arcane function setRenderState(vo:MethodVO, renderable:IRenderable, stage3DProxy:Stage3DProxy, camera:Camera3D):void
Sets the render state for a single renderable.
Parameters
vo:MethodVO — The MethodVO object linking this method with the pass currently being compiled.
| |
renderable:IRenderable — The renderable currently being rendered.
| |
stage3DProxy:Stage3DProxy — The Stage3DProxy object currently used for rendering.
| |
camera:Camera3D — The camera from which the scene is currently rendered.
|