Packageaway3d.materials.methods
Classpublic class AnisotropicSpecularMethod
InheritanceAnisotropicSpecularMethod Inheritance BasicSpecularMethod Inheritance LightingMethodBase Inheritance ShadingMethodBase Inheritance NamedAssetBase Inheritance flash.events.EventDispatcher

AnisotropicSpecularMethod provides a specular method resulting in anisotropic highlights. These are typical for surfaces with microfacet details such as tiny grooves. In particular, this uses the Heidrich-Seidel distrubution. The tangent vectors are used as the surface groove directions.



Public Properties
 PropertyDefined By
 InheritedassetFullPath : Array
[read-only]
NamedAssetBase
 InheritedassetNamespace : String
[read-only]
NamedAssetBase
 Inheritedgloss : Number
The sharpness of the specular highlight.
BasicSpecularMethod
 Inheritedid : String
NamedAssetBase
 Inheritedname : String
NamedAssetBase
 InheritedoriginalName : String
[read-only] The original name used for this asset in the resource (e.g.
NamedAssetBase
 Inheritedpasses : Vector.<MaterialPassBase>
[read-only] Any passes required that render to a texture used by this method.
ShadingMethodBase
 Inheritedspecular : Number
The overall strength of the specular highlights.
BasicSpecularMethod
 InheritedspecularColor : uint
The colour of the specular reflection of the surface.
BasicSpecularMethod
 Inheritedtexture : Texture2DBase
The bitmapData that encodes the specular highlight strength per texel in the red channel, and the sharpness in the green channel.
BasicSpecularMethod
Protected Properties
 PropertyDefined By
 Inherited_isFirstLight : Boolean
BasicSpecularMethod
 Inherited_passes : Vector.<MaterialPassBase>
ShadingMethodBase
 Inherited_sharedRegisters : ShaderRegisterData
ShadingMethodBase
 Inherited_specularDataRegister : ShaderRegisterElement
BasicSpecularMethod
 Inherited_specularTexData : ShaderRegisterElement
BasicSpecularMethod
 Inherited_specularTextureRegister : ShaderRegisterElement
BasicSpecularMethod
 Inherited_totalLightColorReg : ShaderRegisterElement
BasicSpecularMethod
 Inherited_useTexture : Boolean
BasicSpecularMethod
Public Methods
 MethodDefined By
  
Creates a new AnisotropicSpecularMethod object.
AnisotropicSpecularMethod
 Inherited
assetPathEquals(name:String, ns:String):Boolean
NamedAssetBase
 Inherited
[override] Copies the state from a ShadingMethodBase object into the current object.
BasicSpecularMethod
 Inherited
dispose():void
Cleans up any resources used by the current object.
ShadingMethodBase
 Inherited
resetAssetPath(name:String, ns:String = null, overrideOriginal:Boolean = true):void
NamedAssetBase
Protected Methods
 MethodDefined By
 Inherited
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
 Inherited
A helper method that generates standard code for sampling from a cube texture.
ShadingMethodBase
 Inherited
Marks the shader program as invalid, so it will be recompiled before the next render.
ShadingMethodBase
Public Constants
 ConstantDefined By
 InheritedDEFAULT_NAMESPACE : String = default
[static]
NamedAssetBase
Constructor Detail
AnisotropicSpecularMethod()Constructor
public function AnisotropicSpecularMethod()

Creates a new AnisotropicSpecularMethod object.

Method Detail
getFragmentCodePerLight()method
override arcane function getFragmentCodePerLight(vo:MethodVO, lightDirReg:ShaderRegisterElement, lightColReg:ShaderRegisterElement, regCache:ShaderRegisterCache):String

Get the fragment shader code that will generate the code relevant to a single light.

Parameters

vo:MethodVO — The MethodVO object containing the method data for the currently compiled material pass.
 
lightDirReg:ShaderRegisterElement — The register containing the light direction vector.
 
lightColReg:ShaderRegisterElement — The register containing the light colour.
 
regCache:ShaderRegisterCache — The register cache used during the compilation.

Returns
String
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.