1 /* |
|
2 * Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: Definition of GlxtnImageDecoderFactory |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 #ifndef GLXTNIMAGEDECODERFACTORY_H |
|
21 #define GLXTNIMAGEDECODERFACTORY_H |
|
22 |
|
23 #include <e32std.h> |
|
24 |
|
25 class CImageDecoder; |
|
26 class RFs; |
|
27 |
|
28 /** |
|
29 * Factory to create appropriate decoder for a given image. |
|
30 * |
|
31 * @author Dan Rhodes |
|
32 * @ingroup glx_thumbnail_creator |
|
33 */ |
|
34 class GlxtnImageDecoderFactory |
|
35 { |
|
36 public: |
|
37 /** |
|
38 * Create a decoder for an image file. If the file is a JPEG, the function |
|
39 * will first try to create a hardware decoder. If that fails a software |
|
40 * decoder will be created. |
|
41 * @param aFs File server session. |
|
42 * @param aFilename Full path of the file. |
|
43 * @return Pointer to image decoder (caller takes ownership). |
|
44 */ |
|
45 static CImageDecoder* NewL( RFs& aFs, const TDesC& aFilename ); |
|
46 /** |
|
47 * Create a decoder for JPEG image data. |
|
48 * @param aFs File server session. |
|
49 * @param aData Buffer containing the image to be decoded. |
|
50 * @return Pointer to image decoder (caller takes ownership). |
|
51 */ |
|
52 static CImageDecoder* NewL( RFs& aFs, const TDesC8& aData ); |
|
53 }; |
|
54 |
|
55 #endif // GLXTNIMAGEDECODERFACTORY_H |
|