Packageaway3d.materials.compilation
Classpublic class ShaderCompiler
InheritanceShaderCompiler Inheritance Object
Subclasses LightingShaderCompiler, SuperShaderCompiler



Public Properties
 PropertyDefined By
  alphaPremultiplied : Boolean
ShaderCompiler
  animatableAttributes : Vector.<String>
[read-only]
ShaderCompiler
  animateUVs : Boolean
ShaderCompiler
  animationTargetRegisters : Vector.<String>
[read-only]
ShaderCompiler
  cameraPositionIndex : int
[read-only]
ShaderCompiler
  commonsDataIndex : int
[read-only]
ShaderCompiler
  diffuseLightSources : uint
ShaderCompiler
  fragmentCode : String
[read-only]
ShaderCompiler
  fragmentLightCode : String
[read-only]
ShaderCompiler
  framentPostLightCode : String
[read-only]
ShaderCompiler
  lightFragmentConstantIndex : int
[read-only]
ShaderCompiler
  lightProbeDiffuseIndices : Vector.<uint>
[read-only]
ShaderCompiler
  lightProbeSpecularIndices : Vector.<uint>
[read-only]
ShaderCompiler
  methodSetup : ShaderMethodSetup
ShaderCompiler
  needUVAnimation : Boolean
[read-only]
ShaderCompiler
  normalBufferIndex : int
[read-only]
ShaderCompiler
  numDirectionalLights : uint
ShaderCompiler
  numLightProbes : uint
ShaderCompiler
  numPointLights : uint
ShaderCompiler
  numUsedFragmentConstants : uint
[read-only]
ShaderCompiler
  numUsedStreams : uint
[read-only]
ShaderCompiler
  numUsedTextures : uint
[read-only]
ShaderCompiler
  numUsedVaryings : uint
[read-only]
ShaderCompiler
  numUsedVertexConstants : uint
[read-only]
ShaderCompiler
  preserveAlpha : Boolean
ShaderCompiler
  probeWeightsIndex : int
[read-only]
ShaderCompiler
  sceneMatrixIndex : int
[read-only]
ShaderCompiler
  sceneNormalMatrixIndex : int
[read-only]
ShaderCompiler
  secondaryUVBufferIndex : int
[read-only]
ShaderCompiler
  shadedTarget : String
[read-only]
ShaderCompiler
  specularLightSources : uint
ShaderCompiler
  tangentBufferIndex : int
[read-only]
ShaderCompiler
  usesNormals : Boolean
[read-only]
ShaderCompiler
  usingSpecularMethod : Boolean
[read-only]
ShaderCompiler
  uvBufferIndex : int
[read-only]
ShaderCompiler
  UVSource : String
[read-only]
ShaderCompiler
  UVTarget : String
[read-only]
ShaderCompiler
  uvTransformIndex : int
[read-only]
ShaderCompiler
  vertexCode : String
[read-only]
ShaderCompiler
  vertexConstantsOffset : uint
[read-only]
ShaderCompiler
Protected Properties
 PropertyDefined By
  _alphaPremultiplied : Boolean
ShaderCompiler
  _animatableAttributes : Vector.<String>
ShaderCompiler
  _animateUVs : Boolean
ShaderCompiler
  _animationTargetRegisters : Vector.<String>
ShaderCompiler
  _cameraPositionIndex : int = -1
ShaderCompiler
  _combinedLightSources : uint
ShaderCompiler
  _dependencyCounter : MethodDependencyCounter
ShaderCompiler
  _diffuseLightSources : uint
ShaderCompiler
  _fragmentCode : String
ShaderCompiler
  _fragmentConstantData : Vector.<Number>
ShaderCompiler
  _fragmentLightCode : String
ShaderCompiler
  _framentPostLightCode : String
ShaderCompiler
  _lightFragmentConstantIndex : int = -1
ShaderCompiler
  _lightProbeDiffuseIndices : Vector.<uint>
ShaderCompiler
  _lightProbeSpecularIndices : Vector.<uint>
ShaderCompiler
  _methodSetup : ShaderMethodSetup
ShaderCompiler
  _mipmap : Boolean
ShaderCompiler
  _needUVAnimation : Boolean
ShaderCompiler
  _normalBufferIndex : int = -1
ShaderCompiler
  _numDirectionalLights : uint
ShaderCompiler
  _numLightProbes : uint
ShaderCompiler
  _numLights : int
ShaderCompiler
  _numPointLights : uint
ShaderCompiler
  _numProbeRegisters : Number
ShaderCompiler
  _preserveAlpha : Boolean = true
ShaderCompiler
  _probeWeightsIndex : int = -1
ShaderCompiler
  _registerCache : ShaderRegisterCache
ShaderCompiler
  _repeat : Boolean
ShaderCompiler
  _sceneMatrixIndex : int = -1
ShaderCompiler
  _sceneNormalMatrixIndex : int = -1
ShaderCompiler
  _secondaryUVBufferIndex : int = -1
ShaderCompiler
  _sharedRegisters : ShaderRegisterData
ShaderCompiler
  _smooth : Boolean
ShaderCompiler
  _specularLightSources : uint
ShaderCompiler
  _tangentBufferIndex : int = -1
ShaderCompiler
  _usingSpecularMethod : Boolean
ShaderCompiler
  _uvBufferIndex : int = -1
ShaderCompiler
  _UVSource : String
ShaderCompiler
  _UVTarget : String
ShaderCompiler
  _uvTransformIndex : int = -1
ShaderCompiler
  _vertexCode : String
ShaderCompiler
  _vertexConstantData : Vector.<Number>
ShaderCompiler
  _vertexConstantsOffset : uint
ShaderCompiler
Public Methods
 MethodDefined By
  
ShaderCompiler
  
compile():void
ShaderCompiler
  
dispose():void
ShaderCompiler
  
setConstantDataBuffers(vertexConstantData:Vector.<Number>, fragmentConstantData:Vector.<Number>):void
ShaderCompiler
  
setTextureSampling(smooth:Boolean, repeat:Boolean, mipmap:Boolean):void
ShaderCompiler
Protected Methods
 MethodDefined By
  
ShaderCompiler
  
ShaderCompiler
  
ShaderCompiler
  
ShaderCompiler
  
ShaderCompiler
  
ShaderCompiler
  
ShaderCompiler
  
ShaderCompiler
  
ShaderCompiler
  
usesLights():Boolean
ShaderCompiler
  
ShaderCompiler
  
ShaderCompiler
  
usesProbes():Boolean
ShaderCompiler
  
ShaderCompiler
  
ShaderCompiler
Property Detail
_alphaPremultipliedproperty
protected var _alphaPremultiplied:Boolean

_animatableAttributesproperty 
protected var _animatableAttributes:Vector.<String>

_animateUVsproperty 
protected var _animateUVs:Boolean

_animationTargetRegistersproperty 
protected var _animationTargetRegisters:Vector.<String>

_cameraPositionIndexproperty 
protected var _cameraPositionIndex:int = -1

_combinedLightSourcesproperty 
protected var _combinedLightSources:uint

_dependencyCounterproperty 
protected var _dependencyCounter:MethodDependencyCounter

_diffuseLightSourcesproperty 
protected var _diffuseLightSources:uint

_fragmentCodeproperty 
protected var _fragmentCode:String

_fragmentConstantDataproperty 
protected var _fragmentConstantData:Vector.<Number>

_fragmentLightCodeproperty 
protected var _fragmentLightCode:String

_framentPostLightCodeproperty 
protected var _framentPostLightCode:String

_lightFragmentConstantIndexproperty 
protected var _lightFragmentConstantIndex:int = -1

_lightProbeDiffuseIndicesproperty 
protected var _lightProbeDiffuseIndices:Vector.<uint>

_lightProbeSpecularIndicesproperty 
protected var _lightProbeSpecularIndices:Vector.<uint>

_methodSetupproperty 
protected var _methodSetup:ShaderMethodSetup

_mipmapproperty 
protected var _mipmap:Boolean

_needUVAnimationproperty 
protected var _needUVAnimation:Boolean

_normalBufferIndexproperty 
protected var _normalBufferIndex:int = -1

_numDirectionalLightsproperty 
protected var _numDirectionalLights:uint

_numLightProbesproperty 
protected var _numLightProbes:uint

_numLightsproperty 
protected var _numLights:int

_numPointLightsproperty 
protected var _numPointLights:uint

_numProbeRegistersproperty 
protected var _numProbeRegisters:Number

_preserveAlphaproperty 
protected var _preserveAlpha:Boolean = true

_probeWeightsIndexproperty 
protected var _probeWeightsIndex:int = -1

_registerCacheproperty 
protected var _registerCache:ShaderRegisterCache

_repeatproperty 
protected var _repeat:Boolean

_sceneMatrixIndexproperty 
protected var _sceneMatrixIndex:int = -1

_sceneNormalMatrixIndexproperty 
protected var _sceneNormalMatrixIndex:int = -1

_secondaryUVBufferIndexproperty 
protected var _secondaryUVBufferIndex:int = -1

_sharedRegistersproperty 
protected var _sharedRegisters:ShaderRegisterData

_smoothproperty 
protected var _smooth:Boolean

_specularLightSourcesproperty 
protected var _specularLightSources:uint

_tangentBufferIndexproperty 
protected var _tangentBufferIndex:int = -1

_usingSpecularMethodproperty 
protected var _usingSpecularMethod:Boolean

_uvBufferIndexproperty 
protected var _uvBufferIndex:int = -1

_UVSourceproperty 
protected var _UVSource:String

_UVTargetproperty 
protected var _UVTarget:String

_uvTransformIndexproperty 
protected var _uvTransformIndex:int = -1

_vertexCodeproperty 
protected var _vertexCode:String

_vertexConstantDataproperty 
protected var _vertexConstantData:Vector.<Number>

_vertexConstantsOffsetproperty 
protected var _vertexConstantsOffset:uint

alphaPremultipliedproperty 
alphaPremultiplied:Boolean


Implementation
    public function get alphaPremultiplied():Boolean
    public function set alphaPremultiplied(value:Boolean):void
animatableAttributesproperty 
animatableAttributes:Vector.<String>  [read-only]


Implementation
    public function get animatableAttributes():Vector.<String>
animateUVsproperty 
animateUVs:Boolean


Implementation
    public function get animateUVs():Boolean
    public function set animateUVs(value:Boolean):void
animationTargetRegistersproperty 
animationTargetRegisters:Vector.<String>  [read-only]


Implementation
    public function get animationTargetRegisters():Vector.<String>
cameraPositionIndexproperty 
cameraPositionIndex:int  [read-only]


Implementation
    public function get cameraPositionIndex():int
commonsDataIndexproperty 
commonsDataIndex:int  [read-only]


Implementation
    public function get commonsDataIndex():int
diffuseLightSourcesproperty 
diffuseLightSources:uint


Implementation
    public function get diffuseLightSources():uint
    public function set diffuseLightSources(value:uint):void
fragmentCodeproperty 
fragmentCode:String  [read-only]


Implementation
    public function get fragmentCode():String
fragmentLightCodeproperty 
fragmentLightCode:String  [read-only]


Implementation
    public function get fragmentLightCode():String
framentPostLightCodeproperty 
framentPostLightCode:String  [read-only]


Implementation
    public function get framentPostLightCode():String
lightFragmentConstantIndexproperty 
lightFragmentConstantIndex:int  [read-only]


Implementation
    public function get lightFragmentConstantIndex():int
lightProbeDiffuseIndicesproperty 
lightProbeDiffuseIndices:Vector.<uint>  [read-only]


Implementation
    public function get lightProbeDiffuseIndices():Vector.<uint>
lightProbeSpecularIndicesproperty 
lightProbeSpecularIndices:Vector.<uint>  [read-only]


Implementation
    public function get lightProbeSpecularIndices():Vector.<uint>
methodSetupproperty 
methodSetup:ShaderMethodSetup


Implementation
    public function get methodSetup():ShaderMethodSetup
    public function set methodSetup(value:ShaderMethodSetup):void
needUVAnimationproperty 
needUVAnimation:Boolean  [read-only]


Implementation
    public function get needUVAnimation():Boolean
normalBufferIndexproperty 
normalBufferIndex:int  [read-only]


Implementation
    public function get normalBufferIndex():int
numDirectionalLightsproperty 
numDirectionalLights:uint


Implementation
    public function get numDirectionalLights():uint
    public function set numDirectionalLights(value:uint):void
numLightProbesproperty 
numLightProbes:uint


Implementation
    public function get numLightProbes():uint
    public function set numLightProbes(value:uint):void
numPointLightsproperty 
numPointLights:uint


Implementation
    public function get numPointLights():uint
    public function set numPointLights(value:uint):void
numUsedFragmentConstantsproperty 
numUsedFragmentConstants:uint  [read-only]


Implementation
    public function get numUsedFragmentConstants():uint
numUsedStreamsproperty 
numUsedStreams:uint  [read-only]


Implementation
    public function get numUsedStreams():uint
numUsedTexturesproperty 
numUsedTextures:uint  [read-only]


Implementation
    public function get numUsedTextures():uint
numUsedVaryingsproperty 
numUsedVaryings:uint  [read-only]


Implementation
    public function get numUsedVaryings():uint
numUsedVertexConstantsproperty 
numUsedVertexConstants:uint  [read-only]


Implementation
    public function get numUsedVertexConstants():uint
preserveAlphaproperty 
preserveAlpha:Boolean


Implementation
    public function get preserveAlpha():Boolean
    public function set preserveAlpha(value:Boolean):void
probeWeightsIndexproperty 
probeWeightsIndex:int  [read-only]


Implementation
    public function get probeWeightsIndex():int
sceneMatrixIndexproperty 
sceneMatrixIndex:int  [read-only]


Implementation
    public function get sceneMatrixIndex():int
sceneNormalMatrixIndexproperty 
sceneNormalMatrixIndex:int  [read-only]


Implementation
    public function get sceneNormalMatrixIndex():int
secondaryUVBufferIndexproperty 
secondaryUVBufferIndex:int  [read-only]


Implementation
    public function get secondaryUVBufferIndex():int
shadedTargetproperty 
shadedTarget:String  [read-only]


Implementation
    public function get shadedTarget():String
specularLightSourcesproperty 
specularLightSources:uint


Implementation
    public function get specularLightSources():uint
    public function set specularLightSources(value:uint):void
tangentBufferIndexproperty 
tangentBufferIndex:int  [read-only]


Implementation
    public function get tangentBufferIndex():int
usesNormalsproperty 
usesNormals:Boolean  [read-only]


Implementation
    public function get usesNormals():Boolean
usingSpecularMethodproperty 
usingSpecularMethod:Boolean  [read-only]


Implementation
    public function get usingSpecularMethod():Boolean
uvBufferIndexproperty 
uvBufferIndex:int  [read-only]


Implementation
    public function get uvBufferIndex():int
UVSourceproperty 
UVSource:String  [read-only]


Implementation
    public function get UVSource():String
UVTargetproperty 
UVTarget:String  [read-only]


Implementation
    public function get UVTarget():String
uvTransformIndexproperty 
uvTransformIndex:int  [read-only]


Implementation
    public function get uvTransformIndex():int
vertexCodeproperty 
vertexCode:String  [read-only]


Implementation
    public function get vertexCode():String
vertexConstantsOffsetproperty 
vertexConstantsOffset:uint  [read-only]


Implementation
    public function get vertexConstantsOffset():uint
Constructor Detail
ShaderCompiler()Constructor
public function ShaderCompiler()



Method Detail
calculateDependencies()method
protected function calculateDependencies():void

compile()method 
public function compile():void

compileGlobalPositionCode()method 
protected function compileGlobalPositionCode():void

compileLightingCode()method 
protected function compileLightingCode():void

compileMethods()method 
protected function compileMethods():void

compileMethodsCode()method 
protected function compileMethodsCode():void

compileNormalCode()method 
protected function compileNormalCode():void

compileViewDirCode()method 
protected function compileViewDirCode():void

dispose()method 
public function dispose():void

initLightData()method 
protected function initLightData():void

initRegisterIndices()method 
protected function initRegisterIndices():void

setConstantDataBuffers()method 
public function setConstantDataBuffers(vertexConstantData:Vector.<Number>, fragmentConstantData:Vector.<Number>):void

Parameters

vertexConstantData:Vector.<Number>
 
fragmentConstantData:Vector.<Number>

setTextureSampling()method 
public function setTextureSampling(smooth:Boolean, repeat:Boolean, mipmap:Boolean):void

Parameters

smooth:Boolean
 
repeat:Boolean
 
mipmap:Boolean

usesLights()method 
protected function usesLights():Boolean

Returns
Boolean
usesLightsForDiffuse()method 
protected function usesLightsForDiffuse():Boolean

Returns
Boolean
usesLightsForSpecular()method 
protected function usesLightsForSpecular():Boolean

Returns
Boolean
usesProbes()method 
protected function usesProbes():Boolean

Returns
Boolean
usesProbesForDiffuse()method 
protected function usesProbesForDiffuse():Boolean

Returns
Boolean
usesProbesForSpecular()method 
protected function usesProbesForSpecular():Boolean

Returns
Boolean