Package | away3d.materials |
Class | public class PhongColorMaterial |
Inheritance | PhongColorMaterial CompositeMaterial BitmapMaterial LayerMaterial ColorMaterial WireColorMaterial WireframeMaterial Material flash.events.EventDispatcher |
Property | Defined by | ||
---|---|---|---|
alpha : Number
Defines an alpha value for the texture bitmap.
| BitmapMaterial | ||
bitmap : BitmapData
Defines the bitmapData object being used as the material texture.
| BitmapMaterial | ||
blendMode : String
Defines a blendMode value for the texture bitmap.
| BitmapMaterial | ||
color : uint
Defines a colored tint for the texture bitmap.
| BitmapMaterial | ||
colorTransform : ColorTransform
Defines a colortransform for the texture bitmap.
| BitmapMaterial | ||
debug : Boolean
Toggles debug mode: textured triangles are drawn with white outlines, precision correction triangles are drawn with blue outlines.
| ColorMaterial | ||
height : Number
Returns the height of the bitmapData being used as the material texture.
| CompositeMaterial | ||
id : int
Unique identifier
| Material | ||
repeat : Boolean
Determines if texture bitmap will tile in uv-space
| BitmapMaterial | ||
shininess : Number
The exponential dropoff value used for specular highlights.
| PhongColorMaterial | ||
showNormals : Boolean
Displays the normals per face in pink lines.
| BitmapMaterial | ||
smooth : Boolean
Determines if texture bitmap is smoothed (bilinearly filtered) when drawn to screen.
| BitmapMaterial | ||
specular : Number
Coefficient for specular light level.
| PhongColorMaterial | ||
surfaceCache : Boolean | CompositeMaterial | ||
thickness : Number
Determines the thickness value of the wire
| WireframeMaterial | ||
transparent : Boolean
Defines whether the caching bitmapData objects are transparent
| CompositeMaterial | ||
visible : Boolean
Indicates whether the material is visible
| WireColorMaterial | ||
width : Number
Returns the width of the bitmapData being used as the material texture.
| CompositeMaterial | ||
wireAlpha : Number
Determines the alpha value of the wire
| WireframeMaterial | ||
wireColor : uint
24 bit color value representing the wire color
| WireframeMaterial |
Method | Defined by | ||
---|---|---|---|
PhongColorMaterial
(color:*, init:Object = null)
Creates a new
PhongBitmapMaterial object. | PhongColorMaterial | ||
CompositeMaterial | |||
addOnMaterialUpdate(listener:Function):void
Default method for adding a materialupdated event listener
| Material | ||
clearMaterials():void
| CompositeMaterial | ||
Duplicates the material properties to another material object.
| ColorMaterial | ||
getPixel32(u:Number, v:Number):uint
Returns the argb value of the bitmapData pixel at the given u v coordinate.
| BitmapMaterial | ||
CompositeMaterial | |||
removeOnMaterialUpdate(listener:Function):void
Default method for removing a materialupdated event listener
| Material |
Method | Defined by | ||
---|---|---|---|
getDefaultThickness():Number
| WireframeMaterial | ||
| CompositeMaterial | ||
BitmapMaterial | |||
BitmapMaterial | |||
updateColorTransform():void
Updates the colortransform object applied to the texture from the
color and alpha properties. | PhongColorMaterial | ||
BitmapMaterial | |||
updateRenderBitmap():void
Updates the texture bitmapData with the colortransform determined from the
color and alpha properties. | CompositeMaterial |
shininess | property |
shininess:Number
[read-write]The exponential dropoff value used for specular highlights.
Implementation public function get shininess():Number
public function set shininess(value:Number):void
specular | property |
specular:Number
[read-write]Coefficient for specular light level.
Implementation public function get specular():Number
public function set specular(value:Number):void
PhongColorMaterial | () | constructor |
public function PhongColorMaterial(color:*, init:Object = null)
Parameters
color:* — A string, hex value or colorname representing the color of the material.
|
|
init:Object (default = null ) — [optional] An initialisation object for specifying default instance properties.
|
shininess:Number (default = 20) | |
specular:Number (default = 0.7, min:0, max:1) |
updateColorTransform | () | method |
protected override function updateColorTransform():void
Updates the colortransform object applied to the texture from the color
and alpha
properties.
See also