Bitmap bitmap = new Bitmap("1.jpg"); TextureBrush b = new TextureBrush(bitmap);//指定纹理图片 Pen p = new Pen(b, 30);//创建画笔 //用纹理笔刷直接绘制线条 e.Graphics.DrawEllipse(p, 100, 40, 200, 100); p.Dispose();
时间: 2024-11-21 00:43:49
Bitmap bitmap = new Bitmap("1.jpg"); TextureBrush b = new TextureBrush(bitmap);//指定纹理图片 Pen p = new Pen(b, 30);//创建画笔 //用纹理笔刷直接绘制线条 e.Graphics.DrawEllipse(p, 100, 40, 200, 100); p.Dispose();