BitmapDisplacement modifier. Displaces verttices based on RGB values of pixels.
BitmapDisplacement is inspired by both the AS3 built-in DisplacementMapFilter. It allows
to use color values for each channels of a bitmap to modify the position of vertices in a mesh.
The displacement taks place along the cardinal axes, and each axis is mapped to a
channel in the bitmap: X for Red, Y for Green and Z for Blue.
protected var _axes:int = 7
axes:int
[read-write]Implementation
public function get axes():int
public function set axes(value:int):void
protected var _bitmap:BitmapData
bitmap:BitmapData
[read-only]Implementation
public function get bitmap():BitmapData
protected var _force:Number
force:Number
[read-write]Implementation
public function get force():Number
public function set force(value:Number):void
protected var offset:Number = 0x80
public function BitmapDisplacement(b:BitmapData, f:Number = 1)
Parameters
| b:BitmapData |
|
| f:Number (default = 1 )
|
public function apply():void
public function getUVPixel(u:Number, v:Number):uint
Parameters
Returns