Loading...
Searching...
No Matches
cr2image.hpp
// SPDX-License-Identifier: GPL-2.0-or-later
#ifndef CR2IMAGE_HPP_
#define CR2IMAGE_HPP_
// *****************************************************************************
#include "exiv2lib_export.h"
// included header files
#include "image.hpp"
// *****************************************************************************
// namespace extensions
namespace Exiv2 {
// *****************************************************************************
// class definitions
class EXIV2API Cr2Image : public Image {
public:
Cr2Image(BasicIo::UniquePtr io, bool create);
void readMetadata() override;
void writeMetadata() override;
void printStructure(std::ostream& out, PrintStructureOption option, size_t depth) override;
void setComment(const std::string&) override;
[[nodiscard]] std::string mimeType() const override;
[[nodiscard]] uint32_t pixelWidth() const override;
[[nodiscard]] uint32_t pixelHeight() const override;
}; // class Cr2Image
class EXIV2API Cr2Parser {
public:
static ByteOrder decode(ExifData& exifData, IptcData& iptcData, XmpData& xmpData, const byte* pData, size_t size);
static WriteMethod encode(BasicIo& io, const byte* pData, size_t size, ByteOrder byteOrder, ExifData& exifData,
IptcData& iptcData, XmpData& xmpData);
}; // class Cr2Parser
// *****************************************************************************
// template, inline and free functions
// These could be static private functions on Image subclasses but then
// ImageFactory needs to be made a friend.
EXIV2API Image::UniquePtr newCr2Instance(BasicIo::UniquePtr io, bool create);
EXIV2API bool isCr2Type(BasicIo& iIo, bool advance);
} // namespace Exiv2
#endif // #ifndef CR2IMAGE_HPP_
Exiv2::BasicIo
An interface for simple binary IO.
Definition basicio.hpp:35
Exiv2::BasicIo::UniquePtr
std::unique_ptr< BasicIo > UniquePtr
BasicIo auto_ptr type.
Definition basicio.hpp:38
Exiv2::Cr2Image
Class to access raw Canon CR2 images. Exif metadata is supported directly, IPTC is read from the Exif...
Definition cr2image.hpp:27
Exiv2::Cr2Parser
Stateless parser class for data in CR2 format. Images use this class to decode and encode CR2 data....
Definition cr2image.hpp:80
Exiv2::ExifData
A container for Exif data. This is a top-level class of the Exiv2 library. The container holds Exifda...
Definition exif.hpp:379
Exiv2::Image
Abstract base class defining the interface for an image. This is the top-level interface to the Exiv2...
Definition image.hpp:50
Exiv2::Image::UniquePtr
std::unique_ptr< Image > UniquePtr
Image auto_ptr type.
Definition image.hpp:53
Exiv2::IptcData
A container for IPTC data. This is a top-level class of the Exiv2 library.
Definition iptc.hpp:153
Exiv2::XmpData
A container for XMP data. This is a top-level class of the Exiv2 library.
Definition xmp_exiv2.hpp:138
Exiv2
Class CrwImage to access Canon CRW images. References: The Canon RAW (CRW) File Format by Phil Harv...
Definition asfvideo.hpp:15
Exiv2::PrintStructureOption
PrintStructureOption
Options for printStructure.
Definition image.hpp:38
Exiv2::newCr2Instance
EXIV2API Image::UniquePtr newCr2Instance(BasicIo::UniquePtr io, bool create)
Create a new Cr2Image instance and return an auto-pointer to it. Caller owns the returned object and ...
Definition cr2image.cpp:129
Exiv2::ByteOrder
ByteOrder
Type to express the byte order (little or big endian)
Definition types.hpp:34
Exiv2::WriteMethod
WriteMethod
Type to indicate write method used by TIFF parsers.
Definition types.hpp:41
Exiv2::isCr2Type
EXIV2API bool isCr2Type(BasicIo &iIo, bool advance)
Check if the file iIo is a CR2 image.
Definition cr2image.cpp:137
Exiv2::mimeType
List of TIFF compression to MIME type mappings.
Definition tiffimage.cpp:47