iPhone Air 游戏的像素化问题

发布于 2024-12-27 21:43:01 字数 821 浏览 0 评论 0原文

我正在开发一款适用于 Android 和 iOS 设备的跨平台手机游戏。我使用 Adob​​e Flash 与 AIR 和 AS3 来编写游戏代码。我正在 Adob​​e Illustrator 中绘制我的角色、障碍物和背景。 Flash 中的画布设置为 960x640。该角色的高度预计为屏幕高度的 1/3,即大约 213 像素高。我在 Adob​​e Illustrator 中设计的角色高度约为 900 像素。当我将角色导入 Flash 时,我为他设置了动画,使用 var player:Player = new Player() 实例化他,并使用scaleX 和scaleY 属性将他缩小到一定大小。我在台式机和 Android 手机上进行了测试,看起来非常棒。然而,当我在 iPhone 上测试它时,播放器的边缘像素化程度令人无法接受。我认为我绘制的动画远大于预期高度一定是问题所在,因此我将播放器重新绘制到正好 213 像素高,并在 iPhone 上重新测试,动画质量没有任何改善。我还尝试将 MovieClip 转换为位图矢量解释 此处 但这对动画的质量也没有影响。

iPhone 上的动画

此时,我不知所措。有人对如何避免我从 Adob​​e Illustrator 转到 Flash 再到 iPhone 时遇到的像素化问题有任何建议吗?

I am working on a cross-platform mobile game for Android and iOS devices. I am using Adobe Flash with AIR and AS3 to code the game. I am drawing my character, obstacles, and backgrounds in Adobe Illustrator. The canvas in Flash is set to 960x640. The character was intended to be 1/3 of the screen height so around 213 pixels high. I designed the character in Adobe Illustrator to be somewhere around 900 pixels high. When I imported the character into Flash I animated him, instantiated him using var player:Player = new Player(), and scaled him down to size using the scaleX and scaleY properties. I tested it out on the desktop and Android phone and it looked wonderful. However, when I tested it out on an iPhone, the player was unacceptably pixelated around the edges. I figured the fact that I drew the animation much larger than the intended height must be the problem, so I redrew the player to exactly 213 pixels high and retested on the iPhone without any improvement in the quality of the animation. I also tried converting the MovieClip to a Bitmap vector explained here but that also had no effect on the quality of the animation.

animation on an iPhone

At this point, I am at a loss. Does anyone have any suggestions on how to avoid this pixelation issue that I am experiencing when going from Adobe Illustrator to Flash to the iPhone?

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

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

发布评论

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

评论(3

丑疤怪 2025-01-03 21:43:01

为了获得更优化的 iPhone 路线,您可能需要考虑将动画创建为一组位图图形,即使用 PhotoShop 将它们创建为 png 文件,并按照您希望它们显示的大小。

通过这样做,您将节省 Flash 创建平滑位图时的 CPU 活动

For a more optimised iPhone route you might want to consider creating your animation as a set of bitmap graphics, i.e. create them as png files using PhotoShop at the size you want them to be displayed at.

By doing this you'll save CPU activity in having Flash create smoothed bitmaps

心的位置 2025-01-03 21:43:01

尝试将位图的平滑设置为 true。

yourbitmap.smoothing = true;

Try to set smoothing to true for your bitmap.

yourbitmap.smoothing = true;

念﹏祤嫣 2025-01-03 21:43:01

我对你的问题有一些解决方案。

  1. 角色不应有黑色轮廓。使用渐变以获得更好的效果。
  2. 颜色组合应该适合你的性格。你使用哪个背景和其他东西。

I have some solutions for your problems.

  1. Character should not have dark outlines. Use gradients for better effects.
  2. Color combination should understand for your character. which background you use and other things.
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文