Symbian
Symbian OS Library

SYMBIAN OS V9.3

[Index] [Spacer] [Previous] [Next]



How to construct a multibitmap

  1. Create the original Windows bitmap using Microsoft Paintbrush, or some other bitmap drawing package.

  2. Save the bitmaps at the appropriate colour depth for the target platform. Note that increased colour depth comes at the cost of increased file size, and should be used sparingly.

  3. Open a command prompt (MSDOS box) at the location in which the bitmaps are stored.

  4. Invoke the Bitmap Converter on the command line to combine the bitmaps into a multi-bitmap file. The command line options are given in the syntax reference, and there is an example below.


See also

Bitmap Converter syntax bmconv.exe

[Top]


Example

The following command line creates the multi-bitmap file bmexmpl.mbm, and adds to it: the 4 bit grey-scale windows bitmap smiley.bmp, the 1 bit grey-scale windows bitmap hangman.bmp and the 16 colour windows bitmap abstract.bmp.

bmconv /hbmexmpl.h bmexmpl.mbm /4smiley.bmp /1hangman.bmp /c16abstract.bmp

The screen output should be:

BMCONV version 103.
Compiling...
Multiple bitmap store type: File store
Epoc file: bmexmpl.mbm

Bitmap file 1   : Smiley.bmp
Bitmap file 2   : Hangman.bmp
Bitmap file 3   : Abstract.bmp
Success.

The /hbmexmpl.h option in the command line causes the Bitmap Converter to create a C++ header file (bmexmpl.h). The header file contains an enumeration for the multibitmap, so that applications can access its stored bitmaps. The header file generated is as follows:

// bmexmpl.h
// Generated by BitmapCompiler
// Copyright (c) 1998-2000 Symbian Ltd
// 

enum TMbmBmexmpl
 {
 EMbmBmexmplSmiley,
 EMbmBmexmplHangman,
 EMbmBmexmplAbstract
 };