Package | away3d.materials.methods |
Class | public class LightMapDiffuseMethod |
Inheritance | LightMapDiffuseMethod CompositeDiffuseMethod BasicDiffuseMethod LightingMethodBase ShadingMethodBase NamedAssetBase flash.events.EventDispatcher |
Property | Defined By | ||
---|---|---|---|
alphaThreshold : Number [override]
The minimum alpha value for which pixels should be drawn. | CompositeDiffuseMethod | ||
assetFullPath : Array [read-only] | NamedAssetBase | ||
assetNamespace : String [read-only] | NamedAssetBase | ||
baseMethod : BasicDiffuseMethod
The base diffuse method on which this method's shading is based. | CompositeDiffuseMethod | ||
blendMode : String
The blend mode with which the light map should be applied to the lighting result. | LightMapDiffuseMethod | ||
diffuseAlpha : Number [override]
The alpha component of the diffuse reflection. | CompositeDiffuseMethod | ||
diffuseColor : uint [override]
The color of the diffuse reflection when not using a texture. | CompositeDiffuseMethod | ||
id : String | NamedAssetBase | ||
lightMapTexture : Texture2DBase
The texture containing the light map data. | LightMapDiffuseMethod | ||
name : String | NamedAssetBase | ||
originalName : String [read-only]
The original name used for this asset in the resource (e.g. | NamedAssetBase | ||
passes : Vector.<MaterialPassBase> [read-only]
Any passes required that render to a texture used by this method. | ShadingMethodBase | ||
texture : Texture2DBase [override]
The bitmapData to use to define the diffuse reflection color per texel. | CompositeDiffuseMethod | ||
_totalLightColorReg : ShaderRegisterElement | BasicDiffuseMethod |
Method | Defined By | ||
---|---|---|---|
LightMapDiffuseMethod(lightMap:Texture2DBase, blendMode:String = multiply, useSecondaryUV:Boolean = false, baseMethod:BasicDiffuseMethod = null)
Creates a new LightMapDiffuseMethod method. | LightMapDiffuseMethod | ||
assetPathEquals(name:String, ns:String):Boolean | NamedAssetBase | ||
copyFrom(method:ShadingMethodBase):void [override]
Copies the state from a ShadingMethodBase object into the current object. | BasicDiffuseMethod | ||
dispose():void [override]
Cleans up any resources used by the current object. | CompositeDiffuseMethod | ||
generateMip(stage3DProxy:Stage3DProxy):void
Forces the creation of the texture. | BasicDiffuseMethod | ||
resetAssetPath(name:String, ns:String = null, overrideOriginal:Boolean = true):void | NamedAssetBase |
Constant | Defined By | ||
---|---|---|---|
ADD : String = add [static]
Indicates the light map should be added into the calculated shading result. | LightMapDiffuseMethod | ||
DEFAULT_NAMESPACE : String = default [static] | NamedAssetBase | ||
MULTIPLY : String = multiply [static]
Indicates the light map should be multiplied with the calculated shading result. | LightMapDiffuseMethod |
blendMode | property |
blendMode:String
The blend mode with which the light map should be applied to the lighting result.
public function get blendMode():String
public function set blendMode(value:String):void
See also
lightMapTexture | property |
lightMapTexture:Texture2DBase
The texture containing the light map data.
public function get lightMapTexture():Texture2DBase
public function set lightMapTexture(value:Texture2DBase):void
LightMapDiffuseMethod | () | Constructor |
public function LightMapDiffuseMethod(lightMap:Texture2DBase, blendMode:String = multiply, useSecondaryUV:Boolean = false, baseMethod:BasicDiffuseMethod = null)
Creates a new LightMapDiffuseMethod method.
ParameterslightMap:Texture2DBase — The texture containing the light map.
| |
blendMode:String (default = multiply ) — The blend mode with which the light map should be applied to the lighting result.
| |
useSecondaryUV:Boolean (default = false ) — Indicates whether the secondary UV set should be used to map the light map.
| |
baseMethod:BasicDiffuseMethod (default = null ) — The diffuse method used to calculate the regular light-based lighting.
|
activate | () | method |
override arcane function activate(vo:MethodVO, stage3DProxy:Stage3DProxy):void
Parameters
vo:MethodVO | |
stage3DProxy:Stage3DProxy |
getFragmentPostLightingCode | () | method |
override arcane function getFragmentPostLightingCode(vo:MethodVO, regCache:ShaderRegisterCache, targetReg:ShaderRegisterElement):String
Parameters
vo:MethodVO | |
regCache:ShaderRegisterCache | |
targetReg:ShaderRegisterElement |
String |
initVO | () | method |
ADD | Constant |
public static const ADD:String = add
Indicates the light map should be added into the calculated shading result. This can be used to add pre-calculated lighting or global illumination.
MULTIPLY | Constant |
public static const MULTIPLY:String = multiply
Indicates the light map should be multiplied with the calculated shading result. This can be used to add pre-calculated shadows or occlusion.