Esempio n. 1
0
        public TextureBrush(Image image, Rectangle dstRect, ImageAttributes imageAttr)
        {
            if (image == null)
            {
                throw new ArgumentNullException("image");
            }

            IntPtr attr   = imageAttr == null ? IntPtr.Zero : imageAttr.NativeObject;
            Status status = GDIPlus.GdipCreateTextureIAI(image.nativeObject, attr, dstRect.X, dstRect.Y,
                                                         dstRect.Width, dstRect.Height, out nativeObject);

            GDIPlus.CheckStatus(status);
        }