Package | com.transmote.flar.source |
Class | public class FLARCameraSource |
Inheritance | FLARCameraSource flash.display.Sprite |
Implements | IFLARSource |
Property | Defined by | ||
---|---|---|---|
downsampleRatio : Number [read-only]
amount by which the BitmapData source is downsampled
before being sent to FLARToolkit.
| FLARCameraSource | ||
mirrored : Boolean
set to true to flip the camera image horizontally.
| FLARCameraSource | ||
source : BitmapData [read-only]
retrieve the BitmapData source used for analysis.
| FLARCameraSource | ||
sourceSize : Rectangle [read-only]
size of BitmapData source used for analysis.
| FLARCameraSource |
Method | Defined by | ||
---|---|---|---|
FLARCameraSource(captureWidth:int = 640, captureHeight:int = 480, fps:Number = 30, mirrored:Boolean = true, displayWidth:int = -1, displayHeight:int = -1, downsampleRatio:Number = 0.5)
constructor.
| FLARCameraSource | ||
update():void
update the BitmapData source.
| FLARCameraSource |
downsampleRatio | property |
downsampleRatio:Number
[read-only]amount by which the BitmapData source is downsampled before being sent to FLARToolkit.
Implementation public function get downsampleRatio():Number
mirrored | property |
mirrored:Boolean
[read-write]set to true to flip the camera image horizontally.
Implementation public function get mirrored():Boolean
public function set mirrored(value:Boolean):void
source | property |
source:BitmapData
[read-only]retrieve the BitmapData source used for analysis. NOTE: returns the actual BitmapData object, not a clone.
Implementation public function get source():BitmapData
sourceSize | property |
sourceSize:Rectangle
[read-only]size of BitmapData source used for analysis.
Implementation public function get sourceSize():Rectangle
FLARCameraSource | () | constructor |
public function FLARCameraSource(captureWidth:int = 640, captureHeight:int = 480, fps:Number = 30, mirrored:Boolean = true, displayWidth:int = -1, displayHeight:int = -1, downsampleRatio:Number = 0.5)
constructor.
ParameterscaptureWidth:int (default = 640 ) — width at which to capture video.
|
|
captureHeight:int (default = 480 ) — height at which to capture video.
|
|
fps:Number (default = 30 ) — framerate of camera capture.
|
|
mirrored:Boolean (default = true ) — if true, video is flipped horizontally.
|
|
displayWidth:int (default = -1 ) — width at which to display video.
|
|
displayHeight:int (default = -1 ) — height at which to display video.
|
|
downsampleRatio:Number (default = 0.5 ) — amount to downsample camera input.
FLARToolkit runs faster with more downsampling,
but also has more difficulty recognizing marker patterns.
a value of 1.0 results in no downsampling;
a value of 0.5 (the default) downsamples the camera input by half.
|
— if no camera is found.
(thrown by this.init, called from this method.)
|
update | () | method |
public function update():void
update the BitmapData source.