mirror of
https://git.mirrors.martin98.com/https://github.com/slic3r/Slic3r.git
synced 2025-08-15 14:25:56 +08:00
Start a simple Slic3r::Log to collect all of the debugging prints to a single area.
Upgrade backend to boost::log as needed.
This commit is contained in:
parent
d145ee3465
commit
ad46bc8106
24
xs/src/libslic3r/Log.hpp
Normal file
24
xs/src/libslic3r/Log.hpp
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
#ifndef slic3r_LOG_HPP
|
||||||
|
#define slic3r_LOG_HPP
|
||||||
|
|
||||||
|
#include <string>
|
||||||
|
|
||||||
|
namespace Slic3r {
|
||||||
|
|
||||||
|
class Log {
|
||||||
|
public:
|
||||||
|
static void fatal_error(std::string topic, std::wstring message) {
|
||||||
|
std::cerr << topic << ": ";
|
||||||
|
std::wcerr << message << std::endl;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void info(std::string topic, std::wstring message) {
|
||||||
|
std::clog << topic << ": ";
|
||||||
|
std::wclog << message << std::endl;
|
||||||
|
}
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
#endif // slic3r_LOG_HPP
|
Loading…
x
Reference in New Issue
Block a user