|
1 /* |
|
2 * Copyright (c) 2006-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: Writes location info to image's EXIF data. |
|
15 * |
|
16 */ |
|
17 |
|
18 #ifndef C_CLOCATIONWRITE_H |
|
19 #define C_CLOCATIONWRITE_H |
|
20 |
|
21 #include <e32base.h> |
|
22 |
|
23 class CExifModify; |
|
24 class CLocationRecord; |
|
25 class TPosition; |
|
26 /** |
|
27 * This class writes GPS details to image's EXIF data. |
|
28 * |
|
29 * @since S60 3.1 |
|
30 */ |
|
31 class CLocationWrite : public CBase |
|
32 { |
|
33 public: |
|
34 /** |
|
35 * 2-phased constructor. |
|
36 */ |
|
37 IMPORT_C static CLocationWrite* NewL( CLocationRecord& aLocRecord ); |
|
38 |
|
39 /** |
|
40 * C++ destructor. |
|
41 */ |
|
42 IMPORT_C virtual ~CLocationWrite(); |
|
43 |
|
44 public: |
|
45 /** |
|
46 * Write location information to the image. |
|
47 * @since S60 3.1 |
|
48 * @param aName, The name and path of the image, in which the location |
|
49 * information will be updated. |
|
50 */ |
|
51 IMPORT_C void WriteLocationL( const TDesC& aName ); |
|
52 |
|
53 private: |
|
54 /** |
|
55 * C++ constructor. |
|
56 */ |
|
57 CLocationWrite( CLocationRecord& aLocRecord ); |
|
58 |
|
59 /** |
|
60 * 2nd phase constructor. |
|
61 */ |
|
62 void ConstructL(); |
|
63 |
|
64 private: |
|
65 /** |
|
66 * Write GPS tags to EXIF. |
|
67 */ |
|
68 void WriteGPSTagsToExifL( CExifModify& aExif, |
|
69 const TPosition& aPosition ); |
|
70 |
|
71 /** |
|
72 * Create EXIF tag. |
|
73 */ |
|
74 void CreateTag( const TInt aTagId, |
|
75 const TPosition& aPosition, |
|
76 TDes8& aTagData ); |
|
77 |
|
78 /** |
|
79 * Append integer to descriptor. |
|
80 */ |
|
81 void AppendIntegerToDesc( TDes8& aTagDesc, const TUint aValue ); |
|
82 |
|
83 private: |
|
84 /** |
|
85 * The location trail record class. |
|
86 * Not own. |
|
87 */ |
|
88 CLocationRecord& iLocationRecord; |
|
89 }; |
|
90 |
|
91 #endif // C_CLOCATIONWRITE_H |
|
92 |
|
93 // End of file. |