ACloudViewer  3.9.4
A Modern Library for 3D Data Processing
PyPrintLogger.cpp
Go to the documentation of this file.
1 // ----------------------------------------------------------------------------
2 // - CloudViewer: www.cloudViewer.org -
3 // ----------------------------------------------------------------------------
4 // Copyright (c) 2018-2024 www.cloudViewer.org
5 // SPDX-License-Identifier: MIT
6 // ----------------------------------------------------------------------------
7 
8 #include "PyPrintLogger.h"
9 
10 void PyPrintLogger::logMessage(const QString &message, int level)
11 {
12  std::lock_guard<std::mutex> guard(m_lock);
13  const std::string stdMsg = message.toStdString();
14  py::print(stdMsg.c_str());
15 }
void logMessage(const QString &message, int level) override
Generic message logging method.