merge with dev
This commit is contained in:
@@ -37,6 +37,7 @@
|
||||
#include "rtimage.h"
|
||||
#include "version.h"
|
||||
#include "extprog.h"
|
||||
#include "dynamicprofile.h"
|
||||
|
||||
#ifndef WIN32
|
||||
#include <glibmm/fileutils.h>
|
||||
@@ -182,7 +183,7 @@ int main (int argc, char **argv)
|
||||
bool consoleOpened = false;
|
||||
|
||||
// suppression of annoying error boxes
|
||||
SetErrorMode(SEM_FAILCRITICALERRORS | SEM_NOGPFAULTERRORBOX | SEM_NOOPENFILEERRORBOX);
|
||||
SetErrorMode (SEM_FAILCRITICALERRORS | SEM_NOGPFAULTERRORBOX | SEM_NOOPENFILEERRORBOX);
|
||||
|
||||
if (argc > 1 || options.rtSettings.verbose) {
|
||||
if (options.rtSettings.verbose || ( !Glib::file_test (fname_to_utf8 (argv[1]), Glib::FILE_TEST_EXISTS ) && !Glib::file_test (fname_to_utf8 (argv[1]), Glib::FILE_TEST_IS_DIR))) {
|
||||
@@ -208,8 +209,8 @@ int main (int argc, char **argv)
|
||||
SetConsoleCtrlHandler ( NULL, true );
|
||||
// Set title of console
|
||||
char consoletitle[128];
|
||||
sprintf(consoletitle, "RawTherapee %s Console", RTVERSION);
|
||||
SetConsoleTitle(consoletitle);
|
||||
sprintf (consoletitle, "RawTherapee %s Console", RTVERSION);
|
||||
SetConsoleTitle (consoletitle);
|
||||
// increase size of screen buffer
|
||||
COORD c;
|
||||
c.X = 200;
|
||||
@@ -717,7 +718,7 @@ int processLineParams ( int argc, char **argv )
|
||||
rawParams = new rtengine::procparams::PartialProfile (true, true);
|
||||
Glib::ustring profPath = options.findProfilePath (options.defProfRaw);
|
||||
|
||||
if (options.is_defProfRawMissing() || profPath.empty() || rawParams->load (profPath == DEFPROFILE_INTERNAL ? DEFPROFILE_INTERNAL : Glib::build_filename (profPath, options.defProfRaw.substr (5) + paramFileExtension))) {
|
||||
if (options.is_defProfRawMissing() || profPath.empty() || (profPath != DEFPROFILE_DYNAMIC && rawParams->load (profPath == DEFPROFILE_INTERNAL ? DEFPROFILE_INTERNAL : Glib::build_filename (profPath, options.defProfRaw.substr (5) + paramFileExtension)))) {
|
||||
std::cerr << "Error: default raw processing profile not found" << std::endl;
|
||||
rawParams->deleteInstance();
|
||||
delete rawParams;
|
||||
@@ -728,7 +729,7 @@ int processLineParams ( int argc, char **argv )
|
||||
imgParams = new rtengine::procparams::PartialProfile (true);
|
||||
profPath = options.findProfilePath (options.defProfImg);
|
||||
|
||||
if (options.is_defProfImgMissing() || profPath.empty() || imgParams->load (profPath == DEFPROFILE_INTERNAL ? DEFPROFILE_INTERNAL : Glib::build_filename (profPath, options.defProfImg.substr (5) + paramFileExtension))) {
|
||||
if (options.is_defProfImgMissing() || profPath.empty() || (profPath != DEFPROFILE_DYNAMIC && imgParams->load (profPath == DEFPROFILE_INTERNAL ? DEFPROFILE_INTERNAL : Glib::build_filename (profPath, options.defProfImg.substr (5) + paramFileExtension)))) {
|
||||
std::cerr << "Error: default non-raw processing profile not found" << std::endl;
|
||||
imgParams->deleteInstance();
|
||||
delete imgParams;
|
||||
@@ -800,9 +801,21 @@ int processLineParams ( int argc, char **argv )
|
||||
|
||||
if (useDefault) {
|
||||
if (isRaw) {
|
||||
if (options.defProfRaw == DEFPROFILE_DYNAMIC) {
|
||||
rawParams->deleteInstance();
|
||||
delete rawParams;
|
||||
rawParams = loadDynamicProfile (ii->getMetaData());
|
||||
}
|
||||
|
||||
std::cout << " Merging default raw processing profile" << std::endl;
|
||||
rawParams->applyTo (¤tParams);
|
||||
} else {
|
||||
if (options.defProfImg == DEFPROFILE_DYNAMIC) {
|
||||
imgParams->deleteInstance();
|
||||
delete imgParams;
|
||||
imgParams = loadDynamicProfile (ii->getMetaData());
|
||||
}
|
||||
|
||||
std::cout << " Merging default non-raw processing profile" << std::endl;
|
||||
imgParams->applyTo (¤tParams);
|
||||
}
|
||||
|
Reference in New Issue
Block a user