Bitmap


Inheritance Bitmap View Module hilo/view/Bitmap Requires hilo/core/Hilo, hilo/core/Class, hilo/view/View, hilo/view/Drawable Source Bitmap.js
Bitmap


Example:

var bmp = new Hilo.Bitmap({image:imgElem, rect:[0, 0, 100, 100]});
stage.addChild(bmp);

Properties

Show Inherited Properties
Property Defined

Methods

Show Inherited Methods
Method Defined
Bitmap(properties:Object)
Constructor
Bitmap
setImage(Image:Image|String, rect:Array, crossOrigin:Boolean):Bitmap
set the image。
Bitmap

Constructor

Bitmap(properties:Object)
parameters
properties:Object — the options of create Instance.It can contains all writable property and Moreover:
  • image - the image of bitmap which contained, required.
  • rect - the range of bitmap in the image, option
  • crossOrigin - Whether cross-domain is needed, default is false

Method Detail

setImage(Image:Image|String, rect:Array, crossOrigin:Boolean):Bitmap
set the image。
parameters
Image:Image|String — Object or URL.
rect:Array — the range of bitmap in the image, option.
crossOrigin:Boolean — Whether cross-domain is needed, default is false.
return
Bitmap — self。