Package com.mi.rs
Class public class ImageRenderTarget
Inheritance ImageRenderTarget Inheritance mx.core.UIComponent

A UIComponent that displays images rendered using a command of type IRenderCommand. The application can use any number of ImageRenderTarget objects and update the image they display by using render commands (any implementation of the IRenderCommand interface, like the RenderCommand class).

If the resolution of the rendered image is not equal to the resolution of the ImageRenderTarget object then the image will be scaled automatically. Use the smoothScaling property to enable/disable using smoothing when scaling the image. This property has no effect if scaling is not needed.

The ImageRenderTarget can either be placed as a visible component in the application or it can be used to obtain the rendered image as a BitmapData object . To use it this way, create an ImageRenderTarget, add a RenderCommand with this object as the target, and call ImageRenderTarget.cloneBitmapData() in the response handler of the RenderCommand.



Public Properties
  Property Defined By
    smoothScaling : Boolean
If true the image will be smoothed when scaled.
ImageRenderTarget
Public Methods
  Method Defined By
   
Constructs an ImageRenderTarget.
ImageRenderTarget
   
cloneBitmapData():BitmapData
Returns a copy of the current image as a BitmapData instance.
ImageRenderTarget
   
update_bitmap(bitmap:Bitmap):void
Package internal method called by the service with the Bitmap response of an IRenderCommand.
ImageRenderTarget
Protected Methods
  Method Defined By
   
updateDisplayList(unscaled_width:Number, unscaled_height:Number):void
[override] Implementation of updateDisplayList that draws the current rendered image and scales it if needed.
ImageRenderTarget
Property Detail
smoothScaling property
smoothScaling:Boolean

If true the image will be smoothed when scaled.


Implementation
    public function get smoothScaling():Boolean
    public function set smoothScaling(value:Boolean):void
Constructor Detail
ImageRenderTarget () Constructor
public function ImageRenderTarget()

Constructs an ImageRenderTarget.

Method Detail
cloneBitmapData () method
public function cloneBitmapData():BitmapData

Returns a copy of the current image as a BitmapData instance.

Returns
BitmapData — A BitmapData object containing a copy of the bitmap that contains the currently rendered image, or null if no image has been rendered yet.
update_bitmap () method  
public function update_bitmap(bitmap:Bitmap):void

Package internal method called by the service with the Bitmap response of an IRenderCommand.

Parameters

bitmap:Bitmap
updateDisplayList () method  
override protected function updateDisplayList(unscaled_width:Number, unscaled_height:Number):void

Implementation of updateDisplayList that draws the current rendered image and scales it if needed.

Parameters

unscaled_width:Number
 
unscaled_height:Number