Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2019-04-17 07:17:24 +0300
committerCampbell Barton <ideasman42@gmail.com>2019-04-17 07:21:24 +0300
commite12c08e8d170b7ca40f204a5b0423c23a9fbc2c1 (patch)
tree8cf3453d12edb177a218ef8009357518ec6cab6a /source/blender/blenkernel/intern/subdiv_stats.c
parentb3dabc200a4b0399ec6b81f2ff2730d07b44fcaa (diff)
ClangFormat: apply to source, most of intern
Apply clang format as proposed in T53211. For details on usage and instructions for migrating branches without conflicts, see: https://wiki.blender.org/wiki/Tools/ClangFormat
Diffstat (limited to 'source/blender/blenkernel/intern/subdiv_stats.c')
-rw-r--r--source/blender/blenkernel/intern/subdiv_stats.c69
1 files changed, 26 insertions, 43 deletions
diff --git a/source/blender/blenkernel/intern/subdiv_stats.c b/source/blender/blenkernel/intern/subdiv_stats.c
index 8ea9e90ff75..56d08a591ec 100644
--- a/source/blender/blenkernel/intern/subdiv_stats.c
+++ b/source/blender/blenkernel/intern/subdiv_stats.c
@@ -29,67 +29,50 @@
void BKE_subdiv_stats_init(SubdivStats *stats)
{
- stats->topology_refiner_creation_time = 0.0;
- stats->subdiv_to_mesh_time = 0.0;
- stats->subdiv_to_mesh_geometry_time = 0.0;
- stats->evaluator_creation_time = 0.0;
- stats->evaluator_refine_time = 0.0;
- stats->subdiv_to_ccg_time = 0.0;
- stats->subdiv_to_ccg_elements_time = 0.0;
- stats->topology_compare_time = 0.0;
+ stats->topology_refiner_creation_time = 0.0;
+ stats->subdiv_to_mesh_time = 0.0;
+ stats->subdiv_to_mesh_geometry_time = 0.0;
+ stats->evaluator_creation_time = 0.0;
+ stats->evaluator_refine_time = 0.0;
+ stats->subdiv_to_ccg_time = 0.0;
+ stats->subdiv_to_ccg_elements_time = 0.0;
+ stats->topology_compare_time = 0.0;
}
void BKE_subdiv_stats_begin(SubdivStats *stats, eSubdivStatsValue value)
{
- stats->begin_timestamp_[value] = PIL_check_seconds_timer();
+ stats->begin_timestamp_[value] = PIL_check_seconds_timer();
}
void BKE_subdiv_stats_end(SubdivStats *stats, eSubdivStatsValue value)
{
- stats->values_[value] =
- PIL_check_seconds_timer() - stats->begin_timestamp_[value];
+ stats->values_[value] = PIL_check_seconds_timer() - stats->begin_timestamp_[value];
}
void BKE_subdiv_stats_reset(SubdivStats *stats, eSubdivStatsValue value)
{
- stats->values_[value] = 0.0;
+ stats->values_[value] = 0.0;
}
void BKE_subdiv_stats_print(const SubdivStats *stats)
{
-#define STATS_PRINT_TIME(stats, value, description) \
- do { \
- if ((stats)->value > 0.0) { \
- printf(" %s: %f (sec)\n", description, (stats)->value); \
- } \
- } while (false)
+#define STATS_PRINT_TIME(stats, value, description) \
+ do { \
+ if ((stats)->value > 0.0) { \
+ printf(" %s: %f (sec)\n", description, (stats)->value); \
+ } \
+ } while (false)
- printf("Subdivision surface statistics:\n");
+ printf("Subdivision surface statistics:\n");
- STATS_PRINT_TIME(stats,
- topology_refiner_creation_time,
- "Topology refiner creation time");
- STATS_PRINT_TIME(stats,
- subdiv_to_mesh_time,
- "Subdivision to mesh time");
- STATS_PRINT_TIME(stats,
- subdiv_to_mesh_geometry_time,
- " Geometry time");
- STATS_PRINT_TIME(stats,
- evaluator_creation_time,
- "Evaluator creation time");
- STATS_PRINT_TIME(stats,
- evaluator_refine_time,
- "Evaluator refine time");
- STATS_PRINT_TIME(stats,
- subdiv_to_ccg_time,
- "Subdivision to CCG time");
- STATS_PRINT_TIME(stats,
- subdiv_to_ccg_elements_time,
- " Elements time");
- STATS_PRINT_TIME(stats,
- topology_compare_time,
- "Topology comparison time");
+ STATS_PRINT_TIME(stats, topology_refiner_creation_time, "Topology refiner creation time");
+ STATS_PRINT_TIME(stats, subdiv_to_mesh_time, "Subdivision to mesh time");
+ STATS_PRINT_TIME(stats, subdiv_to_mesh_geometry_time, " Geometry time");
+ STATS_PRINT_TIME(stats, evaluator_creation_time, "Evaluator creation time");
+ STATS_PRINT_TIME(stats, evaluator_refine_time, "Evaluator refine time");
+ STATS_PRINT_TIME(stats, subdiv_to_ccg_time, "Subdivision to CCG time");
+ STATS_PRINT_TIME(stats, subdiv_to_ccg_elements_time, " Elements time");
+ STATS_PRINT_TIME(stats, topology_compare_time, "Topology comparison time");
#undef STATS_PRINT_TIME
}