new lego.Stage()
Properties:
Name | Type | Description |
---|---|---|
canvas |
Canvas | |
ctx |
CavansContext2d | |
_lastTime |
Number | 上次执行时间 |
Extends
Methods
-
inherited _draw(ctx)
-
子类自己实现渲染方法
Name Type Description ctx
CanvasContext2d -
_init()
-
-
_tick()
-
-
inherited _transform(ctx)
-
转换坐标
Name Type Description ctx
CanvasContext2d -
inherited addChild(child)
-
添加对象
Name Type Description child
lego.View -
inherited getVector()
-
获取坐标
-
inherited removeChild(child)
-
移除对象
Name Type Description child
lego.View -
inherited removeFromParent()
-
从父容器中移除
-
inherited render(ctx, dt)
-
渲染
Name Type Description ctx
CanvasContext2d dt
Number -
resize()
-
-
start()
-
-
stop()
-