Drawing animated images using Symbian C++
S60 3rd Edition (initial release)
Drawing animated images
Applications can draw animated images on their custom UI controls using the CImageDecoder class from ICL (Image Converter Library). The source for the images can be, e.g., an animated GIF file.
ICL allows conversion of animated (multi-frame) images to CFbsBitmap bitmaps using CImageDecoder::Convert(). CImageDecoder::FrameCount() returns the total number of frames in the image file and CImageDecoder::FrameInfo(TInt aFrameNumber = 0) returns the information about each frame.
A call to CImageDecoder::Convert() must be done for each frame. The conversion is asynchronous; once completed, the requested frame is returned as a CFbsBitmap instance.
The delay between frames can be obtained from the TFrameInfo class. Using this information, each CFbsBitmap can then be drawn frame by frame to reproduce the animation.
Note: The class CPAlbImageViewerBasic has been used to draw animated images in S60 2nd Edition. However, it has been removed in S60 3rd Edition.