在缩放的 Flex 应用程序中平滑鼠标悬停图像?

发布于 2024-08-30 14:30:41 字数 385 浏览 1 评论 0原文

我有一个弹性应用程序,我正在使用 systemManager.stage.scaleMode=StageScaleMode.NO_BORDER 进行缩放;在大多数情况下,除了我的位图数据(主要是来自设计师的 png)之外,它运行良好。

我可以将 mx:image 标签设置为 smoothBitmapContent=true,这对于除鼠标悬停对象之外的所有内容都非常有效。当我将鼠标悬停时,源将从一个嵌入图像更改为另一嵌入图像。我已经尝试了几个(很多)在线“smoothimage”类,并尝试编写自己的类,我尝试每次有机会重置 smoothBitmapContent 但仍然没有骰子。似乎因为我在应用程序级别进行缩放,所以翻出的位图在渲染时没有得到平滑。

如何让事情保持顺利?也许有一个标志告诉 Flex 在缩放时平滑内容?

I have a flex app I am scaling using systemManager.stage.scaleMode=StageScaleMode.NO_BORDER; for the most part it works well except for my bitmap data (mostly png's from the designers).

I can set the mx:image tags to smoothBitmapContent=true and that works great for everything except my mouseover objects. When I do a mouseover, the source is being changed from one embedded image to another embedded image. I have tried several (many) online "smoothimage" classes, and tried to write my own, I have tried to reset smoothBitmapContent every chance I get but still no dice. It seems to mee that because I am scaling at the app level, that the flopped out bitmap is not getting smoothed when it renders.

How to keep things smooth? Perhaps there is a flag to tell Flex to smooth stuff when it scales it?

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

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

发布评论

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

评论(1

长途伴 2024-09-06 14:30:41

因此,简单的答案(对我有用)不是将 image.source 从一个嵌入的 png 更改为另一个,而是使用两个图像并在两个图像之间翻转 image.visible...当然,这会添加两个额外的对象但由于某种原因,它们都保持平滑和缩放的方式,而与以前一样,切换源会从平滑变为锯齿状且难以阅读。

乔什

So the easy answer (that works for me) was to instead of changing the image.source from one embedded png to another, was to use two images and flip flop image.visible between the two... Granted that adds two extra objects to the screen, But for some reason they all stay smoothed and scaled that way, where as before switching sources was going from smooth to jaggidy and un-readable.

Josh

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