[Bf-blender-cvs] [ea95ea644a9] master: Libmv: Avoid use of LOG(INFO) in solver

Sergey Sharybin noreply at git.blender.org
Mon Mar 1 17:01:20 CET 2021


Commit: ea95ea644a94ddda4fa7c7c234dffc33c48ef59d
Author: Sergey Sharybin
Date:   Tue Feb 23 16:43:01 2021 +0100
Branches: master
https://developer.blender.org/rBea95ea644a94ddda4fa7c7c234dffc33c48ef59d

Libmv: Avoid use of LOG(INFO) in solver

Usage of LOG(INFO) actually went against own guidelines in the
logging.h: the INFO is for messages which are to be printed
regardless of debug/verbosity settings.

===================================================================

M	intern/libmv/libmv/multiview/euclidean_resection.cc
M	intern/libmv/libmv/simple_pipeline/bundle.cc

===================================================================

diff --git a/intern/libmv/libmv/multiview/euclidean_resection.cc b/intern/libmv/libmv/multiview/euclidean_resection.cc
index 245b027fb7c..16a1a0caafa 100644
--- a/intern/libmv/libmv/multiview/euclidean_resection.cc
+++ b/intern/libmv/libmv/multiview/euclidean_resection.cc
@@ -758,7 +758,7 @@ bool EuclideanResectionPPnP(const Mat2X &x_camera,
     Z = Zmindiag.asDiagonal();
     E = Y - Z*PR;
     error = (E - E_old).norm();
-    LOG(INFO) << "PPnP error(" << (iteration++) << "): " << error;
+    LG << "PPnP error(" << (iteration++) << "): " << error;
     E_old = E;
   }
   *t = -*R*c;
diff --git a/intern/libmv/libmv/simple_pipeline/bundle.cc b/intern/libmv/libmv/simple_pipeline/bundle.cc
index d62f0ebe94f..25a63c87e1b 100644
--- a/intern/libmv/libmv/simple_pipeline/bundle.cc
+++ b/intern/libmv/libmv/simple_pipeline/bundle.cc
@@ -352,7 +352,7 @@ struct ReprojectionErrorInvertIntrinsics {
 // Print a message to the log which camera intrinsics are gonna to be optimized.
 void BundleIntrinsicsLogMessage(const int bundle_intrinsics) {
   if (bundle_intrinsics == BUNDLE_NO_INTRINSICS) {
-    LOG(INFO) << "Bundling only camera positions.";
+    LG << "Bundling only camera positions.";
   } else {
     std::string bundling_message = "";
 
@@ -373,7 +373,7 @@ void BundleIntrinsicsLogMessage(const int bundle_intrinsics) {
     APPEND_BUNDLING_INTRINSICS("p1",     BUNDLE_TANGENTIAL_P1);
     APPEND_BUNDLING_INTRINSICS("p2",     BUNDLE_TANGENTIAL_P2);
 
-    LOG(INFO) << "Bundling " << bundling_message << ".";
+    LG << "Bundling " << bundling_message << ".";
   }
 }



More information about the Bf-blender-cvs mailing list