对半色调漫画图像进行下采样时减少摩尔纹

发布于 2024-08-30 16:11:57 字数 615 浏览 1 评论 0原文

在 iPhone 或 iPad 上进行实时变焦期间对半色调漫画图像进行下采样时,如何减少莫尔效应?

我正在写一个漫画书查看器。如果能够提供更高分辨率的图像并允许用户在阅读漫画书时放大,那就太好了。然而,我的客户不喜欢摩尔纹效果,并且如果在缩放时出现明显的摩尔纹伪影(当然确实存在),则不会允许使用此功能。

仅当修改不易察觉时,修改图像以使其不易受莫尔条纹影响才有效。模糊是被特别禁止的,任何去除人们喜爱的半色调点的东西也是被禁止的。

这些图像是黑白半色调和线条艺术。原始分辨率为 600 dpi,但我们随应用程序提供的分辨率最多只有一半,因此高度可能为 2500 像素或更低。

那么我有什么选择呢?如果我编写一个自定义下采样算法,它在这些设备上的实时速度是否足够快?我还能做其他的技巧吗?避免出现最具视觉莫尔效应的尺寸比例是否有效?

当您放大或缩小时,肯定会出现莫尔效应最严重的峰值。有没有一种方法可以计算这些点是什么,然后缩放到不那么糟糕的附近比例?

欢迎任何建议。我在图像和信号处理方面的经验很少,但很享受学习的机会。我对小波、锐度和其他术语一无所知,所以请详细一点。

编辑:

至少现在我们正在押注动态缩放。我们将支持放大到最大放大倍数,但不支持任意缩放。我希望将来能重新审视这一点。

How can I reduce moire effects when downsampling halftone comic book images during live zoom on an iPhone or iPad?

I am writing a comic book viewer. It would be nice to provide higher resolution images and allow the user to zoom in while reading the comic book. However, my client is averse to moire effects and will not allow this feature if there are noticeable moire artifacts while zooming, which of course there are.

Modifying the images to be less susceptible to moire would only work if the modifications were not perceptible. Blur was specifically prohibited, as is anything that removes the beloved halftone dots.

The images are black and white halftone and line art. The originals are 600 dpi but what we ship with the application will be half that at best, so probably 2500 pixels or less tall.

So what are my options? If I write a custom downsampling algorithm would it be fast enough for real time on these devices? Are there other tricks I can do? Would it work to just avoid the size ratios that have the most visual moire effects?

As you zoom in an out, there are definitely peaks where the moire effects are worst. Is there a way to calculate what those points are and just zoom to a nearby scale that is not as bad?

Any suggestions are welcome. I have very little experience with image and signal processing, but am enjoying the opportunity to learn. I know nothing of wavelets and acutance and other jargon, so please be verbose.

Edit:

For now at least we are punting on dynamic zoom. We will support zooming in to full magnification but not arbitrary scaling. I hope to revisit this in the future.

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

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

发布评论

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

评论(2

杀お生予夺 2024-09-06 16:11:57

莫尔效应是由于混叠而产生的。由于采样频率与信号/图像的频率内容相比太低,因此出现混叠。

我真的看不出有什么方法可以在不应用模糊的情况下避免这种情况。如果您选择的模糊滤镜足够好,您应该能够获得看起来根本不“模糊”的结果。

由于模糊很容易实现,因此我将通过模糊来实现下采样并将其显示给客户。如果他们对结果感到满意,那么一切都应该很好。

我看到的唯一其他选项是:

  1. 自定义下采样方法。除非其他人想出了一个方法,否则我认为这不是一种选择,因为您自己声称对图像/信号处理缺乏经验。

  2. 将漫画转换为矢量格式,这将产生无限缩放。

Moire effects occur due to aliasing. Aliasing occurs due to the sampling frequency being too low compared to the frequency content of the signal/image.

I can't really see any way to avoid this without applying blur. If you choose your blur filter good enough you should be able to get results which do not look "blurred" at all.

Since blur is simple to implement I would implement downsampling with blurring and show it to the customer. If they are happy with the results, then all should be well.

The only other options I see is:

  1. Custom downsampling method. Unless someone else has come up with one, I don't think it's an option, since you yourself claim to have little experience with image/signal processing.

  2. Convert the comics to vector format which would yield infinite zoom.

他不在意 2024-09-06 16:11:57

一般来说,问题很困难,但特别有趣。我怀疑是否存在一个好的简单解决方案 - 也许我们可以假设一个近乎理想的半色调(半色调点放置在完美网格中的单色图像),但这对于扫描图像几乎不起作用。

如果您对数学感兴趣和/或想要一些参考书目进行研究,这篇论文可能会有用(我还没读过)。

您也可以搜索去网算法、插件等来获取想法。

Difficult problem, in general, interesting in particular. I doubt there is a good-simple solution - perhaps if we could assume a nearly ideal halftoning (monochrome images with halftoning dots placed in a perfect grid), but this would hardly work for a scanned image.

If you are interested in the math and/or want some bibliography to research, this thesis might be useful (i haven't read it)

Also you can search for descreening algorithms, plugins, etc, to get ideas.

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