6#include "exiv2lib_export.h"
25 void readMetadata()
override;
26 void writeMetadata()
override;
89 int num_color_components_{-1};
102 int initImage(
const byte initData[],
size_t dataSize);
110 void doWriteMetadata(
BasicIo& outIo);
124 [[nodiscard]]
byte advanceToMarker(
ErrorCode err)
const;
127 DataBuf readNextSegment(
byte marker);
158 [[nodiscard]] std::string
mimeType()
const override;
163 return num_color_components_;
169 return sof_encoding_process_;
176 bool isThisType(
BasicIo& iIo,
bool advance)
const override;
188 int writeHeader(
BasicIo& outIo)
const override;
193 static const byte blank_[];
222 [[nodiscard]] std::string
mimeType()
const override;
228 bool isThisType(
BasicIo& iIo,
bool advance)
const override;
232 int writeHeader(
BasicIo& outIo)
const override;
237 static constexpr char exiv2Id_[] =
"Exiv2";
238 static constexpr byte blank_[] = {0xff, 0x01,
'E',
'x',
'i',
'v',
'2', 0xff, 0xd9};
An interface for simple binary IO.
Definition basicio.hpp:35
std::unique_ptr< BasicIo > UniquePtr
BasicIo auto_ptr type.
Definition basicio.hpp:38
Helper class to access Exiv2 files.
Definition jpgimage.hpp:197
Abstract base class defining the interface for an image. This is the top-level interface to the Exiv2...
Definition image.hpp:50
std::unique_ptr< Image > UniquePtr
Image auto_ptr type.
Definition image.hpp:53
Abstract helper base class to access JPEG images.
Definition jpgimage.hpp:21
virtual int writeHeader(BasicIo &oIo) const =0
Writes the image header (aka signature) to the BasicIo instance.
std::string sof_encoding_process_
image encoding process
Definition jpgimage.hpp:90
virtual bool isThisType(BasicIo &iIo, bool advance) const =0
Determine if the content of the BasicIo instance is of the type supported by this class.
Class to access JPEG images.
Definition jpgimage.hpp:133
int numColorComponents() const
Get the number of color components of the JPEG Image.
Definition jpgimage.hpp:162
std::string encodingProcess() const
Get the encoding process of the JPEG Image derived from the Start of Frame (SOF) markers.
Definition jpgimage.hpp:168
Error class for exceptions, log message class.
Class CrwImage to access Canon CRW images. References: The Canon RAW (CRW) File Format by Phil Harv...
Definition asfvideo.hpp:15
PrintStructureOption
Options for printStructure.
Definition image.hpp:38
EXIV2API bool isExvType(BasicIo &iIo, bool advance)
Check if the file iIo is an EXV file.
Definition jpgimage.cpp:1060
ErrorCode
Complete list of all Exiv2 error codes.
Definition error.hpp:162
EXIV2API Image::UniquePtr newJpegInstance(BasicIo::UniquePtr io, bool create)
Create a new JpegImage instance and return an auto-pointer to it. Caller owns the returned object and...
Definition jpgimage.cpp:1005
EXIV2API Image::UniquePtr newExvInstance(BasicIo::UniquePtr io, bool create)
Create a new ExvImage instance and return an auto-pointer to it. Caller owns the returned object and ...
Definition jpgimage.cpp:1053
ImageType
Supported Image Formats.
Definition image_types.hpp:8
EXIV2API bool isJpegType(BasicIo &iIo, bool advance)
Check if the file iIo is a JPEG image.
Definition jpgimage.cpp:1013
Utility class containing a character array. All it does is to take care of memory allocation and dele...
Definition types.hpp:124
List of TIFF compression to MIME type mappings.
Definition tiffimage.cpp:47