Skip to content

Commit b7bd85f

Browse files
committed
Minor improvement to verbose timing in SOP_OpenVDB_Sample_Points.cc
Signed-off-by: Nick Avramoussis <[email protected]>
1 parent ce514d9 commit b7bd85f

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

openvdb_houdini/openvdb_houdini/SOP_OpenVDB_Sample_Points.cc

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -705,12 +705,11 @@ SOP_OpenVDB_Sample_Points::Cache::cookVDBSop(OP_Context& context)
705705
}
706706
}
707707

708-
// timing: end time
709-
auto duration = std::chrono::duration_cast<std::chrono::milliseconds>(
710-
std::chrono::steady_clock::now() - time_start);
711-
const double seconds = double(duration.count()) / 1000.0;
712-
713708
if (verbose) {
709+
// timing: end time
710+
auto duration = std::chrono::duration_cast<std::chrono::milliseconds>(
711+
std::chrono::steady_clock::now() - time_start);
712+
const double seconds = double(duration.count()) / 1000.0;
714713
std::cout << "Sampling " << nPoints + nVDBPoints << " points in "
715714
<< numVectorGrids << " vector grid" << (numVectorGrids == 1 ? "" : "s")
716715
<< " and " << numScalarGrids << " scalar grid"

0 commit comments

Comments
 (0)