图像边缘检测和平滑?

发布于 2024-12-28 22:24:17 字数 237 浏览 5 评论 0原文

我有一个位图(C# 语言),其中包含透明背景上一个人的剪影。轮廓是一种特定的色调或颜色,但强度不同。

我试图弄清楚轮廓的边缘有多光滑,如果可能的话,去除不属于轮廓的伪影。目标是获得人物的平滑(不模糊)表现,尽可能不像素化且无伪影。

任何人都可以建议一种方法(我正在使用 C# .NET 4.0)来完成此任务吗?我正在考虑某种 3 遍方法——边缘检测、异常值或伪影去除,然后平滑,但我以前从未做过这种事情。

谢谢!

I have a Bitmap (in C#) which contains a silhouette of a single person on a transparent background. The silhouette is a particular hue or color, but of varying intensities.

I'm trying to figure out how smooth the edges of the silhouette, and if possible remove artifacts that are not part of the silhouette. The goal is to get a nice smooth (not blurred) representation of the person, as un-pixelated and artifact free as possible.

Can anyone suggest an approach (I'm working in C# .NET 4.0) to accomplish this? I was thinking some sort of 3 pass approach- edge detection, outlier or artifact removal and then smoothing, but I have never done this kind of thing before.

Thanks!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

朮生 2025-01-04 22:24:17

您可以创建边缘检测算法。这取决于你的照片有多好,结果很快就会出来。

边缘检测后,您可以尝试在检测到的边界周围创建多边形。多边形具有使用任何计算的不透明蒙版的最大分辨率。
如果你的图像分辨率良好,没有太多噪音(如物体或头发),那么它应该是一个很酷的作品。

face border

也许这个项目可以帮助您的项目:
http://www.codeproject.com/Articles/9727/图像处理实验室 C

问候

You can create an edge detection algorith. It depends on how good your pictures are, the result will be available quickly.

After edge detection you can try to create the polygon around the detected border. The polygon has maximum resolution to use any calculated opacity mask.
If your images are in good resolution without a lot of noises (like objects or hair) it should be a cool work.

face border

Perhaps this project helps you for your project:
http://www.codeproject.com/Articles/9727/Image-Processing-Lab-in-C

Regards

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文