Exiv2
Loading...
Searching...
No Matches
makernote_int.hpp
Go to the documentation of this file.
1// ***************************************************************** -*- C++ -*-
2/*
3 * Copyright (C) 2004-2018 Exiv2 authors
4 * This program is part of the Exiv2 distribution.
5 *
6 * This program is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU General Public License
8 * as published by the Free Software Foundation; either version 2
9 * of the License, or (at your option) any later version.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 *
16 * You should have received a copy of the GNU General Public License
17 * along with this program; if not, write to the Free Software
18 * Foundation, Inc., 51 Franklin Street, 5th Floor, Boston, MA 02110-1301 USA.
19 */
30#ifndef MAKERNOTE_INT_HPP_
31#define MAKERNOTE_INT_HPP_
32
33// *****************************************************************************
34// included header files
35#include "tifffwd_int.hpp"
36#include "tags_int.hpp"
37#include "ini.hpp"
38#include "types.hpp"
39
40// + standard includes
41#include <string>
42
43// *****************************************************************************
44// namespace extensions
45namespace Exiv2 {
46 namespace Internal {
47// *****************************************************************************
48// function prototypes
52 std::string getExiv2ConfigPath();
53
57 std::string readExiv2Config(const std::string& section,const std::string& value,const std::string& def);
58
59
60// *****************************************************************************
61// class definitions
62
64 typedef TiffComponent* (*NewMnFct)(uint16_t tag,
65 IfdId group,
66 IfdId mnGroup,
67 const byte* pData,
68 uint32_t size,
69 ByteOrder byteOrder);
70
72 typedef TiffComponent* (*NewMnFct2)(uint16_t tag,
73 IfdId group,
74 IfdId mnGroup);
75
78 struct MakeKey;
86 bool operator==(const std::string& key) const;
87
89 bool operator==(IfdId key) const;
90
91 // DATA
92 const char* make_;
96 };
97
102 public:
114 static TiffComponent* create(uint16_t tag,
115 IfdId group,
116 const std::string& make,
117 const byte* pData,
118 uint32_t size,
119 ByteOrder byteOrder);
124 static TiffComponent* create(uint16_t tag,
125 IfdId group,
126 IfdId mnGroup);
127
128 protected:
131 private:
132 static const TiffMnRegistry registry_[]; //<! List of makernotes
133 }; // class TiffMnCreator
134
136 class MnHeader {
137 public:
139
140
141 virtual ~MnHeader();
143
145
146 virtual bool read(const byte* pData,
147 uint32_t size,
152 virtual void setByteOrder(ByteOrder byteOrder);
154
156
157 virtual uint32_t size() const =0;
159 virtual uint32_t write(IoWrapper& ioWrapper,
160 ByteOrder byteOrder) const =0;
165 virtual uint32_t ifdOffset() const;
171 virtual ByteOrder byteOrder() const;
177 virtual uint32_t baseOffset(uint32_t mnOffset) const;
179
180 }; // class MnHeader
181
183 class OlympusMnHeader : public MnHeader {
184 public:
186
187
190 virtual ~OlympusMnHeader();
192
194 virtual bool read(const byte* pData,
195 uint32_t size,
198
200 virtual uint32_t size() const;
201 virtual uint32_t write(IoWrapper& ioWrapper, ByteOrder byteOrder) const;
202 virtual uint32_t ifdOffset() const;
204
205 static uint32_t sizeOfSignature();
206
207 private:
208 DataBuf header_;
209 static const byte signature_[];
210
211 }; // class OlympusMnHeader
212
214 class Olympus2MnHeader : public MnHeader {
215 public:
217
218
221 virtual ~Olympus2MnHeader();
223
225 virtual bool read(const byte* pData,
226 uint32_t size,
229
231 virtual uint32_t size() const;
232 virtual uint32_t write(IoWrapper& ioWrapper, ByteOrder byteOrder) const;
233 virtual uint32_t ifdOffset() const;
234 virtual uint32_t baseOffset(uint32_t mnOffset) const;
236
237 static uint32_t sizeOfSignature();
238
239 private:
240 DataBuf header_;
241 static const byte signature_[];
242
243 }; // class Olympus2MnHeader
244
246 class FujiMnHeader : public MnHeader {
247 public:
249
250
251 FujiMnHeader();
253 virtual ~FujiMnHeader();
255
257 virtual bool read(const byte* pData,
258 uint32_t size,
260 // setByteOrder not implemented
262
264 virtual uint32_t size() const;
265 virtual uint32_t write(IoWrapper& ioWrapper, ByteOrder byteOrder) const;
266 virtual uint32_t ifdOffset() const;
267 virtual ByteOrder byteOrder() const;
268 virtual uint32_t baseOffset(uint32_t mnOffset) const;
270
271 static uint32_t sizeOfSignature();
272
273 private:
274 DataBuf header_;
275 static const byte signature_[];
276 static const ByteOrder byteOrder_;
277 uint32_t start_;
278
279 }; // class FujiMnHeader
280
282 class Nikon2MnHeader : public MnHeader {
283 public:
285
286
289 virtual ~Nikon2MnHeader();
291
293 virtual bool read(const byte* pData,
294 uint32_t size,
297
299 virtual uint32_t size() const;
300 virtual uint32_t write(IoWrapper& ioWrapper, ByteOrder byteOrder) const;
301 virtual uint32_t ifdOffset() const;
303
304 static uint32_t sizeOfSignature();
305
306 private:
307 DataBuf buf_;
308 uint32_t start_;
309 static const byte signature_[];
310
311 }; // class Nikon2MnHeader
312
314 class Nikon3MnHeader : public MnHeader {
315 public:
317
318
321 virtual ~Nikon3MnHeader();
323
325 virtual bool read(const byte* pData,
326 uint32_t size,
328 virtual void setByteOrder(ByteOrder byteOrder);
330
332 virtual uint32_t size() const;
333 virtual uint32_t write(IoWrapper& ioWrapper, ByteOrder byteOrder) const;
334 virtual uint32_t ifdOffset() const;
335 virtual ByteOrder byteOrder() const;
336 virtual uint32_t baseOffset(uint32_t mnOffset) const;
338
339 static uint32_t sizeOfSignature();
340
341 private:
342 DataBuf buf_;
343 ByteOrder byteOrder_;
344 uint32_t start_;
345 static const byte signature_[];
346
347 }; // class Nikon3MnHeader
348
351 public:
353
354
357 virtual ~PanasonicMnHeader();
359
361 virtual bool read(const byte* pData,
362 uint32_t size,
365
367 virtual uint32_t size() const;
368 virtual uint32_t write(IoWrapper& ioWrapper, ByteOrder byteOrder) const;
369 virtual uint32_t ifdOffset() const;
371
372 static uint32_t sizeOfSignature();
373
374 private:
375 DataBuf buf_;
376 uint32_t start_;
377 static const byte signature_[];
378
379 }; // class PanasonicMnHeader
380
383 public:
385
386
389 virtual ~PentaxDngMnHeader();
391
393 virtual bool read(const byte* pData,
394 uint32_t size,
397
399 virtual uint32_t size() const;
400 virtual uint32_t write(IoWrapper& ioWrapper, ByteOrder byteOrder) const;
401 virtual uint32_t ifdOffset() const;
402 virtual uint32_t baseOffset(uint32_t mnOffset) const;
404
405 static uint32_t sizeOfSignature();
406
407 private:
408 DataBuf header_;
409 static const byte signature_[];
410
411 }; // class PentaxDngMnHeader
412
414 class PentaxMnHeader : public MnHeader {
415 public:
417
418
421 virtual ~PentaxMnHeader();
423
425 virtual bool read(const byte* pData,
426 uint32_t size,
429
431 virtual uint32_t size() const;
432 virtual uint32_t write(IoWrapper& ioWrapper, ByteOrder byteOrder) const;
433 virtual uint32_t ifdOffset() const;
435
436 static uint32_t sizeOfSignature();
437
438 private:
439 DataBuf header_;
440 static const byte signature_[];
441
442 }; // class PentaxMnHeader
443
445 class SamsungMnHeader : public MnHeader {
446 public:
448
449
452
454 virtual bool read(const byte* pData,
455 uint32_t size,
458
460 virtual uint32_t size() const;
461 virtual uint32_t write(IoWrapper& ioWrapper, ByteOrder byteOrder) const;
462 virtual uint32_t baseOffset(uint32_t mnOffset) const;
464
465 }; // class SamsungMnHeader
466
468 class SigmaMnHeader : public MnHeader {
469 public:
471
472
475 virtual ~SigmaMnHeader();
477
479 virtual bool read(const byte* pData,
480 uint32_t size,
483
485 virtual uint32_t size() const;
486 virtual uint32_t write(IoWrapper& ioWrapper, ByteOrder byteOrder) const;
487 virtual uint32_t ifdOffset() const;
489
490 static uint32_t sizeOfSignature();
491
492 private:
493 DataBuf buf_;
494 uint32_t start_;
495 static const byte signature1_[];
496 static const byte signature2_[];
497
498 }; // class SigmaMnHeader
499
501 class SonyMnHeader : public MnHeader {
502 public:
504
505
506 SonyMnHeader();
508 virtual ~SonyMnHeader();
510
512 virtual bool read(const byte* pData,
513 uint32_t size,
516
518 virtual uint32_t size() const;
519 virtual uint32_t write(IoWrapper& ioWrapper, ByteOrder byteOrder) const;
520 virtual uint32_t ifdOffset() const;
522
523 static uint32_t sizeOfSignature();
524
525 private:
526 DataBuf buf_;
527 uint32_t start_;
528 static const byte signature_[];
529
530 }; // class SonyMnHeader
531
533 class Casio2MnHeader : public MnHeader {
534 public:
536
537
540 virtual ~Casio2MnHeader();
542
544 virtual bool read(const byte* pData,
545 uint32_t size,
548
550 virtual uint32_t size() const;
551 virtual uint32_t write(IoWrapper& ioWrapper, ByteOrder byteOrder) const;
552 virtual uint32_t ifdOffset() const;
553 virtual ByteOrder byteOrder() const;
555
556 static uint32_t sizeOfSignature();
557
558 private:
559 DataBuf buf_;
560 uint32_t start_;
561 static const byte signature_[];
562 static const ByteOrder byteOrder_;
563
564 }; // class Casio2MnHeader
565
566 // *****************************************************************************
567// template, inline and free functions
568
570 TiffComponent* newIfdMn(uint16_t tag,
571 IfdId group,
572 IfdId mnGroup,
573 const byte* pData,
574 uint32_t size,
575 ByteOrder byteOrder);
576
578 TiffComponent* newIfdMn2(uint16_t tag,
579 IfdId group,
580 IfdId mnGroup);
581
583 TiffComponent* newOlympusMn(uint16_t tag,
584 IfdId group,
585 IfdId mnGroup,
586 const byte* pData,
587 uint32_t size,
588 ByteOrder byteOrder);
589
591 TiffComponent* newOlympusMn2(uint16_t tag,
592 IfdId group,
593 IfdId mnGroup);
594
596 TiffComponent* newOlympus2Mn2(uint16_t tag,
597 IfdId group,
598 IfdId mnGroup);
599
601 TiffComponent* newFujiMn(uint16_t tag,
602 IfdId group,
603 IfdId mnGroup,
604 const byte* pData,
605 uint32_t size,
606 ByteOrder byteOrder);
607
609 TiffComponent* newFujiMn2(uint16_t tag,
610 IfdId group,
611 IfdId mnGroup);
612
617 TiffComponent* newNikonMn(uint16_t tag,
618 IfdId group,
619 IfdId mnGroup,
620 const byte* pData,
621 uint32_t size,
622 ByteOrder byteOrder);
623
625 TiffComponent* newNikon2Mn2(uint16_t tag,
626 IfdId group,
627 IfdId mnGroup);
628
630 TiffComponent* newNikon3Mn2(uint16_t tag,
631 IfdId group,
632 IfdId mnGroup);
633
635 TiffComponent* newPanasonicMn(uint16_t tag,
636 IfdId group,
637 IfdId mnGroup,
638 const byte* pData,
639 uint32_t size,
640 ByteOrder byteOrder);
641
643 TiffComponent* newPanasonicMn2(uint16_t tag,
644 IfdId group,
645 IfdId mnGroup);
646
648 TiffComponent* newPentaxMn(uint16_t tag,
649 IfdId group,
650 IfdId mnGroup,
651 const byte* pData,
652 uint32_t size,
653 ByteOrder byteOrder);
654
656 TiffComponent* newPentaxMn2(uint16_t tag,
657 IfdId group,
658 IfdId mnGroup);
659
661 TiffComponent* newPentaxDngMn2(uint16_t tag,
662 IfdId group,
663 IfdId mnGroup);
664
666 TiffComponent* newSamsungMn(uint16_t tag,
667 IfdId group,
668 IfdId mnGroup,
669 const byte* pData,
670 uint32_t size,
671 ByteOrder byteOrder);
672
674 TiffComponent* newSamsungMn2(uint16_t tag,
675 IfdId group,
676 IfdId mnGroup);
677
679 TiffComponent* newSigmaMn(uint16_t tag,
680 IfdId group,
681 IfdId mnGroup,
682 const byte* pData,
683 uint32_t size,
684 ByteOrder byteOrder);
685
687 TiffComponent* newSigmaMn2(uint16_t tag,
688 IfdId group,
689 IfdId mnGroup);
690
692 TiffComponent* newSonyMn(uint16_t tag,
693 IfdId group,
694 IfdId mnGroup,
695 const byte* pData,
696 uint32_t size,
697 ByteOrder byteOrder);
698
700 TiffComponent* newSony1Mn2(uint16_t tag,
701 IfdId group,
702 IfdId mnGroup);
703
705 TiffComponent* newSony2Mn2(uint16_t tag,
706 IfdId group,
707 IfdId mnGroup);
708
710 TiffComponent* newCasioMn(uint16_t tag,
711 IfdId group,
712 IfdId mnGroup,
713 const byte* pData,
714 uint32_t size,
715 ByteOrder byteOrder);
716
718 TiffComponent* newCasio2Mn2(uint16_t tag,
719 IfdId group,
720 IfdId mnGroup);
721
731 int sonyCsSelector(uint16_t tag, const byte* pData, uint32_t size, TiffComponent* const pRoot);
732
742 int sony2010eSelector(uint16_t tag, const byte* pData, uint32_t size, TiffComponent* const pRoot);
743
753 int nikonSelector(uint16_t tag, const byte* pData, uint32_t size, TiffComponent* const pRoot);
754
764 int nikonAf2Selector(uint16_t tag, const byte* pData, uint32_t size, TiffComponent* const pRoot);
765
782 DataBuf nikonCrypt(uint16_t tag, const byte* pData, uint32_t size, TiffComponent* const pRoot);
783
784}} // namespace Internal, Exiv2
785
786#endif // #ifndef MAKERNOTE_INT_HPP_
Utility class containing a character array. All it does is to take care of memory allocation and dele...
Definition types.hpp:204
Header of a Casio2 Makernote.
Definition makernote_int.hpp:533
virtual uint32_t size() const
Return the size of the header (in bytes).
Definition makernote_int.cpp:815
virtual ~Casio2MnHeader()
Virtual destructor.
Definition makernote_int.cpp:811
virtual uint32_t ifdOffset() const
Return the offset to the start of the Makernote IFD from the start of the Makernote (= the start of t...
Definition makernote_int.cpp:820
virtual uint32_t write(IoWrapper &ioWrapper, ByteOrder byteOrder) const
Write the header to a data buffer, return the number of bytes written.
Definition makernote_int.cpp:842
virtual bool read(const byte *pData, uint32_t size, ByteOrder byteOrder)
Read the header from a data buffer, return true if ok.
Definition makernote_int.cpp:830
static uint32_t sizeOfSignature()
Return the size of the makernote header signature.
Definition makernote_int.cpp:801
virtual ByteOrder byteOrder() const
Return the byte order for the makernote. If the return value is invalidByteOrder, this means that the...
Definition makernote_int.cpp:825
Casio2MnHeader()
Default constructor.
Definition makernote_int.cpp:806
Header of a Fujifilm Makernote.
Definition makernote_int.hpp:246
virtual uint32_t baseOffset(uint32_t mnOffset) const
Return the base offset for the makernote IFD entries relative to the start of the TIFF header....
Definition makernote_int.cpp:367
virtual ByteOrder byteOrder() const
Return the byte order for the makernote. If the return value is invalidByteOrder, this means that the...
Definition makernote_int.cpp:362
FujiMnHeader()
Default constructor.
Definition makernote_int.cpp:343
virtual ~FujiMnHeader()
Virtual destructor.
Definition makernote_int.cpp:348
virtual uint32_t size() const
Return the size of the header (in bytes).
Definition makernote_int.cpp:352
virtual uint32_t ifdOffset() const
Return the offset to the start of the Makernote IFD from the start of the Makernote (= the start of t...
Definition makernote_int.cpp:357
static uint32_t sizeOfSignature()
Return the size of the makernote header signature.
Definition makernote_int.cpp:338
virtual bool read(const byte *pData, uint32_t size, ByteOrder byteOrder)
Read the header from a data buffer, return true if ok.
Definition makernote_int.cpp:372
virtual uint32_t write(IoWrapper &ioWrapper, ByteOrder byteOrder) const
Write the header to a data buffer, return the number of bytes written.
Definition makernote_int.cpp:389
Simple IO wrapper to ensure that the header is only written if there is any other data at all.
Definition tiffcomposite_int.hpp:124
Makernote header interface. This class is used with TIFF makernotes.
Definition makernote_int.hpp:136
virtual uint32_t write(IoWrapper &ioWrapper, ByteOrder byteOrder) const =0
Write the header to a data buffer, return the number of bytes written.
virtual void setByteOrder(ByteOrder byteOrder)
Set the byte order for the makernote.
Definition makernote_int.cpp:211
virtual bool read(const byte *pData, uint32_t size, ByteOrder byteOrder)=0
Read the header from a data buffer, return true if ok.
virtual ~MnHeader()
Virtual destructor.
Definition makernote_int.cpp:207
virtual uint32_t baseOffset(uint32_t mnOffset) const
Return the base offset for the makernote IFD entries relative to the start of the TIFF header....
Definition makernote_int.cpp:225
virtual uint32_t ifdOffset() const
Return the offset to the start of the Makernote IFD from the start of the Makernote (= the start of t...
Definition makernote_int.cpp:215
virtual ByteOrder byteOrder() const
Return the byte order for the makernote. If the return value is invalidByteOrder, this means that the...
Definition makernote_int.cpp:220
virtual uint32_t size() const =0
Return the size of the header (in bytes).
Header of a Nikon 2 Makernote.
Definition makernote_int.hpp:282
virtual ~Nikon2MnHeader()
Virtual destructor.
Definition makernote_int.cpp:410
virtual uint32_t write(IoWrapper &ioWrapper, ByteOrder byteOrder) const
Write the header to a data buffer, return the number of bytes written.
Definition makernote_int.cpp:436
Nikon2MnHeader()
Default constructor.
Definition makernote_int.cpp:405
virtual uint32_t size() const
Return the size of the header (in bytes).
Definition makernote_int.cpp:414
static uint32_t sizeOfSignature()
Return the size of the makernote header signature.
Definition makernote_int.cpp:400
virtual uint32_t ifdOffset() const
Return the offset to the start of the Makernote IFD from the start of the Makernote (= the start of t...
Definition makernote_int.cpp:419
virtual bool read(const byte *pData, uint32_t size, ByteOrder byteOrder)
Read the header from a data buffer, return true if ok.
Definition makernote_int.cpp:424
Header of a Nikon 3 Makernote.
Definition makernote_int.hpp:314
virtual uint32_t size() const
Return the size of the header (in bytes).
Definition makernote_int.cpp:465
virtual ByteOrder byteOrder() const
Return the byte order for the makernote. If the return value is invalidByteOrder, this means that the...
Definition makernote_int.cpp:475
Nikon3MnHeader()
Default constructor.
Definition makernote_int.cpp:453
virtual bool read(const byte *pData, uint32_t size, ByteOrder byteOrder)
Read the header from a data buffer, return true if ok.
Definition makernote_int.cpp:485
virtual uint32_t ifdOffset() const
Return the offset to the start of the Makernote IFD from the start of the Makernote (= the start of t...
Definition makernote_int.cpp:470
virtual uint32_t baseOffset(uint32_t mnOffset) const
Return the base offset for the makernote IFD entries relative to the start of the TIFF header....
Definition makernote_int.cpp:480
virtual ~Nikon3MnHeader()
Virtual destructor.
Definition makernote_int.cpp:461
virtual uint32_t write(IoWrapper &ioWrapper, ByteOrder byteOrder) const
Write the header to a data buffer, return the number of bytes written.
Definition makernote_int.cpp:500
virtual void setByteOrder(ByteOrder byteOrder)
Set the byte order for the makernote.
Definition makernote_int.cpp:514
static uint32_t sizeOfSignature()
Return the size of the makernote header signature.
Definition makernote_int.cpp:448
Header of an Olympus II Makernote.
Definition makernote_int.hpp:214
virtual uint32_t write(IoWrapper &ioWrapper, ByteOrder byteOrder) const
Write the header to a data buffer, return the number of bytes written.
Definition makernote_int.cpp:326
virtual bool read(const byte *pData, uint32_t size, ByteOrder byteOrder)
Read the header from a data buffer, return true if ok.
Definition makernote_int.cpp:312
virtual uint32_t baseOffset(uint32_t mnOffset) const
Return the base offset for the makernote IFD entries relative to the start of the TIFF header....
Definition makernote_int.cpp:307
virtual uint32_t ifdOffset() const
Return the offset to the start of the Makernote IFD from the start of the Makernote (= the start of t...
Definition makernote_int.cpp:302
virtual uint32_t size() const
Return the size of the header (in bytes).
Definition makernote_int.cpp:297
Olympus2MnHeader()
Default constructor.
Definition makernote_int.cpp:288
static uint32_t sizeOfSignature()
Return the size of the makernote header signature.
Definition makernote_int.cpp:283
virtual ~Olympus2MnHeader()
Virtual destructor.
Definition makernote_int.cpp:293
Header of an Olympus Makernote.
Definition makernote_int.hpp:183
static uint32_t sizeOfSignature()
Return the size of the makernote header signature.
Definition makernote_int.cpp:234
virtual uint32_t ifdOffset() const
Return the offset to the start of the Makernote IFD from the start of the Makernote (= the start of t...
Definition makernote_int.cpp:253
virtual bool read(const byte *pData, uint32_t size, ByteOrder byteOrder)
Read the header from a data buffer, return true if ok.
Definition makernote_int.cpp:258
virtual uint32_t write(IoWrapper &ioWrapper, ByteOrder byteOrder) const
Write the header to a data buffer, return the number of bytes written.
Definition makernote_int.cpp:272
OlympusMnHeader()
Default constructor.
Definition makernote_int.cpp:239
virtual uint32_t size() const
Return the size of the header (in bytes).
Definition makernote_int.cpp:248
virtual ~OlympusMnHeader()
Virtual destructor.
Definition makernote_int.cpp:244
Header of a Panasonic Makernote.
Definition makernote_int.hpp:350
virtual uint32_t write(IoWrapper &ioWrapper, ByteOrder byteOrder) const
Write the header to a data buffer, return the number of bytes written.
Definition makernote_int.cpp:559
virtual ~PanasonicMnHeader()
Virtual destructor.
Definition makernote_int.cpp:533
PanasonicMnHeader()
Default constructor.
Definition makernote_int.cpp:528
virtual uint32_t ifdOffset() const
Return the offset to the start of the Makernote IFD from the start of the Makernote (= the start of t...
Definition makernote_int.cpp:542
virtual bool read(const byte *pData, uint32_t size, ByteOrder byteOrder)
Read the header from a data buffer, return true if ok.
Definition makernote_int.cpp:547
static uint32_t sizeOfSignature()
Return the size of the makernote header signature.
Definition makernote_int.cpp:523
virtual uint32_t size() const
Return the size of the header (in bytes).
Definition makernote_int.cpp:537
Header of an Pentax DNG Makernote.
Definition makernote_int.hpp:382
PentaxDngMnHeader()
Default constructor.
Definition makernote_int.cpp:575
virtual uint32_t write(IoWrapper &ioWrapper, ByteOrder byteOrder) const
Write the header to a data buffer, return the number of bytes written.
Definition makernote_int.cpp:613
virtual bool read(const byte *pData, uint32_t size, ByteOrder byteOrder)
Read the header from a data buffer, return true if ok.
Definition makernote_int.cpp:599
virtual uint32_t baseOffset(uint32_t mnOffset) const
Return the base offset for the makernote IFD entries relative to the start of the TIFF header....
Definition makernote_int.cpp:589
virtual ~PentaxDngMnHeader()
Virtual destructor.
Definition makernote_int.cpp:580
virtual uint32_t size() const
Return the size of the header (in bytes).
Definition makernote_int.cpp:584
static uint32_t sizeOfSignature()
Return the size of the makernote header signature.
Definition makernote_int.cpp:570
virtual uint32_t ifdOffset() const
Return the offset to the start of the Makernote IFD from the start of the Makernote (= the start of t...
Definition makernote_int.cpp:594
Header of an Pentax Makernote.
Definition makernote_int.hpp:414
virtual bool read(const byte *pData, uint32_t size, ByteOrder byteOrder)
Read the header from a data buffer, return true if ok.
Definition makernote_int.cpp:648
virtual uint32_t size() const
Return the size of the header (in bytes).
Definition makernote_int.cpp:638
static uint32_t sizeOfSignature()
Return the size of the makernote header signature.
Definition makernote_int.cpp:624
virtual ~PentaxMnHeader()
Virtual destructor.
Definition makernote_int.cpp:634
virtual uint32_t ifdOffset() const
Return the offset to the start of the Makernote IFD from the start of the Makernote (= the start of t...
Definition makernote_int.cpp:643
virtual uint32_t write(IoWrapper &ioWrapper, ByteOrder byteOrder) const
Write the header to a data buffer, return the number of bytes written.
Definition makernote_int.cpp:662
PentaxMnHeader()
Default constructor.
Definition makernote_int.cpp:629
Header of a Samsung Makernote, only used for the relative offset.
Definition makernote_int.hpp:445
SamsungMnHeader()
Default constructor.
Definition makernote_int.cpp:669
virtual uint32_t write(IoWrapper &ioWrapper, ByteOrder byteOrder) const
Write the header to a data buffer, return the number of bytes written.
Definition makernote_int.cpp:691
virtual bool read(const byte *pData, uint32_t size, ByteOrder byteOrder)
Read the header from a data buffer, return true if ok.
Definition makernote_int.cpp:684
virtual uint32_t baseOffset(uint32_t mnOffset) const
Return the base offset for the makernote IFD entries relative to the start of the TIFF header....
Definition makernote_int.cpp:679
virtual uint32_t size() const
Return the size of the header (in bytes).
Definition makernote_int.cpp:674
Header of a Sigma Makernote.
Definition makernote_int.hpp:468
virtual uint32_t write(IoWrapper &ioWrapper, ByteOrder byteOrder) const
Write the header to a data buffer, return the number of bytes written.
Definition makernote_int.cpp:742
virtual uint32_t ifdOffset() const
Return the offset to the start of the Makernote IFD from the start of the Makernote (= the start of t...
Definition makernote_int.cpp:724
virtual ~SigmaMnHeader()
Virtual destructor.
Definition makernote_int.cpp:715
static uint32_t sizeOfSignature()
Return the size of the makernote header signature.
Definition makernote_int.cpp:704
virtual uint32_t size() const
Return the size of the header (in bytes).
Definition makernote_int.cpp:719
SigmaMnHeader()
Default constructor.
Definition makernote_int.cpp:710
virtual bool read(const byte *pData, uint32_t size, ByteOrder byteOrder)
Read the header from a data buffer, return true if ok.
Definition makernote_int.cpp:729
Header of a Sony Makernote.
Definition makernote_int.hpp:501
SonyMnHeader()
Default constructor.
Definition makernote_int.cpp:758
virtual ~SonyMnHeader()
Virtual destructor.
Definition makernote_int.cpp:763
static uint32_t sizeOfSignature()
Return the size of the makernote header signature.
Definition makernote_int.cpp:753
virtual uint32_t write(IoWrapper &ioWrapper, ByteOrder byteOrder) const
Write the header to a data buffer, return the number of bytes written.
Definition makernote_int.cpp:789
virtual uint32_t ifdOffset() const
Return the offset to the start of the Makernote IFD from the start of the Makernote (= the start of t...
Definition makernote_int.cpp:772
virtual bool read(const byte *pData, uint32_t size, ByteOrder byteOrder)
Read the header from a data buffer, return true if ok.
Definition makernote_int.cpp:777
virtual uint32_t size() const
Return the size of the header (in bytes).
Definition makernote_int.cpp:767
Interface class for components of a TIFF directory hierarchy (Composite pattern). Both TIFF directori...
Definition tiffcomposite_int.hpp:174
TIFF makernote factory for concrete TIFF makernotes.
Definition makernote_int.hpp:101
~TiffMnCreator()
Prevent destruction (needed if used as a policy class)
Definition makernote_int.hpp:130
static TiffComponent * create(uint16_t tag, IfdId group, const std::string &make, const byte *pData, uint32_t size, ByteOrder byteOrder)
Create the Makernote for camera make and details from the makernote entry itself if needed....
Definition makernote_int.cpp:166
int nikonSelector(uint16_t tag, const byte *pData, uint32_t size, TiffComponent *const)
Function to select cfg + def of a Nikon complex binary array.
Definition makernote_int.cpp:1181
TiffComponent * newSigmaMn(uint16_t tag, IfdId group, IfdId mnGroup, const byte *, uint32_t size, ByteOrder)
Function to create a Sigma makernote.
Definition makernote_int.cpp:1045
TiffComponent * newPanasonicMn2(uint16_t tag, IfdId group, IfdId mnGroup)
Function to create a Panasonic makernote.
Definition makernote_int.cpp:978
TiffComponent *(* NewMnFct2)(uint16_t tag, IfdId group, IfdId mnGroup)
Type for a pointer to a function creating a makernote (group)
Definition makernote_int.hpp:72
TiffComponent *(* NewMnFct)(uint16_t tag, IfdId group, IfdId mnGroup, const byte *pData, uint32_t size, ByteOrder byteOrder)
Type for a pointer to a function creating a makernote (image)
Definition makernote_int.hpp:64
TiffComponent * newFujiMn(uint16_t tag, IfdId group, IfdId mnGroup, const byte *, uint32_t size, ByteOrder)
Function to create a Fujifilm makernote.
Definition makernote_int.cpp:903
TiffComponent * newSony2Mn2(uint16_t tag, IfdId group, IfdId mnGroup)
Function to create a Sony2 makernote.
Definition makernote_int.cpp:1090
TiffComponent * newOlympus2Mn2(uint16_t tag, IfdId group, IfdId mnGroup)
Function to create an Olympus II makernote.
Definition makernote_int.cpp:896
TiffComponent * newFujiMn2(uint16_t tag, IfdId group, IfdId mnGroup)
Function to create a Fujifilm makernote.
Definition makernote_int.cpp:915
int sonyCsSelector(uint16_t, const byte *, uint32_t, TiffComponent *const pRoot)
Function to select cfg + def of the Sony Camera Settings complex binary array.
Definition makernote_int.cpp:1235
TiffComponent * newSonyMn(uint16_t tag, IfdId group, IfdId, const byte *pData, uint32_t size, ByteOrder)
Function to create a Sony makernote.
Definition makernote_int.cpp:1064
TiffComponent * newPanasonicMn(uint16_t tag, IfdId group, IfdId mnGroup, const byte *, uint32_t size, ByteOrder)
Function to create a Panasonic makernote.
Definition makernote_int.cpp:966
int sony2010eSelector(uint16_t, const byte *, uint32_t, TiffComponent *const pRoot)
Function to select cfg + def of the Sony 2010 Miscellaneous Information complex binary array.
Definition makernote_int.cpp:1246
TiffComponent * newNikon3Mn2(uint16_t tag, IfdId group, IfdId mnGroup)
Function to create a Nikon3 makernote.
Definition makernote_int.cpp:959
DataBuf nikonCrypt(uint16_t tag, const byte *pData, uint32_t size, TiffComponent *const pRoot)
Encrypt and decrypt Nikon data.
Definition makernote_int.cpp:1197
TiffComponent * newSigmaMn2(uint16_t tag, IfdId group, IfdId mnGroup)
Function to create a Sigma makernote.
Definition makernote_int.cpp:1057
TiffComponent * newOlympusMn2(uint16_t tag, IfdId group, IfdId mnGroup)
Function to create an Olympus makernote.
Definition makernote_int.cpp:889
int nikonAf2Selector(uint16_t tag, const byte *, uint32_t size, TiffComponent *const)
Function to select cfg + def of a Nikon complex binary array.
Definition makernote_int.cpp:1188
std::string getExiv2ConfigPath()
Determine the path to the Exiv2 configuration file.
Definition makernote_int.cpp:94
TiffComponent * newCasioMn(uint16_t tag, IfdId group, IfdId, const byte *pData, uint32_t size, ByteOrder)
Function to create a Casio2 makernote.
Definition makernote_int.cpp:1097
TiffComponent * newNikon2Mn2(uint16_t tag, IfdId group, IfdId mnGroup)
Function to create a Nikon2 makernote.
Definition makernote_int.cpp:952
IfdId
Type to specify the IFD to which a metadata belongs.
Definition tags_int.hpp:54
TiffComponent * newSamsungMn(uint16_t tag, IfdId group, IfdId mnGroup, const byte *pData, uint32_t size, ByteOrder)
Function to create a Samsung makernote.
Definition makernote_int.cpp:1016
TiffComponent * newSamsungMn2(uint16_t tag, IfdId group, IfdId mnGroup)
Function to create a Samsung makernote.
Definition makernote_int.cpp:1038
TiffComponent * newPentaxMn(uint16_t tag, IfdId group, IfdId, const byte *pData, uint32_t size, ByteOrder)
Function to create an Pentax makernote.
Definition makernote_int.cpp:985
std::string readExiv2Config(const std::string &section, const std::string &value, const std::string &def)
Read value from Exiv2 configuration file.
Definition makernote_int.cpp:113
TiffComponent * newNikonMn(uint16_t tag, IfdId group, IfdId, const byte *pData, uint32_t size, ByteOrder)
Function to create a Nikon makernote. This will create the appropriate Nikon 1, 2 or 3 makernote,...
Definition makernote_int.cpp:922
TiffComponent * newIfdMn2(uint16_t tag, IfdId group, IfdId mnGroup)
Function to create a simple IFD makernote (Canon, Minolta, Nikon1)
Definition makernote_int.cpp:864
TiffComponent * newSony1Mn2(uint16_t tag, IfdId group, IfdId mnGroup)
Function to create a Sony1 makernote.
Definition makernote_int.cpp:1083
TiffComponent * newPentaxDngMn2(uint16_t tag, IfdId group, IfdId mnGroup)
Function to create an Pentax DNG makernote.
Definition makernote_int.cpp:1009
TiffComponent * newCasio2Mn2(uint16_t tag, IfdId group, IfdId mnGroup)
Function to create a Casio2 makernote.
Definition makernote_int.cpp:1113
TiffComponent * newOlympusMn(uint16_t tag, IfdId group, IfdId, const byte *pData, uint32_t size, ByteOrder)
Function to create an Olympus makernote.
Definition makernote_int.cpp:871
TiffComponent * newIfdMn(uint16_t tag, IfdId group, IfdId mnGroup, const byte *, uint32_t size, ByteOrder)
Function to create a simple IFD makernote (Canon, Minolta, Nikon1)
Definition makernote_int.cpp:852
TiffComponent * newPentaxMn2(uint16_t tag, IfdId group, IfdId mnGroup)
Function to create an Pentax makernote.
Definition makernote_int.cpp:1002
Provides classes and functions to encode and decode Exif and Iptc data. The libexiv2 API consists of ...
Definition asfvideo.hpp:36
EXIV2API ExifData::const_iterator make(const ExifData &ed)
Return the camera make.
Definition easyaccess.cpp:428
ByteOrder
Type to express the byte order (little or big endian)
Definition types.hpp:113
Makernote registry structure.
Definition makernote_int.hpp:77
bool operator==(const std::string &key) const
Compare a TiffMnRegistry structure with a key being the make string from the image....
Definition makernote_int.cpp:154
NewMnFct2 newMnFct2_
Makernote create function (group)
Definition makernote_int.hpp:95
IfdId mnGroup_
Group identifier.
Definition makernote_int.hpp:93
NewMnFct newMnFct_
Makernote create function (image)
Definition makernote_int.hpp:94
const char * make_
Camera make.
Definition makernote_int.hpp:92
Internal Exif tag and type information.
Internal TIFF parser related typedefs and forward definitions.
Type definitions for Exiv2 and related functionality.