Exemple #1
0
        public void Draw(int x, int y, double angle, Vector center)
        {
            if (Handle == IntPtr.Zero)
            {
                throw new InvalidOperationException(Errors.E_TEXTURE_NULL);
            }
            if (renderer == null)
            {
                throw new InvalidOperationException(Errors.E_RENDERER_NULL);
            }

            renderer.RenderTexture(Handle, x, y, Width, Height, angle, center);
        }
Exemple #2
0
        public void Draw(int x, int y)
        {
            if (renderer == null)
            {
                throw new ArgumentNullException("renderer", Errors.E_RENDERER_NULL);
            }

            if (Handle == IntPtr.Zero)
            {
                throw new InvalidOperationException(Errors.E_RENDER_TARGET_NULL);
            }

            renderer.RenderTexture(Handle, x, y, Width, Height);
        }