Canvas 渲染器

Extends annie.AObject
Module: annie

Available since 1.0.0

Methods

begin

begin () public

Defined in libs/CanvasRender.js:41

Available since 1.0.0

开始渲染时执行

beginMask

beginMask
(
  • target
)
public

Defined in libs/CanvasRender.js:58

Available since 1.0.0

开始有遮罩时调用

Parameters:

nametypeflagdescription
target annie.DisplayObject

CanvasRender

CanvasRender
(
  • stage
)
public

Defined in libs/CanvasRender.js:21

Available since 1.0.0

Parameters:

nametypeflagdescription
stage annie.Stage

destroy

destroy () Void public

Inherited from annie.AObject: libs/EventDispatcher.js:55

Available since 2.0.0

销毁一个对象 销毁之前一定要做完其他善后工作,否则有可能会出错 特别注意不能在对象自身方法或事件里调用此方法。 比如,不要在显示对象自身的 annie.Event.ON_REMOVE_TO_STAGE 或者其他类似事件调用,一定会报错

Returns:

Void:

draw

draw
(
  • target
)
public

Defined in libs/CanvasRender.js:166

Available since 1.0.0

调用渲染

Parameters:

nametypeflagdescription
target annie.DisplayObject

显示对象

endMask

endMask () public

Defined in libs/CanvasRender.js:90

Available since 1.0.0

结束遮罩时调用

init

init () public

Defined in libs/CanvasRender.js:230

Available since 1.0.0

初始化渲染器

reSize

reSize () public

Defined in libs/CanvasRender.js:242

Available since 1.0.0

当尺寸改变时调用

Properties

canvas

Any public

Defined in libs/CanvasRender.js:29

Available since 1.0.0

渲染器所在最上层的对象

Default:

null

instanceId

Number public

Inherited from annie.AObject: libs/EventDispatcher.js:23

Available since 1.0.0

每一个annie引擎对象都会有一个唯一的id码。

Example:

 //获取 annie引擎类对象唯一码
 console.log(this.instanceId);

instanceType

String public

Inherited from annie.AObject: libs/EventDispatcher.js:41

Available since 1.0.3

每一个annie类都有一个实例类型字符串,通过这个字符串,你能知道这个实例是从哪个类实例而来

Top