Namespaces

Variants
Actions

Please note that as of October 24, 2014, the Nokia Developer Wiki will no longer be accepting user contributions, including new entries, edits and comments, as we begin transitioning to our new home, in the Windows Phone Development Wiki. We plan to move over the majority of the existing entries over the next few weeks. Thanks for all your past and future contributions.

绘制动画图片

From Wiki
Jump to: navigation, search
Article Metadata

文章
huwell 在 30 Jun 2007 创建
最后由 hamishwillee 在 15 Dec 2011 编辑
  • 设备, 软件 版本:

S60 3rd Edition


  • 详细描述:

概述

应用程序可以通过ICL(Image Converter Library)使用CImageDecoder类在自定义的UI控件中绘制动画图片,比如GIF动画图片。


解决方案

ICL允许使用CImageDecoder::Convert()将动画图片(多帧)转换为CFbsBitmap位图机型显示,我们可以通过使用CImageDecoder::FrameCount()获得图片文件的帧数,通过CImageDecoder::FrameInfo(TInt aFrameNumber = 0)返回每帧的信息、


对每帧来说都要调用CImageDecoder::Convert(),这个转换是异步的。每次完成后,完成后将返回一个CFbsBitmap实例。


帧之间的时间间隔可以通过TFrameInfo类获得,通过这些信息,我们可以依次播放CFbsBitmap以产生动画效果。


注意:在S60 2nd中可以使用CPAlbImageViewerBasic来播放动画,但在第三版中已经去除了。

This page was last modified on 15 December 2011, at 10:05.
97 page views in the last 30 days.

Was this page helpful?

Your feedback about this content is important. Let us know what you think.

 

Thank you!

We appreciate your feedback.

×