Reduce logging verbosity.

When user specifies Solver::Options::logging_type = SILENT,
ensure that the minimizer does not log anything.

Change-Id: I94e34dae504881ab36d4a66e6adb7a19a227363e
diff --git a/internal/ceres/minimizer.h b/internal/ceres/minimizer.h
index 3d9da99..ee77726 100644
--- a/internal/ceres/minimizer.h
+++ b/internal/ceres/minimizer.h
@@ -107,7 +107,7 @@
           options.line_search_sufficient_curvature_decrease;
       max_line_search_step_expansion =
           options.max_line_search_step_expansion;
-      is_silent = false;
+      is_silent = (options.logging_type == SILENT);
       evaluator = NULL;
       trust_region_strategy = NULL;
       jacobian = NULL;
diff --git a/internal/ceres/solver_impl.cc b/internal/ceres/solver_impl.cc
index a26ef9f..cf0e251 100644
--- a/internal/ceres/solver_impl.cc
+++ b/internal/ceres/solver_impl.cc
@@ -484,7 +484,7 @@
         "Terminating: Function tolerance reached. "
         "No non-constant parameter blocks found.";
     summary->termination_type = CONVERGENCE;
-    VLOG(1) << summary->message;
+    VLOG_IF(1, options.logging_type != SILENT) << summary->message;
 
     summary->initial_cost = summary->fixed_cost;
     summary->final_cost = summary->fixed_cost;
@@ -804,7 +804,7 @@
         "Terminating: Function tolerance reached. "
         "No non-constant parameter blocks found.";
     summary->termination_type = CONVERGENCE;
-    VLOG(1) << summary->message;
+    VLOG_IF(1, options.logging_type != SILENT) << summary->message;
 
     const double post_process_start_time = WallTimeInSeconds();
     SetSummaryFinalCost(summary);