mmplugins/imagingplugins/codecs/BMPCodec/BMPFormat.h
branchRCL_3
changeset 50 948c7f65f6d4
parent 0 40261b775718
equal deleted inserted replaced
49:735348f59235 50:948c7f65f6d4
       
     1 // Copyright (c) 1999-2009 Nokia Corporation and/or its subsidiary(-ies).
       
     2 // All rights reserved.
       
     3 // This component and the accompanying materials are made available
       
     4 // under the terms of "Eclipse Public License v1.0"
       
     5 // which accompanies this distribution, and is available
       
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     7 //
       
     8 // Initial Contributors:
       
     9 // Nokia Corporation - initial contribution.
       
    10 //
       
    11 // Contributors:
       
    12 //
       
    13 // Description:
       
    14 //
       
    15 
       
    16 #ifndef __BMPFORMAT_H__
       
    17 #define __BMPFORMAT_H__
       
    18 
       
    19 #include <icl/imageprocessor.h>
       
    20 #include "ImageConversion.h"
       
    21 
       
    22 const TInt KBmpFileHeaderSize = 14;
       
    23 const TInt KBmpInfoHeaderV1Size = 12;
       
    24 const TInt KBmpInfoDefaultHeaderV2Size = 40;
       
    25 const TInt KBmpInfoMaxHeaderV2Size = 64;
       
    26 const TInt KBmpMaxPaletteEntries = 256;
       
    27 const TInt KBmpSizeofPaletteEntryV1 = 3;
       
    28 const TInt KBmpSizeofPaletteEntryV2 = 4;
       
    29 
       
    30 
       
    31 const TUint16 KBmpFileSignature = 'B' | ('M' << 8);
       
    32 
       
    33 class TBmpHeader : public TFrameInfo
       
    34 	{
       
    35 public:
       
    36 	enum TCompression
       
    37 		{
       
    38 		ENone,
       
    39 		EEightBppRLE,
       
    40 		EFourBppRLE,
       
    41 		EBitFields // This is valid only when used with 16-bpp and 32-bpp bitmaps.
       
    42 		};
       
    43 
       
    44 public:
       
    45 	TSize iSizeInPixels;
       
    46 	TCompression iCompression;
       
    47 	TInt iPaletteEntries; // 0 - 256
       
    48 	TInt iBitCount; // 1, 4, 8, 24, 32
       
    49 	};
       
    50 
       
    51 #endif // __BMPFORMAT_H__
       
    52