Tidy and fix logging.
[dcpomatic.git] / src / lib / cross.cc
index 4991d9ae38e3fef519e4ec297c8a021c903e0eb2..61b150a3b68fe05526a8a81aa60ff024a414cc6c 100644 (file)
@@ -1,5 +1,5 @@
 /*
-    Copyright (C) 2012-2015 Carl Hetherington <cth@carlh.net>
+    Copyright (C) 2012-2018 Carl Hetherington <cth@carlh.net>
 
     This file is part of DCP-o-matic.
 
@@ -21,6 +21,7 @@
 #include "cross.h"
 #include "compose.hpp"
 #include "log.h"
+#include "dcpomatic_log.h"
 #include "config.h"
 #include "exceptions.h"
 extern "C" {
@@ -53,10 +54,6 @@ extern "C" {
 
 #include "i18n.h"
 
-#define LOG_GENERAL(...) log->log (String::compose (__VA_ARGS__), LogEntry::TYPE_GENERAL);
-#define LOG_ERROR(...) log->log (String::compose (__VA_ARGS__), LogEntry::TYPE_ERROR);
-#define LOG_ERROR_NC(...) log->log (__VA_ARGS__, LogEntry::TYPE_ERROR);
-
 using std::pair;
 using std::list;
 using std::ifstream;
@@ -182,7 +179,7 @@ shared_path ()
 }
 
 void
-run_ffprobe (boost::filesystem::path content, boost::filesystem::path out, shared_ptr<Log> log)
+run_ffprobe (boost::filesystem::path content, boost::filesystem::path out)
 {
 #ifdef DCPOMATIC_WINDOWS
        SECURITY_ATTRIBUTES security;
@@ -414,6 +411,12 @@ start_batch_converter (boost::filesystem::path dcpomatic)
        start_tool (dcpomatic, "dcpomatic2_batch", "DCP-o-matic\\ 2\\ Batch\\ Converter.app");
 }
 
+void
+start_player (boost::filesystem::path dcpomatic)
+{
+       start_tool (dcpomatic, "dcpomatic2_player", "DCP-o-matic\\ 2\\ Player.app");
+}
+
 uint64_t
 thread_id ()
 {