用手指显示具有刮除效果的照片

发布于 2024-09-26 14:53:26 字数 221 浏览 0 评论 0原文

我需要您的帮助来了解如何创建 iPhone 应用程序来显示带有刮擦效果的照片。

类似于这个 flash 教程中的效果 http://www.tutorial5.com/content/view/115/46/

请帮忙。 谢谢。

I need your help to know how to create an iPhone application to show a photo with SCRATCH OUT EFFECT.

Something like the effect in this flash tutorial
http://www.tutorial5.com/content/view/115/46/

Please help.
Thanks.

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

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

发布评论

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

评论(2

黒涩兲箜 2024-10-03 14:53:26

你可以看看下面关于如何创建模糊图像效果的帖子,我不认为这是最好的&禁食方法,但它可能会让您开始:

UIImage模糊

You can have a look at the following post on how to create a blurred image effect, I don't think it's the best & fasted method, but it might get you started:

UIImage blur

生寂 2024-10-03 14:53:26

您可以使用 CoreGraphics 来实现划痕效果。

可刮擦图像的 UIView 子类。
绘制可刮擦的图像,使用蒙版剪掉图像中被“刮擦”的部分。

每次用户刮擦图像时,都要更新蒙版和图像。

github 上的完整代码示例

You can implement the scratch out effect by using CoreGraphics.

Subclass UIView for the scratchable image.
Draw the scratchable image, use a mask to cut out the parts of the image that gets "scratched".

Each time the user scratches the image, make it so the mask and the image gets updated.

Full code example on github

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