Update change log and spec for wrt-plugins-tizen_0.4.11
[framework/web/wrt-plugins-tizen.git] / src / Content / ContentExif.h
1 //
2 // Tizen Web Device API
3 // Copyright (c) 2012 Samsung Electronics Co., Ltd.
4 //
5 // Licensed under the Apache License, Version 2.0 (the License);
6 // you may not use this file except in compliance with the License.
7 // You may obtain a copy of the License at
8 //
9 // http://www.apache.org/licenses/LICENSE-2.0
10 //
11 // Unless required by applicable law or agreed to in writing, software
12 // distributed under the License is distributed on an "AS IS" BASIS,
13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 // See the License for the specific language governing permissions and
15 // limitations under the License.
16 //
17
18
19 #ifndef _PLATFORM_CONTENT_EXIF_H_
20 #define _PLATFORM_CONTENT_EXIF_H_
21
22 #include <string>
23
24 namespace DeviceAPI {
25 namespace Content {
26
27 #define EXIF_TAG_ORIENTATION 0x0112
28
29 class ContentExif
30 {
31 public:
32         ContentExif(std::string path);
33         virtual ~ContentExif();
34
35         int LodExif();
36         bool SetExifChar(unsigned int tag, unsigned char value);
37
38 private:
39
40         int read_1_byte();
41         unsigned int read_2_bytes();
42         unsigned char nextByte();
43
44
45         FILE *fp;
46
47         std::string m_path;
48         bool m_endianType;
49         unsigned char *m_exifBuf;
50         unsigned int m_tagCount;
51         unsigned int m_offset;
52 };
53
54 } // Content
55 } // DeviceAPI
56
57 #endif // _PLATFORM_CONTENT_UTILITY_H_