added basic integration of lensfun
so far only distortion correction, and no GUI yet
This commit is contained in:
@@ -169,6 +169,7 @@ if(WIN32)
|
||||
${GLIBMM_INCLUDE_DIRS}
|
||||
${GTKMM_INCLUDE_DIRS}
|
||||
${GTK_INCLUDE_DIRS}
|
||||
${LENSFUN_INCLUDE_DIRS}
|
||||
)
|
||||
link_directories(. "${PROJECT_SOURCE_DIR}/rtexif"
|
||||
${EXTRA_LIBDIR}
|
||||
@@ -194,6 +195,7 @@ else()
|
||||
${GTK_INCLUDE_DIRS}
|
||||
${IPTCDATA_INCLUDE_DIRS}
|
||||
${LCMS_INCLUDE_DIRS}
|
||||
${LENSFUN_INCLUDE_DIRS}
|
||||
)
|
||||
link_directories(${EXTRA_LIBDIR}
|
||||
${CANBERRA-GTK_LIBRARY_DIRS}
|
||||
@@ -251,6 +253,7 @@ target_link_libraries(rth rtengine
|
||||
${PNG_LIBRARIES}
|
||||
${TIFF_LIBRARIES}
|
||||
${ZLIB_LIBRARIES}
|
||||
${LENSFUN_LIBRARIES}
|
||||
)
|
||||
|
||||
target_link_libraries(rth-cli rtengine
|
||||
@@ -270,6 +273,7 @@ target_link_libraries(rth-cli rtengine
|
||||
${PNG_LIBRARIES}
|
||||
${TIFF_LIBRARIES}
|
||||
${ZLIB_LIBRARIES}
|
||||
${LENSFUN_LIBRARIES}
|
||||
)
|
||||
|
||||
# Install executables
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
|
||||
#include <glibmm.h>
|
||||
#include "options.h"
|
||||
#include "rtengine.h"
|
||||
#include "../rtengine/rtengine.h"
|
||||
|
||||
class CacheImageData: public rtengine::ImageMetaData
|
||||
{
|
||||
@@ -89,9 +89,9 @@ public:
|
||||
bool hasExif() const { return false; }
|
||||
const rtexif::TagDirectory *getExifData() const { return NULL; }
|
||||
bool hasIPTC() const { return false; }
|
||||
const procparams::IPTCPairs getIPTCData () const { return procparams::IPTCPairs(); }
|
||||
const rtengine::procparams::IPTCPairs getIPTCData () const { return rtengine::procparams::IPTCPairs(); }
|
||||
struct tm getDateTime () const { struct tm ret; return ret; }
|
||||
time_t getDateTimeAsTS() const { time_t ret; return ret; }
|
||||
time_t getDateTimeAsTS() const { return time_t(-1); }
|
||||
int getISOSpeed() const { return iso; }
|
||||
double getFNumber() const { return fnumber; }
|
||||
double getFocalLen() const { return focalLen; }
|
||||
|
||||
@@ -291,6 +291,11 @@ void ParamsEdited::set (bool v)
|
||||
lensProf.useDist = v;
|
||||
lensProf.useVign = v;
|
||||
lensProf.useCA = v;
|
||||
lensProf.useLensfun = v;
|
||||
lensProf.lfAutoMatch = v;
|
||||
lensProf.lfCameraMake = v;
|
||||
lensProf.lfCameraModel = v;
|
||||
lensProf.lfLens = v;
|
||||
perspective.horizontal = v;
|
||||
perspective.vertical = v;
|
||||
gradient.enabled = v;
|
||||
@@ -825,6 +830,11 @@ void ParamsEdited::initFrom (const std::vector<rtengine::procparams::ProcParams>
|
||||
lensProf.useDist = lensProf.useDist && p.lensProf.useDist == other.lensProf.useDist;
|
||||
lensProf.useVign = lensProf.useVign && p.lensProf.useVign == other.lensProf.useVign;
|
||||
lensProf.useCA = lensProf.useCA && p.lensProf.useCA == other.lensProf.useCA;
|
||||
lensProf.useLensfun = lensProf.useLensfun && p.lensProf.useLensfun == other.lensProf.useLensfun;
|
||||
lensProf.lfAutoMatch = lensProf.lfAutoMatch && p.lensProf.lfAutoMatch == other.lensProf.lfAutoMatch;
|
||||
lensProf.lfCameraMake = lensProf.lfCameraMake && p.lensProf.lfCameraMake == other.lensProf.lfCameraMake;
|
||||
lensProf.lfCameraModel = lensProf.lfCameraModel && p.lensProf.lfCameraModel == other.lensProf.lfCameraModel;
|
||||
lensProf.lfLens = lensProf.lfLens && p.lensProf.lfLens == other.lensProf.lfLens;
|
||||
perspective.horizontal = perspective.horizontal && p.perspective.horizontal == other.perspective.horizontal;
|
||||
perspective.vertical = perspective.vertical && p.perspective.vertical == other.perspective.vertical;
|
||||
gradient.enabled = gradient.enabled && p.gradient.enabled == other.gradient.enabled;
|
||||
|
||||
@@ -428,6 +428,7 @@ class LensProfParamsEdited
|
||||
{
|
||||
public:
|
||||
bool lcpFile, useDist, useVign, useCA;
|
||||
bool useLensfun, lfAutoMatch, lfCameraMake, lfCameraModel, lfLens;
|
||||
|
||||
bool isUnchanged() const;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user