本文整理汇总了C++中StatisticsVector::insert方法的典型用法代码示例。如果您正苦于以下问题:C++ StatisticsVector::insert方法的具体用法?C++ StatisticsVector::insert怎么用?C++ StatisticsVector::insert使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类StatisticsVector
的用法示例。
在下文中一共展示了StatisticsVector::insert方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: make
StatisticsVector StatisticsVector::make(
const string& name,
const Statistics& stats)
{
StatisticsVector vec;
vec.insert(name, stats);
return vec;
}
示例2: get_statistics
StatisticsVector Intersector::get_statistics() const
{
const uint64 total_ray_count = m_shading_ray_count + m_probe_ray_count;
Statistics intersection_stats;
intersection_stats.insert<uint64>("total rays", total_ray_count);
intersection_stats.insert(
auto_ptr<RayCountStatisticsEntry>(
new RayCountStatisticsEntry(
"shading rays",
m_shading_ray_count,
total_ray_count)));
intersection_stats.insert(
auto_ptr<RayCountStatisticsEntry>(
new RayCountStatisticsEntry(
"probe rays",
m_probe_ray_count,
total_ray_count)));
StatisticsVector vec;
vec.insert("intersection statistics", intersection_stats);
#ifdef FOUNDATION_BVH_ENABLE_TRAVERSAL_STATS
vec.insert(
"assembly tree intersection statistics",
m_assembly_tree_traversal_stats.get_statistics());
vec.insert(
"triangle tree intersection statistics",
m_triangle_tree_traversal_stats.get_statistics());
#endif
vec.insert(
"region tree access cache statistics",
make_dual_stage_cache_stats(m_region_tree_cache));
vec.insert(
"triangle tree access cache statistics",
make_dual_stage_cache_stats(m_triangle_tree_cache));
vec.insert(
"region kit access cache statistics",
make_dual_stage_cache_stats(m_region_kit_cache));
vec.insert(
"tessellation access cache statistics",
make_dual_stage_cache_stats(m_tess_cache));
return vec;
}