四联光电智能照明论坛

 找回密码
 立即注册
搜索
热搜: 活动 交友 discuz
查看: 3366|回复: 7
打印 上一主题 下一主题

绘图

[复制链接]
  • TA的每日心情
    开心
    2018-12-28 16:25
  • 817

    主题

    1556

    帖子

    1万

    积分

    管理员

    Rank: 9Rank: 9Rank: 9

    积分
    14941
    跳转到指定楼层
    楼主
    发表于 2018-6-15 14:20:25 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
    c# 自动计算字符串的宽度 - 脸谱匠 - 博客园 https://www.cnblogs.com/icyJ/p/MeasureText.html
  • TA的每日心情
    开心
    2018-12-28 16:25
  • 817

    主题

    1556

    帖子

    1万

    积分

    管理员

    Rank: 9Rank: 9Rank: 9

    积分
    14941
    沙发
     楼主| 发表于 2018-6-15 14:20:56 | 只看该作者
    C#Color对象的使用介绍及颜色对照表 - 杨奉武 - 博客园 https://www.cnblogs.com/yangfengwu/p/6135941.html
  • TA的每日心情
    开心
    2018-12-28 16:25
  • 817

    主题

    1556

    帖子

    1万

    积分

    管理员

    Rank: 9Rank: 9Rank: 9

    积分
    14941
    板凳
     楼主| 发表于 2018-6-18 22:25:36 | 只看该作者
    C#图像处理(各种旋转、改变大小、柔化、锐化、雾化、底片、浮雕、黑白、滤镜效果) - CSDN博客 https://blog.csdn.net/shuliuzh/article/details/38553497
  • TA的每日心情
    开心
    2018-12-28 16:25
  • 817

    主题

    1556

    帖子

    1万

    积分

    管理员

    Rank: 9Rank: 9Rank: 9

    积分
    14941
    地板
     楼主| 发表于 2018-6-19 10:08:26 | 只看该作者
    C#中基于GDI+(Graphics)图像处理系列之高质量缩略图 - CSDN博客 https://blog.csdn.net/lhtzbj12/article/details/54099246
  • TA的每日心情
    开心
    2018-12-28 16:25
  • 817

    主题

    1556

    帖子

    1万

    积分

    管理员

    Rank: 9Rank: 9Rank: 9

    积分
    14941
    5#
     楼主| 发表于 2019-1-28 15:36:07 | 只看该作者
    C# WinForm窗体四周阴影效果 - 于大大大洋 - CSDN博客 https://blog.csdn.net/arrowzz/article/details/77899061
  • TA的每日心情
    开心
    2018-12-28 16:25
  • 817

    主题

    1556

    帖子

    1万

    积分

    管理员

    Rank: 9Rank: 9Rank: 9

    积分
    14941
    6#
     楼主| 发表于 2019-1-28 15:37:11 | 只看该作者
    绘制圆角矩形:
    1. public static void DrawRoundRectangle(Graphics g, Pen pen, Rectangle rect, int cornerRadius)
    2. {
    3.     using (GraphicsPath path = CreateRoundedRectanglePath(rect, cornerRadius))
    4.     {
    5.         g.DrawPath(pen, path);
    6.     }
    7. }
    8. public static void FillRoundRectangle(Graphics g, Brush brush, Rectangle rect, int cornerRadius)
    9. {
    10.     using (GraphicsPath path = CreateRoundedRectanglePath(rect, cornerRadius))
    11.     {
    12.         g.FillPath(brush, path);
    13.     }
    14. }
    15. internal static GraphicsPath CreateRoundedRectanglePath(Rectangle rect, int cornerRadius)
    16. {
    17.     GraphicsPath roundedRect = new GraphicsPath();
    18.     roundedRect.AddArc(rect.X, rect.Y, cornerRadius * 2, cornerRadius * 2, 180, 90);
    19.     roundedRect.AddLine(rect.X + cornerRadius, rect.Y, rect.Right - cornerRadius * 2, rect.Y);
    20.     roundedRect.AddArc(rect.X + rect.Width - cornerRadius * 2, rect.Y, cornerRadius * 2, cornerRadius * 2, 270, 90);
    21.     roundedRect.AddLine(rect.Right, rect.Y + cornerRadius * 2, rect.Right, rect.Y + rect.Height - cornerRadius * 2);
    22.     roundedRect.AddArc(rect.X + rect.Width - cornerRadius * 2, rect.Y + rect.Height - cornerRadius * 2, cornerRadius * 2, cornerRadius * 2, 0, 90);
    23.     roundedRect.AddLine(rect.Right - cornerRadius * 2, rect.Bottom, rect.X + cornerRadius * 2, rect.Bottom);
    24.     roundedRect.AddArc(rect.X, rect.Bottom - cornerRadius * 2, cornerRadius * 2, cornerRadius * 2, 90, 90);
    25.     roundedRect.AddLine(rect.X, rect.Bottom - cornerRadius * 2, rect.X, rect.Y + cornerRadius * 2);
    26.     roundedRect.CloseFigure();
    27.     return roundedRect;
    28. }
    复制代码

  • TA的每日心情
    开心
    2018-11-9 08:52
  • 241

    主题

    691

    帖子

    7652

    积分

    论坛元老

    Rank: 8Rank: 8

    积分
    7652
    7#
    发表于 2019-1-30 21:40:01 | 只看该作者
    在VC中用GDI+绘制角度可变的颜色渐变效果 - 寒星轩 - CSDN博客 https://blog.csdn.net/starlee/article/details/557947
  • TA的每日心情
    开心
    2018-12-28 16:25
  • 817

    主题

    1556

    帖子

    1万

    积分

    管理员

    Rank: 9Rank: 9Rank: 9

    积分
    14941
    8#
     楼主| 发表于 2019-9-12 16:56:57 | 只看该作者
    C#设置图像透明度 - 百度文库 https://wenku.baidu.com/view/e03b740c581b6bd97f19ead2.html
    您需要登录后才可以回帖 登录 | 立即注册

    本版积分规则

    QQ|Archiver|手机版|小黑屋|Silian Lighting+ ( 蜀ICP备14004521号-1 )

    GMT+8, 2024-4-20 16:05 , Processed in 1.078125 second(s), 22 queries .

    Powered by Discuz! X3.2

    © 2001-2013 Comsenz Inc.

    快速回复 返回顶部 返回列表