diff --git a/include/exiv2/xmp_exiv2.hpp b/include/exiv2/xmp_exiv2.hpp index af8d092c..ec3d02c6 100644 --- a/include/exiv2/xmp_exiv2.hpp +++ b/include/exiv2/xmp_exiv2.hpp @@ -10,6 +10,8 @@ #include "metadatum.hpp" #include "properties.hpp" +#include + // ***************************************************************************** // namespace extensions namespace Exiv2 { @@ -312,7 +314,7 @@ class EXIV2API XmpParser { @param pLockData Pointer to the pLockData passed to initialize() @param lockUnlock Indicates whether to lock (true) or unlock (false) */ - using XmpLockFct = void (*)(void* pLockData, bool lockUnlock); + using XmpLockFct = std::function; /*! @brief Initialize the XMP Toolkit. diff --git a/src/crwimage_int.hpp b/src/crwimage_int.hpp index f5333498..6da5ecfa 100644 --- a/src/crwimage_int.hpp +++ b/src/crwimage_int.hpp @@ -26,10 +26,10 @@ struct CrwSubDir; // type definitions //! Function pointer for functions to decode Exif tags from a CRW entry -using CrwDecodeFct = void (*)(const CiffComponent&, const CrwMapping*, Image&, ByteOrder); +using CrwDecodeFct = std::function; //! Function pointer for functions to encode CRW entries from Exif tags -using CrwEncodeFct = void (*)(const Image&, const CrwMapping*, CiffHeader*); +using CrwEncodeFct = std::function; //! Stack to hold a path of CRW directories using CrwDirs = std::stack; @@ -501,7 +501,7 @@ struct CrwMapping { //@{ //! Default constructor CrwMapping(uint16_t crwTagId, uint16_t crwDir, uint32_t size, uint16_t tag, Internal::IfdId ifdId, - CrwDecodeFct toExif, CrwEncodeFct fromExif) : + const CrwDecodeFct& toExif, const CrwEncodeFct& fromExif) : crwTagId_(crwTagId), crwDir_(crwDir), size_(size),