File: makernote.html

package info (click to toggle)
exiv2 0.10-1.4
  • links: PTS
  • area: main
  • in suites: etch-m68k
  • size: 13,124 kB
  • ctags: 5,665
  • sloc: cpp: 20,697; xml: 15,118; sh: 10,526; ansic: 1,887; makefile: 367; awk: 64; python: 36
file content (274 lines) | stat: -rw-r--r-- 10,468 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <!--*- sgml -*-->
<html>
<head>
  <title>Exiv2 - Exif and Iptc metadata manipulation library and tools</title>
  <meta name="Author" content="Andreas Huggel">
  <meta name="Description" content="Open source Exif and Iptc metadata library and tools with Exif MakerNote and read/write support">
  <meta name="Keywords" content="exif, iptc, metadata, makernote, manipulation, manipulate, read and write, write, change, update, jpeg, jpg, ifd, image file directory, thumbnail, thumbnails, tag, tags, canon, fujifilm, sigma/foveon, nikon, open source, opensource, huggel, andreas, andreas huggel">
  <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
  <link type="text/css" rel="stylesheet" href="../include/default.css">
  <link type="text/css" rel="stylesheet" href="../include/sortabletable.css">
  <link type="text/css" rel="stylesheet" href="doxygen.css">
  <link href="tabs.css" rel="stylesheet" type="text/css">
  <script type="text/javascript" src="../include/sortabletable.js"></script>
  <script type="text/javascript">
  <!--
  var preload = new Array('../include/blank.png', 
                          '../include/ascending.png', 
                          '../include/descending.png');
  var loader = new Array();
  for(var i = 0; i < preload.length; i++) {
    loader[i] = new Image();
    loader[i].src = preload[i];
  }
  //-->
  </script>
</head>
<body>

<div id="content">

<!-- Main index from Doxygen 1.4.6 -->
<div class="tabs">
  <ul>
    <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
    <li><a href="namespaces.html"><span>Namespaces</span></a></li>
    <li><a href="classes.html"><span>Classes</span></a></li>
    <li><a href="files.html"><span>Files</span></a></li>
    <li><a href="examples.html"><span>Examples</span></a></li>
  </ul>
</div>


<h1>MakerNote Formats and Specifications</h1>

<p>
The Makernote is tag 0x927c in the Exif IFD. According to the 
<a title="The Exif 2.2 standard (PDF)" href="http://tsc.jeita.or.jp/avs/data/cp3451.pdf">
Exif 2.2 standard</a>, the makernote is <i>"a tag for manufacturers of
Exif writers to record any desired information. The contents are up to
the manufacturer, but this tag should not be used for any other than
its intended purpose."</i></p> 

<p>Unfortunately, most vendors do not publish their makernote specifications. (Why not?) 
Most of the <a href="#R0">specifications available on the Internet</a> 
were reverse-engineered. Judging from the size of many makernote fields, manufacturers 
apparently store a lot of information there and from the available specifications, 
some of this is certainly quite interesting. For example, makernotes may contain 
information about the lens used, contrast, saturation and sharpness settings, image 
quality settings, etc.</p>

<p>Many (but not all) vendors write the makernote in TIFF IFD (Image File Directory) format, 
i.e., in the same format as the rest of the Exif information is encoded. Although this may 
appear to make sense at first glance, it actually complicates the situation for programs that 
attempt to write to the Exif data. The problem is that IFDs contain offsets relative to the 
start of the Exif data. That implies that if an Exif writer moves a makernote field encoded in 
IFD format to a different location within the Exif data, it gets corrupted. The reason to
write to the Exif data could be as simple as to add copyright information, an Exif comment, 
etc. In my opinion, this is a bug in the specification. In fact, some vendors seem to have
recognized this problem and use offsets relative to somewhere at the beginning of the makernote 
field for the makernote IFD.</p>

<p>The following table summarizes the structures of the makernote field used by some vendors. 
Please let me know if you find further specifications on the Internet.</p>
<table class="ReportTable" id="report-1" cellspacing="0">
  <colgroup>
    <col>
    <col>
    <col>
    <col>
    <col>
    <col align="center">
    <col>
  </colgroup>
  <thead>
   <tr> 
    <th><b>Make</b></th>
    <th><b>Format</b></th>
    <th><b>Header</b></th>
    <th><b>Endian</b> <sup>1)</sup></th>
    <th><b>Offsets</b> <sup>2)</sup></th>
    <th><b>Ref</b></th>
    <th><b>Remarks</b></th>
   </tr>
  </thead>
  <tbody>
   <tr class="OddRow"> 
    <td>Canon</td>
    <td>IFD</td>
    <td>None</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td><a href="#R2">[2]</a></td>
    <td>Some CR2 images have a non-zero next-IFD pointer</td>
   </tr>
   <tr class="EvenRow"> 
    <td>Casio</td>
    <td>IFD</td>
    <td>-</td>
    <td>-</td>
    <td>-</td>
    <td><a href="#R4">[4]</a></td>
    <td>Not supported by Exiv2 yet</td>
   </tr>
   <tr class="OddRow"> 
    <td>FUJIFILM</td>
    <td>IFD, usually at offset 12</td>
    <td>Starts with the string &quot;FUJIFILM&quot; 
    and a 4 byte pointer to the IFD</td>
    <td>Little-endian (II)</td>
    <td>Relative to the beginning of the makernote</td>
    <td><a href="#R1">[1]</a></td>
    <td>Exif data uses big-endian (MM) byte order</td>
   </tr>
   <tr class="EvenRow">
    <td>Minolta, KONICA&nbsp;MINOLTA</td>
    <td>IFD</td>
    <td>None</td>
    <td>&nbsp</td>
    <td>&nbsp</td>
    <td><a href="#R5">[5]</a></td>
    <td>Camera settings tag is encoded in big-endian (MM) style, regardless of
    the encoding style of the Exif data</td>
   </tr>
   <tr class="OddRow"> 
    <td>NIKON</td>
    <td>IFD</td>
    <td>None</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td><a href="#R3">[3]</a></td>
    <td>Models using this makernote include E990, D1</td>
   </tr>
   <tr class="EvenRow"> 
    <td>NIKON</td>
    <td>IFD, at offset 8</td>
    <td>&quot;Nikon\0&quot; followed by two bytes of unknown meaning</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td><a href="#R1">[1]</a></td>
    <td>Models using this makernote include E700, E800, E900, E900S, E910, E950</td>
   </tr>
   <tr class="OddRow"> 
    <td>NIKON</td>
    <td>IFD, usually at offset 18</td>
    <td>&quot;Nikon\0&quot; followed by 4 bytes which look like a version code 
    and a TIFF header</td>
    <td>From makernote TIFF header</td>
    <td>Relative to the start of the makernote TIFF header</td>
    <td>&nbsp;</td>
    <td>Models using this makernote include E5400, SQ, D2H, D70, D100, D200. 
    Makernote IFD of the D200 has no next-IFD pointer. (Is this a bug?)</td>
   </tr>
   <tr class="EvenRow"> 
    <td>OLYMPUS</td>
    <td>IFD, at offset 8</td>
    <td>&quot;OLYMP\0&quot; followed by two bytes of unknown meaning</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td><a href="#R1">[1]</a></td>
    <td>&nbsp;</td>
   </tr>
   <tr class="OddRow"> 
    <td>Sanyo</td>
    <td>IFD</td>
    <td>-</td>
    <td>-</td>
    <td>-</td>
    <td><a href="#R6">[6]</a></td>
    <td>Not supported by Exiv2 yet</td>
   </tr>
   <tr class="EvenRow"> 
    <td>SIGMA, FOVEON</td>
    <td>IFD, at offset 10</td>
    <td>&quot;SIGMA\0\0\0&quot; or &quot;FOVEON\0\0&quot; followed by two bytes 
    of unknown meaning</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td><a href="#R7">[7]</a></td>
    <td>&nbsp;</td>
   </tr>
   <tr class="OddRow"> 
    <td>Panasonic</td>
    <td>IFD without a next-IFD pointer at offset 12</td>
    <td>&quot;Panasonic\0\0\0&quot;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td><a href="#R8">[8]</a></td>
    <td>&nbsp;</td>
   </tr>
   <tr class="EvenRow"> 
    <td>SONY</td>
    <td>IFD without a next-IFD pointer at offset 12</td>
    <td>&quot;SONY DSC \0\0\0&quot;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>Seen in Jpeg images, e.g., from DSC-W7, DSC-R1</td>
   </tr>
   <tr class="OddRow"> 
    <td>SONY</td>
    <td>IFD</td>
    <td>None</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>Seen in SR2 images, e.g., from DSC-R1</td>
   </tr>
  </tbody>
</table>
<script type="text/javascript">
//<![CDATA[
var t1 = new SortableTable(
  document.getElementById("report-1"),
  ["String", "String", "String", "String", "String", "String", "String"]
);
t1.onsort = function () { 
	var rows = t1.tBody.rows;
	var l = rows.length;
	for (var i = 0; i < l; i++) {
		removeClassName(rows[i], i % 2 ? "OddRow" : "EvenRow");
		addClassName(rows[i], i % 2 ? "EvenRow" : "OddRow");
	}
};
//]]>
</script>

<p>
 <small>
  <sup>1)</sup> If not specified, the byte order of the Exif data is applicable.<br>
  <sup>2)</sup> If not specified, offsets are relative to the start of the TIFF header.
 </small>
</p>

<p><a href="http://www.exif.org/">Exif.org</a> has another table with similar 
  info and sample pictures: <a href="http://www.exif.org/samples.html">Digital 
  Camera Sample Images</a>. According to this source, (at least some) Ricoh and 
  Kodak cameras do not write the makernote in IFD format.</p>
<h2><a name="R0">References</a></h2>
<p><a name="R1">[1]</a> <a href="http://park2.wakwak.com/%7Etsuruzoh/Computer/Digicams/exif-e.html">Exif 
  file format</a> by TsuruZoh Tachibanaya<br>
  <a name="R2">[2]</a> <a href="http://www.burren.cx/david/canon.html">EXIF Makernote 
  of Canon</a> by David Burren<br>
  <a name="R3">[3]</a> <a href="http://www.tawbaware.com/990exif.htm">Makernote 
  EXIF Tag of the Nikon 990</a> by Max Lyons<br>
  <a name="R4">[4]</a> <a href="http://www.dicasoft.de/casiomn.htm">&quot;Makernote&quot; 
  Exif tag of Casio</a> by Eckhard Henkel<br>
  <a name="R5">[5]</a> <a href="http://www.dalibor.cz/minolta/makernote.htm">Minolta 
  MakerNote</a> by Dalibor Jelinek<br>
  <a name="R6">[6]</a> <a href="http://www.exif.org/makernotes/SanyoMakerNote.html">Sanyo 
  MakerNote</a> by John Hawkins<br>
  <a name="R7">[7]</a> <a href="http://www.x3f.info/technotes/FileDocs/MakerNoteDoc.html">
  SIGMA and FOVEON EXIF MakerNote Documentation</a> by Foveon<br>
  <a name="R8">[8]</a> <a href="http://www.compton.nu/panasonic.html">Panasonic 
  MakerNote Information</a> by Tom Hughes<br>
  <a name="R9">[9]</a> <a href="http://www.ozhiker.com/electronics/pjmt/jpeg_info/makernotes.html">
  Various Makernote specifications</a> from the <a href="http://www.ozhiker.com/electronics/pjmt/index.html">
  PHP JPEG Metadata Toolkit</a> by Evan Hunter<br>
  <a name="R10">[10]</a> <a href="http://www.sno.phy.queensu.ca/~phil/exiftool/">ExifTool</a>, the most complete and up-to-date tool for reading and writing meta information in image files, by Phil Harvey</p>

</div>
<!-- closes content -->

</body>
</html>