コード例 #1
0
        /// <summary>
        /// Creates a new render texture element.
        /// </summary>
        /// <param name="texture">Render texture to display in the element.</param>
        /// <param name="style">Optional style to use for the element. Style controls the look of the element, as well as 
        ///                     default layout options. Style will be retrieved from the active GUISkin. If not specified 
        ///                     default element style is used.</param>
        /// <param name="options">Options that allow you to control how is the element  positioned and sized. This will 
        ///                       override any similar options set by style.</param>
        public GUIRenderTexture(RenderTexture2D texture, string style, params GUIOption[] options)
        {
            IntPtr texturePtr = IntPtr.Zero;
            if (texture != null)
                texturePtr = texture.GetCachedPtr();

            Internal_CreateInstance(this, texturePtr, false, style, options);
        }
コード例 #2
0
        /// <summary>
        /// Creates a new render texture element.
        /// </summary>
        /// <param name="texture">Render texture to display in the element.</param>
        /// <param name="transparent">Determines should the texture be rendered with transparency active.</param>
        /// <param name="options">Options that allow you to control how is the element  positioned and sized. This will 
        ///                       override any similar options set by style.</param>
        public GUIRenderTexture(RenderTexture2D texture, bool transparent, params GUIOption[] options)
        {
            IntPtr texturePtr = IntPtr.Zero;
            if (texture != null)
                texturePtr = texture.GetCachedPtr();

            Internal_CreateInstance(this, texturePtr, transparent, "", options);
        }
コード例 #3
0
        /// <summary>
        /// Creates a new render texture element.
        /// </summary>
        /// <param name="texture">Render texture to display in the element.</param>
        /// <param name="style">Optional style to use for the element. Style controls the look of the element, as well as
        ///                     default layout options. Style will be retrieved from the active GUISkin. If not specified
        ///                     default element style is used.</param>
        /// <param name="options">Options that allow you to control how is the element  positioned and sized. This will
        ///                       override any similar options set by style.</param>
        public GUIRenderTexture(RenderTexture2D texture, string style, params GUIOption[] options)
        {
            IntPtr texturePtr = IntPtr.Zero;

            if (texture != null)
            {
                texturePtr = texture.GetCachedPtr();
            }

            Internal_CreateInstance(this, texturePtr, false, style, options);
        }
コード例 #4
0
        /// <summary>
        /// Creates a new render texture element.
        /// </summary>
        /// <param name="texture">Render texture to display in the element.</param>
        /// <param name="transparent">Determines should the texture be rendered with transparency active.</param>
        /// <param name="options">Options that allow you to control how is the element  positioned and sized. This will
        ///                       override any similar options set by style.</param>
        public GUIRenderTexture(RenderTexture2D texture, bool transparent, params GUIOption[] options)
        {
            IntPtr texturePtr = IntPtr.Zero;

            if (texture != null)
            {
                texturePtr = texture.GetCachedPtr();
            }

            Internal_CreateInstance(this, texturePtr, transparent, "", options);
        }