public RenderImage(GGraph holder)
{
_width = (int)holder.width;
_height = (int)holder.height;
_cacheTexture = true;
this._image = new Image();
holder.SetNativeObject(this._image);
if (_camera == null)
CreateCamera();
this._root = new GameObject("render_image" + _gid++).transform;
Object.DontDestroyOnLoad(this._root.gameObject);
this._root.SetParent(_camera.transform, false);
SetLayer(this._root.gameObject, HIDDEN_LAYER);
this.modelRoot = new GameObject("model_root").transform;
Object.DontDestroyOnLoad(this.modelRoot.gameObject);
this.modelRoot.SetParent(this._root, false);
this._background = new GameObject("background").transform;
Object.DontDestroyOnLoad(this._background.gameObject);
this._background.SetParent(this._root, false);
this._image.onAddedToStage.Add(OnAddedToStage);
this._image.onRemovedFromStage.Add(OnRemoveFromStage);
if (this._image.stage != null)
OnAddedToStage();
}