epoc32/include/icl/imagecodecdata.h
author William Roberts <williamr@symbian.org>
Wed, 31 Mar 2010 12:33:34 +0100
branchSymbian3
changeset 4 837f303aceeb
parent 2 2fe1408b6811
permissions -rw-r--r--
Current Symbian^3 public API header files (from PDK 3.0.h)
This is the epoc32/include tree with the "platform" subtrees removed, and
all but a selected few mbg and rsg files removed.
williamr@2
     1
// Copyright (c) 2001-2009 Nokia Corporation and/or its subsidiary(-ies).
williamr@2
     2
// All rights reserved.
williamr@2
     3
// This component and the accompanying materials are made available
williamr@4
     4
// under the terms of "Eclipse Public License v1.0"
williamr@2
     5
// which accompanies this distribution, and is available
williamr@4
     6
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
williamr@2
     7
//
williamr@2
     8
// Initial Contributors:
williamr@2
     9
// Nokia Corporation - initial contribution.
williamr@2
    10
//
williamr@2
    11
// Contributors:
williamr@2
    12
//
williamr@2
    13
// Description:
williamr@2
    14
// ImageCodecData.h - data used by standard codecs
williamr@2
    15
// 
williamr@2
    16
//
williamr@2
    17
williamr@2
    18
/**
williamr@2
    19
@file
williamr@2
    20
@publishedAll
williamr@2
    21
@released
williamr@2
    22
*/
williamr@2
    23
williamr@2
    24
williamr@2
    25
#ifndef __IMAGECODECDATA_H__
williamr@2
    26
#define __IMAGECODECDATA_H__
williamr@2
    27
williamr@2
    28
#include <gdi.h>
williamr@2
    29
#include <ezcompressor.h>
williamr@2
    30
#include <icl/imagedata.h>
williamr@2
    31
williamr@2
    32
class CFrameImageData;
williamr@2
    33
williamr@2
    34
williamr@2
    35
// Identification UIDs for TFrameDataBlock-derived classes
williamr@2
    36
williamr@2
    37
/** GIF image descriptor.
williamr@2
    38
*/
williamr@2
    39
const TUid KGIFImageDescriptorUid = { 0x101F45E4 };
williamr@2
    40
/** GIF colour table
williamr@2
    41
*/
williamr@2
    42
const TUid KGIFColorTableUid = { 0x101F7C0A };
williamr@2
    43
/** GIF compression type LZW information.
williamr@2
    44
*/
williamr@2
    45
const TUid KGIFLZWInfoUid = { 0x101F45E5 };
williamr@2
    46
/** GIF image controller.
williamr@2
    47
*/
williamr@2
    48
const TUid KGIFImageControlUid = { 0x101F45E6 };
williamr@2
    49
/** GIF loop iterations.
williamr@2
    50
*/
williamr@2
    51
const TUid KGIFLoopIterationsUid = { 0x102834A6 };
williamr@2
    52
/** MBM decode data.
williamr@2
    53
*/
williamr@2
    54
const TUid KMBMDecodeDataUid = { 0x101F45E0 };
williamr@2
    55
/** MBM encode data.
williamr@2
    56
*/
williamr@2
    57
const TUid KMBMEncodeDataUid = { 0x101F45E9 };
williamr@2
    58
/** PNG encode data.
williamr@2
    59
*/
williamr@2
    60
const TUid KPNGEncodeDataUid = { 0x101F460A };
williamr@2
    61
/** TIFF image data.
williamr@2
    62
*/
williamr@2
    63
const TUid KTIFFImageDataUid = { 0x101F45E8 };
williamr@2
    64
williamr@2
    65
williamr@2
    66
williamr@2
    67
//Identification UIDs for TImageDataBlock-derived classes
williamr@2
    68
williamr@2
    69
/** BMP image data.
williamr@2
    70
*/
williamr@2
    71
const TUid KBMPImageDataUid = { 0x101F45BF };
williamr@2
    72
/** BMP compression.
williamr@2
    73
*/
williamr@2
    74
const TUid KBMPCompressionUid = { 0x101F45E3 };
williamr@2
    75
/** JPG image data.
williamr@2
    76
*/
williamr@2
    77
const TUid KJPGImageDataUid = { 0x101F45DA };
williamr@2
    78
/** JPG Q table.
williamr@2
    79
*/
williamr@2
    80
const TUid KJPGQTableUid = { 0x101F45E1 };
williamr@2
    81
/** JPG comment.
williamr@2
    82
*/
williamr@2
    83
const TUid KJPGCommentUid = { 0x101F45E2 };
williamr@2
    84
/** GIF background colour.
williamr@2
    85
*/
williamr@2
    86
const TUid KGIFBackgroundColorUid = { 0x101F45DE };
williamr@2
    87
/** GIF comment.
williamr@2
    88
*/
williamr@2
    89
const TUid KGIFCommentUid = { 0x101F45E7 };
williamr@2
    90
williamr@2
    91
/** Max number of GIF palatte entries
williamr@2
    92
*/
williamr@2
    93
const TInt KGifColorTableMaxEntries = 256;
williamr@2
    94
williamr@2
    95
/**
williamr@2
    96
@publishedAll
williamr@2
    97
@released
williamr@2
    98
williamr@2
    99
BMP specific image data variant which holds bits per pixel info.
williamr@2
   100
It is only used when configuring the BMP encoder.
williamr@2
   101
If the Symbian bitmap encoder (0x101F45AE) is supplied then encoder specific defaults 
williamr@2
   102
are used if this object is not presented to the conversion process.
williamr@2
   103
The default bitmap colour depth is 24-bit.
williamr@2
   104
@see CImageEncoder
williamr@2
   105
@see CFrameImageData
williamr@2
   106
*/
williamr@2
   107
class TBmpImageData : public TImageDataBlock
williamr@2
   108
	{
williamr@2
   109
public:
williamr@2
   110
	IMPORT_C TBmpImageData();
williamr@2
   111
williamr@2
   112
public:
williamr@2
   113
	/** The number of bits/pixel.
williamr@2
   114
	*/
williamr@2
   115
	TInt iBitsPerPixel;
williamr@2
   116
williamr@2
   117
private:
williamr@2
   118
	TImageDataBlock* DuplicateL(CFrameImageData& aFrameImageData) const;
williamr@2
   119
	};
williamr@2
   120
williamr@2
   121
/**
williamr@2
   122
@publishedAll
williamr@2
   123
@released
williamr@2
   124
williamr@2
   125
BMP specific image data variant which holds compression info.
williamr@2
   126
It is only used when extracting info from the BMP decoder.
williamr@2
   127
*/
williamr@2
   128
class TBmpCompression : public TImageDataBlock
williamr@2
   129
	{
williamr@2
   130
public:
williamr@2
   131
	IMPORT_C TBmpCompression();
williamr@2
   132
williamr@2
   133
public:
williamr@2
   134
	/**
williamr@2
   135
	Flag reflecting the compression type.
williamr@2
   136
	*/
williamr@2
   137
	enum TCompression
williamr@2
   138
	{
williamr@2
   139
	/** No compression used.
williamr@2
   140
	*/
williamr@2
   141
	ENone,
williamr@2
   142
williamr@2
   143
	/** Eight bits per pixel run length encoding.
williamr@2
   144
	*/
williamr@2
   145
	EEightBppRLE,
williamr@2
   146
williamr@2
   147
	/** Four bits per pixel run length encoding.
williamr@2
   148
	*/
williamr@2
   149
	EFourBppRLE,
williamr@2
   150
williamr@2
   151
	/** Compression using bit fields.
williamr@2
   152
	*/
williamr@2
   153
	EBitFields
williamr@2
   154
	};
williamr@2
   155
williamr@2
   156
public:
williamr@2
   157
	/**
williamr@2
   158
	@see enum TCompression
williamr@2
   159
williamr@2
   160
	The type of compression used
williamr@2
   161
	*/
williamr@2
   162
	TCompression iCompression;
williamr@2
   163
williamr@2
   164
private:
williamr@2
   165
	TImageDataBlock* DuplicateL(CFrameImageData& aFrameImageData) const;
williamr@2
   166
	};
williamr@2
   167
williamr@2
   168
williamr@2
   169
/**
williamr@2
   170
@publishedAll
williamr@2
   171
@released
williamr@2
   172
williamr@2
   173
JPEG specific image data variant which holds color sampling and quality
williamr@2
   174
factor information.
williamr@2
   175
williamr@2
   176
It can be used with both the JPEG decoder and encoder.
williamr@2
   177
*/
williamr@2
   178
class TJpegImageData : public TImageDataBlock
williamr@2
   179
	{
williamr@2
   180
public:
williamr@2
   181
	/**
williamr@2
   182
	Flag reflecting the color sampling type.
williamr@2
   183
	*/
williamr@2
   184
	enum TColorSampling
williamr@2
   185
		{
williamr@2
   186
		/** Monochrome.
williamr@2
   187
		*/
williamr@2
   188
		EMonochrome,
williamr@2
   189
williamr@2
   190
		/** Horizontal and vertical chrominance decimation.
williamr@2
   191
		*/
williamr@2
   192
		EColor420,
williamr@2
   193
williamr@2
   194
		/** Horizontal chrominance decimation.
williamr@2
   195
		*/
williamr@2
   196
		EColor422,
williamr@2
   197
williamr@2
   198
		/** No chrominance decimation.
williamr@2
   199
		*/
williamr@2
   200
		EColor444
williamr@2
   201
		};
williamr@2
   202
public:
williamr@2
   203
	IMPORT_C TJpegImageData(); // Defaults to EColor420 and 75
williamr@2
   204
williamr@2
   205
public:
williamr@2
   206
	/**
williamr@2
   207
	@see enum TColorSampling
williamr@2
   208
williamr@2
   209
	The color sampling scheme to use.
williamr@2
   210
	*/
williamr@2
   211
	TColorSampling iSampleScheme;
williamr@2
   212
williamr@2
   213
	/** The quality factor. 
williamr@2
   214
	
williamr@2
   215
	This represents the current allowable percentage level of degradation when compressing the image 
williamr@2
   216
	data.
williamr@2
   217
williamr@2
   218
	The range is 0 to 100 inclusive.
williamr@2
   219
	*/
williamr@2
   220
	TInt iQualityFactor; 
williamr@2
   221
williamr@2
   222
private:
williamr@2
   223
	TImageDataBlock* DuplicateL(CFrameImageData& aFrameImageData) const;
williamr@2
   224
	};
williamr@2
   225
williamr@2
   226
/** The number of JPEG Q table entries.
williamr@2
   227
williamr@2
   228
@see class TJpegQTable
williamr@2
   229
*/
williamr@2
   230
const TInt KJpgQTableEntries = 64;
williamr@2
   231
williamr@2
   232
/**
williamr@2
   233
@publishedAll
williamr@2
   234
@released
williamr@2
   235
williamr@2
   236
JPEG specific image data variant which holds QTable info.
williamr@2
   237
williamr@2
   238
It can be used with both the JPEG decoder and encoder.
williamr@2
   239
*/
williamr@2
   240
class TJpegQTable : public TImageDataBlock
williamr@2
   241
	{
williamr@2
   242
public:
williamr@2
   243
	/**
williamr@2
   244
	Flag reflecting the type of Q or quantization table.
williamr@2
   245
	*/
williamr@2
   246
	enum TQTableIndex
williamr@2
   247
		{
williamr@2
   248
		/** Luminance table.
williamr@2
   249
		*/
williamr@2
   250
		ELumaTable = 0,
williamr@2
   251
williamr@2
   252
		/** Chrominance table.
williamr@2
   253
		*/
williamr@2
   254
		EChromaTable = 1
williamr@2
   255
		};
williamr@2
   256
public:
williamr@2
   257
	IMPORT_C TJpegQTable();
williamr@2
   258
williamr@2
   259
public:
williamr@2
   260
	/** The type of Q table. */
williamr@2
   261
	TInt iTableIndex;
williamr@2
   262
williamr@2
   263
	/** The number of entries in the Q table. */
williamr@2
   264
	TBuf8<KJpgQTableEntries> iEntries;
williamr@2
   265
williamr@2
   266
private:
williamr@2
   267
	TImageDataBlock* DuplicateL(CFrameImageData& aFrameImageData) const;
williamr@2
   268
	};
williamr@2
   269
williamr@2
   270
/**
williamr@2
   271
@publishedAll
williamr@2
   272
@released
williamr@2
   273
williamr@2
   274
JPEG specific image data variant which holds JPEG comment information.
williamr@2
   275
williamr@2
   276
It can be used with both the JPEG decoder and encoder.
williamr@2
   277
*/
williamr@2
   278
class TJpegComment : public TImageDataBlock
williamr@2
   279
	{
williamr@2
   280
public:
williamr@2
   281
	IMPORT_C TJpegComment();
williamr@2
   282
williamr@2
   283
public:
williamr@2
   284
	/** The JPEG comment associated with the JPEG image.
williamr@2
   285
	*/
williamr@2
   286
	HBufC8* iComment;
williamr@2
   287
williamr@2
   288
private:
williamr@2
   289
	TImageDataBlock* DuplicateL(CFrameImageData& aFrameImageData) const;
williamr@2
   290
	};
williamr@2
   291
williamr@2
   292
williamr@2
   293
/**
williamr@2
   294
@publishedAll
williamr@2
   295
@released
williamr@2
   296
williamr@2
   297
GIF specific image data variant which holds background color info.
williamr@2
   298
williamr@2
   299
It can only be used with the GIF decoder (the encoder is not configurable).
williamr@2
   300
*/
williamr@2
   301
class TGifBackgroundColor : public TImageDataBlock
williamr@2
   302
	{
williamr@2
   303
public:
williamr@2
   304
	IMPORT_C TGifBackgroundColor();
williamr@2
   305
williamr@2
   306
public:
williamr@2
   307
	/** The background colour as an index.
williamr@2
   308
	*/
williamr@2
   309
	TInt iBackgroundColorIndex;
williamr@2
   310
williamr@2
   311
	/** The background colour as an RGB value.
williamr@2
   312
	*/
williamr@2
   313
	TRgb iBackgroundColor;
williamr@2
   314
williamr@2
   315
private:
williamr@2
   316
	TImageDataBlock* DuplicateL(CFrameImageData& aFrameImageData) const;
williamr@2
   317
	};
williamr@2
   318
williamr@2
   319
/**
williamr@2
   320
GIF specific frame data variant which holds image descriptor information.
williamr@2
   321
williamr@2
   322
It can only be used with the GIF decoder (the encoder is not configurable).
williamr@2
   323
williamr@2
   324
@publishedAll
williamr@2
   325
@released
williamr@2
   326
*/
williamr@2
   327
class TGifImageDescriptor : public TFrameDataBlock
williamr@2
   328
	{
williamr@2
   329
public:
williamr@2
   330
	IMPORT_C TGifImageDescriptor();
williamr@2
   331
williamr@2
   332
public:
williamr@2
   333
	/** A boolean indicating if the frame has its own local colour map. ETrue if it does, otherwise
williamr@2
   334
    EFalse.
williamr@2
   335
	*/
williamr@2
   336
	TBool iLocalColorMap;
williamr@2
   337
williamr@2
   338
	/** A boolean indicating if the frame's local colour map is sorted in priority order. ETrue if
williamr@2
   339
    it is, otherwise EFalse.
williamr@2
   340
	*/
williamr@2
   341
	TBool iSortedLocalMap;
williamr@2
   342
williamr@2
   343
	/** A boolean indicating if the image is interlaced. ETrue if the image is interlaced.
williamr@2
   344
	*/
williamr@2
   345
	TBool iInterlaced;
williamr@2
   346
williamr@2
   347
private:
williamr@2
   348
	TFrameDataBlock* DuplicateL(CFrameImageData& aFrameImageData) const;
williamr@2
   349
	};
williamr@2
   350
williamr@2
   351
/**
williamr@2
   352
@publishedAll
williamr@2
   353
@released
williamr@2
   354
williamr@2
   355
GIF specific frame data for saving a frame local color map (palette).
williamr@2
   356
*/
williamr@2
   357
class TGifColorTable : public TFrameDataBlock
williamr@2
   358
	{
williamr@2
   359
public:
williamr@2
   360
	IMPORT_C TGifColorTable();
williamr@2
   361
   
williamr@2
   362
public:
williamr@2
   363
    /** The palette */
williamr@2
   364
	TRgb iPalette[KGifColorTableMaxEntries];
williamr@2
   365
williamr@2
   366
private:
williamr@2
   367
	TFrameDataBlock* DuplicateL(CFrameImageData& aFrameImageData) const;
williamr@2
   368
	};
williamr@2
   369
williamr@2
   370
/**
williamr@2
   371
@publishedAll
williamr@2
   372
@released
williamr@2
   373
williamr@2
   374
GIF specific frame data variant which holds LZW compression information.
williamr@2
   375
williamr@2
   376
It can only be used with the GIF decoder (the encoder is not configurable).
williamr@2
   377
*/
williamr@2
   378
class TGifLZWInfo : public TFrameDataBlock
williamr@2
   379
	{
williamr@2
   380
public:
williamr@2
   381
	IMPORT_C TGifLZWInfo();
williamr@2
   382
williamr@2
   383
public:
williamr@2
   384
	/** The initial number of bits used in LZW compression. 
williamr@2
   385
	*/
williamr@2
   386
	TInt iInitialCodeLength;
williamr@2
   387
williamr@2
   388
	/** The size of compressed frame.
williamr@2
   389
	*/
williamr@2
   390
	TInt iCompressedBytes;
williamr@2
   391
williamr@2
   392
private:
williamr@2
   393
	TFrameDataBlock* DuplicateL(CFrameImageData& aFrameImageData) const;
williamr@2
   394
	};
williamr@2
   395
williamr@2
   396
/**
williamr@2
   397
@publishedAll
williamr@2
   398
@released
williamr@2
   399
williamr@2
   400
GIF specific frame data variant which holds GIF image control information.
williamr@2
   401
williamr@2
   402
It can only be used with the GIF decoder (the encoder is not configurable).
williamr@2
   403
*/
williamr@2
   404
class TGifImageControl : public TFrameDataBlock
williamr@2
   405
	{
williamr@2
   406
public:
williamr@2
   407
	/**
williamr@2
   408
	Flag reflecting how the previous frame is handled when the next frame is drawn.
williamr@2
   409
	*/
williamr@2
   410
	enum TDisposalMethod
williamr@2
   411
		{
williamr@2
   412
		/** No method set.
williamr@2
   413
		*/
williamr@2
   414
		ENone = 0,
williamr@2
   415
williamr@2
   416
		/** Leave the previous frame in place.
williamr@2
   417
		*/
williamr@2
   418
		ELeaveInPlace = 1,
williamr@2
   419
williamr@2
   420
		/** Restore to the backgound colour.
williamr@2
   421
		*/
williamr@2
   422
		ERestoreToBackground = 2,
williamr@2
   423
williamr@2
   424
		/** Restore the previous frame.
williamr@2
   425
		*/
williamr@2
   426
		ERestoreToPrevious = 3
williamr@2
   427
		};
williamr@2
   428
williamr@2
   429
public:
williamr@2
   430
	IMPORT_C TGifImageControl();
williamr@2
   431
williamr@2
   432
public:
williamr@2
   433
	/** The interval between display of successive frames in units of 1/100 second.
williamr@2
   434
	*/
williamr@2
   435
	TInt iDelayTimeInCentiseconds;
williamr@2
   436
williamr@2
   437
	/** The colour index to be used for transparency.
williamr@2
   438
	*/
williamr@2
   439
	TInt iTransparentColorIndex;
williamr@2
   440
williamr@2
   441
	/** A flag indicating if user input is required before display of next frame.
williamr@2
   442
	*/
williamr@2
   443
	TBool iUserInputFlag;
williamr@2
   444
williamr@2
   445
	/** The frame disposal method for multiframe images.
williamr@2
   446
	*/
williamr@2
   447
	TDisposalMethod iDisposalMethod;
williamr@2
   448
williamr@2
   449
private:
williamr@2
   450
	TFrameDataBlock* DuplicateL(CFrameImageData& aFrameImageData) const;
williamr@2
   451
	};
williamr@2
   452
williamr@2
   453
/**
williamr@2
   454
@publishedAll
williamr@2
   455
@released
williamr@2
   456
williamr@2
   457
GIF specific image data variant which holds GIF comment info.
williamr@2
   458
williamr@2
   459
It can only be used with the GIF decoder (the encoder is not configurable).
williamr@2
   460
*/
williamr@2
   461
class TGifComment : public TImageDataBlock
williamr@2
   462
	{
williamr@2
   463
public:
williamr@2
   464
	IMPORT_C TGifComment();
williamr@2
   465
williamr@2
   466
public:
williamr@2
   467
	/** The comment associated with the GIF image. 
williamr@2
   468
	*/
williamr@2
   469
	HBufC8* iComment;
williamr@2
   470
williamr@2
   471
private:
williamr@2
   472
	TImageDataBlock* DuplicateL(CFrameImageData& aFrameImageData) const;
williamr@2
   473
	};
williamr@2
   474
williamr@2
   475
/**
williamr@2
   476
@publishedAll
williamr@2
   477
@released
williamr@2
   478
williamr@2
   479
GIF specific image data variant which holds Netscape 2.0 Application Extension block loop iterations value
williamr@2
   480
williamr@2
   481
It can only be used with the GIF decoder (the encoder is not configurable).
williamr@2
   482
*/
williamr@2
   483
class TGifLoopIterations : public TImageDataBlock
williamr@2
   484
    {
williamr@2
   485
public:
williamr@2
   486
    IMPORT_C TGifLoopIterations();
williamr@2
   487
williamr@2
   488
public:
williamr@2
   489
    /** The number of times to loop an animated GIF
williamr@2
   490
    */
williamr@2
   491
    TInt iLoopIterations;
williamr@2
   492
williamr@2
   493
private:
williamr@2
   494
    TImageDataBlock* DuplicateL(CFrameImageData& aFrameImageData) const;
williamr@2
   495
    };
williamr@2
   496
williamr@2
   497
// Mbm compression data. (Decoder only)
williamr@2
   498
/**
williamr@2
   499
@publishedAll
williamr@2
   500
@released
williamr@2
   501
williamr@2
   502
MBM specific frame data variant which holds frame data information.
williamr@2
   503
williamr@2
   504
It can only be used with the MBM decoder.
williamr@2
   505
*/
williamr@2
   506
class TMbmDecodeData : public TFrameDataBlock
williamr@2
   507
	{
williamr@2
   508
public:
williamr@2
   509
	IMPORT_C TMbmDecodeData();
williamr@2
   510
williamr@2
   511
public:
williamr@2
   512
	/** A flag indicating if RLE compression is used. 
williamr@2
   513
	*/
williamr@2
   514
	TBool iCompressed;
williamr@2
   515
williamr@2
   516
	/** The uncompressed frame size in bytes.
williamr@2
   517
	*/
williamr@2
   518
	TInt iImageDataSizeInBytes;
williamr@2
   519
williamr@2
   520
private:
williamr@2
   521
	TFrameDataBlock* DuplicateL(CFrameImageData& aFrameImageData) const;
williamr@2
   522
	};
williamr@2
   523
williamr@2
   524
williamr@2
   525
// Mbm display mode. (Encoder only)
williamr@2
   526
/**
williamr@2
   527
@publishedAll
williamr@2
   528
@released
williamr@2
   529
williamr@2
   530
MBM specific image data variant which holds frame data information.
williamr@2
   531
williamr@2
   532
It can only be used with the MBM encoder.
williamr@2
   533
*/
williamr@2
   534
class TMbmEncodeData : public TFrameDataBlock
williamr@2
   535
	{
williamr@2
   536
public:
williamr@2
   537
	IMPORT_C TMbmEncodeData();
williamr@2
   538
williamr@2
   539
public:
williamr@2
   540
	/** The display mode.
williamr@2
   541
	*/
williamr@2
   542
	TDisplayMode iDisplayMode;
williamr@2
   543
williamr@2
   544
private:
williamr@2
   545
	TFrameDataBlock* DuplicateL(CFrameImageData& aFrameImageData) const;
williamr@2
   546
	};
williamr@2
   547
williamr@2
   548
williamr@2
   549
/**
williamr@2
   550
@publishedAll
williamr@2
   551
@released
williamr@2
   552
williamr@2
   553
PNG specific frame data variant which holds PNG encoding information.
williamr@2
   554
williamr@2
   555
It can only be used with the PNG encoder.
williamr@2
   556
*/
williamr@2
   557
class TPngEncodeData : public TFrameDataBlock
williamr@2
   558
	{
williamr@2
   559
public:
williamr@2
   560
	// Same values as CEZCompressor
williamr@2
   561
	/**
williamr@2
   562
	A flag reflecting the level of compression used.
williamr@2
   563
	*/
williamr@2
   564
	enum TPngCompressLevel
williamr@2
   565
		{
williamr@2
   566
		/**
williamr@2
   567
		Default level of compression used.
williamr@2
   568
		*/
williamr@2
   569
		EDefaultCompression = Z_DEFAULT_COMPRESSION,
williamr@2
   570
williamr@2
   571
		/** No compression used.
williamr@2
   572
		*/
williamr@2
   573
		ENoCompression = Z_NO_COMPRESSION,
williamr@2
   574
williamr@2
   575
		/** Optimise compression for speed.
williamr@2
   576
		*/
williamr@2
   577
		EBestSpeed = Z_BEST_SPEED,
williamr@2
   578
williamr@2
   579
		/** Optimise compression for size.
williamr@2
   580
		*/
williamr@2
   581
		EBestCompression = Z_BEST_COMPRESSION
williamr@2
   582
		};
williamr@2
   583
public:
williamr@2
   584
	IMPORT_C TPngEncodeData();
williamr@2
   585
williamr@2
   586
public:
williamr@2
   587
	/** The number of bits per pixel.
williamr@2
   588
	*/
williamr@2
   589
	TInt iBitsPerPixel;
williamr@2
   590
williamr@2
   591
	/** A flag indicating if the image is color or grayscale.
williamr@2
   592
	*/
williamr@2
   593
	TBool iColor;
williamr@2
   594
williamr@2
   595
	/** A flag indicating use of a palette or RGB.
williamr@2
   596
	*/
williamr@2
   597
	TBool iPaletted;
williamr@2
   598
williamr@2
   599
	/** The level of compression to apply.
williamr@2
   600
	*/
williamr@2
   601
	TPngCompressLevel iLevel;
williamr@2
   602
williamr@2
   603
private:
williamr@2
   604
	TFrameDataBlock* DuplicateL(CFrameImageData& aFrameImageData) const;
williamr@2
   605
	};
williamr@2
   606
williamr@2
   607
/**
williamr@2
   608
@publishedAll
williamr@2
   609
@released
williamr@2
   610
williamr@2
   611
TIFF specific frame data variant. Holds colour sampling and quality factor information.
williamr@2
   612
williamr@2
   613
It can only be used with the TIFF decoder.
williamr@2
   614
*/
williamr@2
   615
class TTiffImageData : public TFrameDataBlock
williamr@2
   616
	{
williamr@2
   617
public:
williamr@2
   618
	IMPORT_C TTiffImageData();
williamr@2
   619
williamr@2
   620
public:
williamr@2
   621
	/** The new subfile type.
williamr@2
   622
	*/
williamr@2
   623
	TUint32				iNewSubfileType;
williamr@2
   624
williamr@2
   625
	/** The frame size in pixels.
williamr@2
   626
	*/
williamr@2
   627
	TSize				iSizeInPixels;
williamr@2
   628
williamr@2
   629
	/** The number of bits per sample.
williamr@2
   630
	*/
williamr@2
   631
	TInt				iBitsPerSample;
williamr@2
   632
williamr@2
   633
	/** The number of samples per pixel.
williamr@2
   634
	*/
williamr@2
   635
	TInt				iSamplesPerPixel;
williamr@2
   636
williamr@2
   637
	/** The compression setting.
williamr@2
   638
	*/
williamr@2
   639
	TInt				iCompression;
williamr@2
   640
williamr@2
   641
	/** T4 options as per the "Standardization of Group 3 facsimile apparatus for document 
williamr@2
   642
	transmission, Recommendation T.4, Volume VII, Fascicle VII.3".
williamr@2
   643
	*/
williamr@2
   644
	TInt				iT4Options;
williamr@2
   645
williamr@2
   646
	/** T6 options as per the "Facsimile Coding Schemes and Coding Control Functions for Group 4 
williamr@2
   647
	Facsimile Apparatus, Recommendation T.6, Volume VII, Fascicle VII.3".
williamr@2
   648
	*/
williamr@2
   649
	TInt				iT6Options;
williamr@2
   650
williamr@2
   651
	/** The photometric interpretation setting.
williamr@2
   652
	*/
williamr@2
   653
	TInt				iPhotometricInterpretation;
williamr@2
   654
williamr@2
   655
	/** The fill order.
williamr@2
   656
	*/
williamr@2
   657
	TInt				iFillOrder;
williamr@2
   658
williamr@2
   659
	/** The frame width in twips.
williamr@2
   660
	*/
williamr@2
   661
	TReal				iWidthInTwips;
williamr@2
   662
williamr@2
   663
	/** The frame height in twips.
williamr@2
   664
	*/
williamr@2
   665
	TReal				iHeightInTwips;
williamr@2
   666
williamr@2
   667
	/** The number of rows per strip.
williamr@2
   668
	*/
williamr@2
   669
	TInt				iRowsPerStrip;
williamr@2
   670
williamr@2
   671
	/** The number of TTiffImageStrips.
williamr@2
   672
	*/
williamr@2
   673
	TInt				iNumStrips;
williamr@2
   674
williamr@2
   675
	/** An array of TTiffImageStrips.
williamr@2
   676
	*/
williamr@2
   677
	HBufC8*				iStripInfo;
williamr@2
   678
williamr@2
   679
private:
williamr@2
   680
	TFrameDataBlock* DuplicateL(CFrameImageData& aFrameImageData) const;
williamr@2
   681
	};
williamr@2
   682
williamr@2
   683
// Identification UIDs for image types.
williamr@2
   684
williamr@2
   685
/** Image type BMP.
williamr@2
   686
*/
williamr@2
   687
const TUid KImageTypeBMPUid = {0x101F45B0};
williamr@2
   688
/** Image type GIF.
williamr@2
   689
*/
williamr@2
   690
const TUid KImageTypeGIFUid = {0x101F45B3};
williamr@2
   691
/** Image type WMF.
williamr@2
   692
*/
williamr@2
   693
const TUid KImageTypeWMFUid = {0x101F45BA};
williamr@2
   694
/** Image type WMF subtype Std.
williamr@2
   695
*/
williamr@2
   696
const TUid KImageTypeWMFSubTypeStdUid = {0x101F45BB};
williamr@2
   697
/** Image type WMF subtype Apm.
williamr@2
   698
*/
williamr@2
   699
const TUid KImageTypeWMFSubTypeApmUid = {0x101F45BC};
williamr@2
   700
/** Image type WMF subtype Clp.
williamr@2
   701
*/
williamr@2
   702
const TUid KImageTypeWMFSubTypeClpUid = {0x101F45BD};
williamr@2
   703
/** Image type TIFF.
williamr@2
   704
*/
williamr@2
   705
const TUid KImageTypeTIFFUid = {0x101F45C4};
williamr@2
   706
/** Image type TIFF subtype LittleEndian.
williamr@2
   707
*/
williamr@2
   708
const TUid KImageTypeTIFFSubTypeLittleEndianUid = {0x101F45C5};
williamr@2
   709
/** Image type TIFF subtype BigEndian.
williamr@2
   710
*/
williamr@2
   711
const TUid KImageTypeTIFFSubTypeBigEndianUid = {0x101F45C6};
williamr@2
   712
/** Image type PNG.
williamr@2
   713
*/
williamr@2
   714
const TUid KImageTypePNGUid = {0x101F45C9};
williamr@2
   715
/** Image type MBM.
williamr@2
   716
*/
williamr@2
   717
const TUid KImageTypeMBMUid = {0x101F45CC};
williamr@2
   718
/** Image type WBMP.
williamr@2
   719
*/
williamr@2
   720
const TUid KImageTypeWBMPUid = {0x101F45CF};
williamr@2
   721
/** Image type OTA.
williamr@2
   722
*/
williamr@2
   723
const TUid KImageTypeOTAUid = {0x101F45D2};
williamr@2
   724
/** Image type ICO.
williamr@2
   725
*/
williamr@2
   726
const TUid KImageTypeICOUid = {0x101F45D5};
williamr@2
   727
/** Image type JPG.
williamr@2
   728
*/
williamr@2
   729
const TUid KImageTypeJPGUid = {0x101F45D8};
williamr@2
   730
williamr@2
   731
#endif // __IMAGECODECDATA_H__
williamr@4
   732