GoWrapper Class |
Namespace: FairyGUI
public class GoWrapper : DisplayObject
The GoWrapper type exposes the following members.
| Name | Description | |
|---|---|---|
| GoWrapper | Initializes a new instance of the GoWrapper class | |
| GoWrapper(GameObject) | Initializes a new instance of the GoWrapper class |
| Name | Description | |
|---|---|---|
| alpha | (Inherited from DisplayObject.) | |
| blendMode | (Inherited from DisplayObject.) | |
| cacheAsBitmap |
将整个显示对象(如果是容器,则容器包含的整个显示列表)静态化,所有内容被缓冲到一张纹理上。
DC将保持为1。CPU消耗将降到最低。但对象的任何变化不会更新。
当cacheAsBitmap已经为true时,再次调用cacheAsBitmap=true将会刷新一次。
(Inherited from DisplayObject.) | |
| cachedTransform | (Inherited from DisplayObject.) | |
| filter | (Inherited from DisplayObject.) | |
| focalLength | (Inherited from DisplayObject.) | |
| gameObject | (Inherited from DisplayObject.) | |
| graphics | (Inherited from DisplayObject.) | |
| grayed | (Inherited from DisplayObject.) | |
| height | (Inherited from DisplayObject.) | |
| home |
为对象设置一个默认的父Transform。当对象不在显示列表里时,它的GameObject挂到哪里。
(Inherited from DisplayObject.) | |
| isDisposed | (Inherited from DisplayObject.) | |
| layer | (Overrides DisplayObjectlayer.) | |
| location |
This is the pivot position
(Inherited from DisplayObject.) | |
| material | (Inherited from DisplayObject.) | |
| onAddedToStage | (Inherited from DisplayObject.) | |
| onClick | (Inherited from DisplayObject.) | |
| onClickLink | (Inherited from DisplayObject.) | |
| onKeyDown | (Inherited from DisplayObject.) | |
| onMouseWheel | (Inherited from DisplayObject.) | |
| onRemovedFromStage | (Inherited from DisplayObject.) | |
| onRightClick | (Inherited from DisplayObject.) | |
| onRollOut | (Inherited from DisplayObject.) | |
| onRollOver | (Inherited from DisplayObject.) | |
| onTouchBegin | (Inherited from DisplayObject.) | |
| onTouchEnd | (Inherited from DisplayObject.) | |
| onTouchMove | (Inherited from DisplayObject.) | |
| paintingGraphics | (Inherited from DisplayObject.) | |
| paintingMode | (Inherited from DisplayObject.) | |
| parent | (Inherited from DisplayObject.) | |
| perspective |
当对象处于ScreenSpace,也就是使用正交相机渲染时,对象虽然可以绕X轴或者Y轴旋转,但没有透视效果。设置perspective,可以模拟出透视效果。
(Inherited from DisplayObject.) | |
| pivot | (Inherited from DisplayObject.) | |
| position | (Inherited from DisplayObject.) | |
| renderingOrder | (Overrides DisplayObjectrenderingOrder.) | |
| rotation | (Inherited from DisplayObject.) | |
| rotationX | (Inherited from DisplayObject.) | |
| rotationY | (Inherited from DisplayObject.) | |
| scale | (Inherited from DisplayObject.) | |
| scaleX | (Inherited from DisplayObject.) | |
| scaleY | (Inherited from DisplayObject.) | |
| shader | (Inherited from DisplayObject.) | |
| size | (Inherited from DisplayObject.) | |
| skew | (Inherited from DisplayObject.) | |
| stage | (Inherited from DisplayObject.) | |
| topmost | (Inherited from DisplayObject.) | |
| touchable | (Inherited from DisplayObject.) | |
| visible | (Inherited from DisplayObject.) | |
| width | (Inherited from DisplayObject.) | |
| worldSpaceContainer | (Inherited from DisplayObject.) | |
| wrapTarget |
设置包装对象。注意如果原来有包装对象,设置新的包装对象后,原来的包装对象只会被删除引用,但不会被销毁。
对象包含的所有材质不会被复制,如果材质已经是公用的,这可能影响到其他对象。如果希望自动复制,改为使用setWrapTarget(target, true)设置。
| |
| x | (Inherited from DisplayObject.) | |
| xy | (Inherited from DisplayObject.) | |
| y | (Inherited from DisplayObject.) | |
| z | (Inherited from DisplayObject.) |
| Name | Description | |
|---|---|---|
| AddEventListener(String, EventCallback0) | (Inherited from EventDispatcher.) | |
| AddEventListener(String, EventCallback1) | (Inherited from EventDispatcher.) | |
| BroadcastEvent | (Inherited from EventDispatcher.) | |
| BubbleEvent | (Inherited from EventDispatcher.) | |
| CacheRenderers |
GoWrapper will cache all renderers of your gameobject on constructor.
If your gameobject change laterly, call this function to update the cache.
GoWrapper会在构造函数里查询你的gameobject所有的Renderer并保存。如果你的gameobject
后续发生了改变,调用这个函数通知GoWrapper重新查询和保存。
| |
| DispatchEvent(String) | (Inherited from EventDispatcher.) | |
| DispatchEvent(EventContext) | (Inherited from EventDispatcher.) | |
| DispatchEvent(String, Object) | (Inherited from EventDispatcher.) | |
| DispatchEvent(String, Object, Object) | (Inherited from EventDispatcher.) | |
| Dispose | Releases all resources used by the GoWrapper (Overrides DisplayObjectDispose.) | |
| EnsureSizeCorrect | (Inherited from DisplayObject.) | |
| EnterPaintingMode |
进入绘画模式,整个对象将画到一张RenderTexture上,然后这种贴图将代替原有的显示内容。
可以在onPaint回调里对这张纹理进行进一步操作,实现特殊效果。
可能有多个地方要求进入绘画模式,这里用requestorId加以区别,取值是1、2、4、8、16以此类推。1024内内部保留。用户自定义的id从1024开始。
(Inherited from DisplayObject.) | |
| GetBounds | (Inherited from DisplayObject.) | |
| GlobalToLocal |
将舞台坐标转换为本地坐标
(Inherited from DisplayObject.) | |
| InvalidateBatchingState | (Inherited from DisplayObject.) | |
| LeavePaintingMode |
离开绘画模式
(Inherited from DisplayObject.) | |
| LocalToGlobal |
将本地坐标转换为舞台坐标
(Inherited from DisplayObject.) | |
| RemoveEventListener(String, EventCallback0) | (Inherited from EventDispatcher.) | |
| RemoveEventListener(String, EventCallback1) | (Inherited from EventDispatcher.) | |
| RemoveEventListeners | (Inherited from EventDispatcher.) | |
| RemoveEventListeners(String) | (Inherited from EventDispatcher.) | |
| RemoveFromParent | (Inherited from DisplayObject.) | |
| SetPosition | (Inherited from DisplayObject.) | |
| SetScale | (Inherited from DisplayObject.) | |
| SetSize | (Inherited from DisplayObject.) | |
| setWrapTarget |
设置包装对象。注意如果原来有包装对象,设置新的包装对象后,原来的包装对象只会被删除引用,但不会被销毁。
| |
| SetXY | (Inherited from DisplayObject.) | |
| TransformPoint | (Inherited from DisplayObject.) | |
| TransformRect | (Inherited from DisplayObject.) | |
| Update | (Overrides DisplayObjectUpdate(UpdateContext).) | |
| WorldToLocal |
转换世界坐标点到等效的本地xy平面的点。等效的意思是他们在屏幕方向看到的位置一样。
返回的点是在对象的本地坐标空间,且z=0
(Inherited from DisplayObject.) |
| Name | Description | |
|---|---|---|
| gOwner | (Inherited from DisplayObject.) | |
| id | (Inherited from DisplayObject.) | |
| name | (Inherited from DisplayObject.) | |
| onPaint | (Inherited from DisplayObject.) | |
| supportStencil |
被包装对象的材质是否支持Stencil。如果支持,则会自动设置这些材质的stecnil相关参数,从而实现对包装对象的遮罩
|