| Package | sandy.materials |
| Class | public class VideoMaterial |
| Inheritance | VideoMaterial BitmapMaterial Material |
Based on the AS2 class VideoSkin made by kiroukou and zeusprod
| Property | Defined by | ||
|---|---|---|---|
![]() | attributes : MaterialAttributes
The attributes of this material.
| Material | |
| DEFAULT_FILL_COLOR : uint = 0 [static]
Default color used to draw the bitmapdata content with.
| VideoMaterial | ||
![]() | filters : Array
The array of filters for this material.
| Material | |
![]() | graphics : Graphics | BitmapMaterial | |
![]() | id : Number
The unique id of this material
| Material | |
![]() | lightingEnable : Boolean = false
Specify is the material can receive light and apply the lightAttributes if specified.
| Material | |
![]() | map : Matrix | BitmapMaterial | |
![]() | modified : Boolean
The modified state of this material.
| Material | |
![]() | polygon : Polygon | BitmapMaterial | |
![]() | precision : uint = 0
Precision of the bitmap mapping.
| BitmapMaterial | |
![]() | repeat : Boolean
The repeat property (?).
| Material | |
![]() | smooth : Boolean = false
This property enable smooth bitmap rendering when set to true.
| BitmapMaterial | |
![]() | texture : BitmapData
The texture ( bitmap ) of this material
| BitmapMaterial | |
![]() | type : MaterialType
The material type of this material.
| Material | |
![]() | useVertexNormal : Boolean = false
Specify if the material use the vertex normal information
Default value is set to false.
| Material | |
| Method | Defined by | ||
|---|---|---|---|
|
VideoMaterial(p_oVideo:Video, p_nUpdateMS:uint = 40, p_oAttr:MaterialAttributes = null)
Creates a new VideoMaterial.
| VideoMaterial | ||
![]() |
Initiates this material.
| BitmapMaterial | |
|
Renders this material on the face it dresses.
| VideoMaterial | ||
|
setTransparency(p_nValue:Number):void
Changes the transparency of the texture.
| VideoMaterial | ||
|
start():void
Call this method when you want to start the material update.
| VideoMaterial | ||
|
stop():void
Call this method is case you would like to stop the automatic video material graphics update.
| VideoMaterial | ||
![]() |
toString():String
| BitmapMaterial | |
| DEFAULT_FILL_COLOR | property |
public static var DEFAULT_FILL_COLOR:uint = 0Default color used to draw the bitmapdata content with. In case you need a specific color, change this value at your application initialization
| VideoMaterial | () | constructor |
public function VideoMaterial(p_oVideo:Video, p_nUpdateMS:uint = 40, p_oAttr:MaterialAttributes = null)Creates a new VideoMaterial.
The video is converted to a bitmap to give it a perspective distortion.
To see the animation, the bitmap has to be recreated from the video on a regular basis.
p_oVideo:Video — The video to be shown by this material
|
|
p_nUpdateMS:uint (default = 40) — The update interval
|
|
p_oAttr:MaterialAttributes (default = null) — The material attributes
|
| renderPolygon | () | method |
public override function renderPolygon(p_oScene:Scene3D, p_oPolygon:Polygon, p_mcContainer:Sprite):voidRenders this material on the face it dresses.
Parametersp_oScene:Scene3D — The current scene
|
|
p_oPolygon:Polygon — The face to be rendered
|
|
p_mcContainer:Sprite — The container to draw on
|
| setTransparency | () | method |
public override function setTransparency(p_nValue:Number):voidChanges the transparency of the texture.
The passed value is the percentage of opacity.
Parametersp_nValue:Number — A value between 0 and 1. (automatically constrained)
|
| start | () | method |
public function start():voidCall this method when you want to start the material update. This is automatically called at the material creation so basically it is used only when the VideoMaterial::stop() method has been called
| stop | () | method |
public function stop():voidCall this method is case you would like to stop the automatic video material graphics update.