update retinexadd with master 4d6833c
This commit is contained in:
@@ -31,7 +31,7 @@ extern const Settings* settings;
|
||||
|
||||
ImProcCoordinator::ImProcCoordinator ()
|
||||
: orig_prev(NULL), oprevi(NULL), oprevl(NULL), nprevl(NULL), previmg(NULL), workimg(NULL),
|
||||
ncie(NULL), imgsrc(NULL), shmap(NULL), lastAwbEqual(0.), ipf(¶ms, true), scale(10),
|
||||
ncie(NULL), imgsrc(NULL), shmap(NULL), lastAwbEqual(0.), ipf(¶ms, true), monitorIntent(RI_RELATIVE), scale(10),
|
||||
highDetailPreprocessComputed(false), highDetailRawComputed(false), allocated(false),
|
||||
bwAutoR(-9000.f), bwAutoG(-9000.f), bwAutoB(-9000.f), CAMMean(0.),
|
||||
|
||||
@@ -782,6 +782,10 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
|
||||
}
|
||||
}
|
||||
}
|
||||
// Update the monitor color transform if necessary
|
||||
if (todo & M_MONITOR) {
|
||||
ipf.updateColorProfiles(params.icm, monitorProfile, monitorIntent);
|
||||
}
|
||||
|
||||
// process crop, if needed
|
||||
for (size_t i = 0; i < crops.size(); i++)
|
||||
@@ -796,7 +800,8 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
|
||||
|
||||
progress ("Conversion to RGB...", 100 * readyphase / numofphases);
|
||||
|
||||
if (todo != CROP && todo != MINUPDATE) {
|
||||
// if (todo != CROP && todo != MINUPDATE) {
|
||||
if ((todo != CROP && todo != MINUPDATE) || (todo & M_MONITOR)) {
|
||||
MyMutex::MyLock prevImgLock(previmg->getMutex());
|
||||
|
||||
try {
|
||||
@@ -806,13 +811,13 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
|
||||
|
||||
if(settings->HistogramWorking) {
|
||||
Glib::ustring workProfile = params.icm.working;
|
||||
workimg = ipf.lab2rgb (nprevl, 0, 0, pW, pH, workProfile, true);
|
||||
workimg = ipf.lab2rgb (nprevl, 0, 0, pW, pH, workProfile, RI_RELATIVE, true); // HOMBRE: was RELATIVE by default in lab2rgb, is it safe to assume we have to use it again ?
|
||||
} else {
|
||||
if (params.icm.output == "" || params.icm.output == ColorManagementParams::NoICMString) {
|
||||
if (params.icm.output.empty() || params.icm.output == ColorManagementParams::NoICMString) {
|
||||
outProfile = "sRGB";
|
||||
}
|
||||
|
||||
workimg = ipf.lab2rgb (nprevl, 0, 0, pW, pH, outProfile, false);
|
||||
workimg = ipf.lab2rgb (nprevl, 0, 0, pW, pH, outProfile, params.icm.outputIntent, false);
|
||||
}
|
||||
} catch(char * str) {
|
||||
progress ("Error converting file...", 0);
|
||||
@@ -1128,6 +1133,17 @@ void ImProcCoordinator::getAutoCrop (double ratio, int &x, int &y, int &w, int &
|
||||
y = (fullh - h) / 2;
|
||||
}
|
||||
|
||||
void ImProcCoordinator::setMonitorProfile (const Glib::ustring& profile, RenderingIntent intent)
|
||||
{
|
||||
monitorProfile = profile;
|
||||
monitorIntent = intent;
|
||||
}
|
||||
|
||||
void ImProcCoordinator::getMonitorProfile (Glib::ustring& profile, RenderingIntent& intent) const
|
||||
{
|
||||
profile = monitorProfile;
|
||||
intent = monitorIntent;
|
||||
}
|
||||
|
||||
void ImProcCoordinator::saveInputICCReference (const Glib::ustring& fname, bool apply_wb)
|
||||
{
|
||||
|
Reference in New Issue
Block a user