17 namespace ActsExamples {
27 namespace po = boost::program_options;
28 opt.add_options()(
"obj-precision", po::value<int>()->default_value(6),
29 "Floating number output precision.")(
30 "obj-scalor", po::value<double>()->default_value(1.),
31 "Optional scaling from Acts units to output units.")(
34 "View configuration of container volumes (vis/novis, r, g, b, trimesh).")(
36 po::value<Integers<5>>()->default_value({{1, 220, 220, 0, 0}}),
37 "View configuration of navigation volumes (vis/novis, r, g, b, "
40 po::value<Integers<5>>()->default_value({{1, 100, 180, 240, 0}}),
41 "View configuration of layer structures (vis/novis, r, g, b, trimesh).")(
43 po::value<Integers<5>>()->default_value({{1, 0, 180, 240, 0}}),
44 "View configuration of sensitive surfaces (vis/novis, r, g, b, "
47 po::value<Integers<5>>()->default_value({{1, 240, 280, 0, 0}}),
48 "View configuration of sensitive surfaces (vis/novis, r, g, "
51 po::value<Integers<5>>()->default_value({{1, 220, 0, 0, 0}}),
52 "View configuration of grid structures (vis/novis, r, g, b, trimesh).")(
53 "obj-grid-offset", po::value<double>()->default_value(0.),
54 "View offset of grid values.")(
"obj-grid-thickness",
55 po::value<double>()->default_value(0.5),
56 "Thickness of grid objects.");
62 const boost::program_options::variables_map& vm) {
63 namespace po = boost::program_options;
67 objTgConfig.
outputScalor = vm[
"obj-scalor"].template as<double>();
71 auto cview = vm[vname].template as<Integers<5>>();
72 if (not cview.empty()) {
74 viewCfg.visible =
false;
75 }
else if (cview.size() > 3) {
76 viewCfg.color = {cview[1], cview[2], cview[3]};
77 if (cview.size() > 4 and cview[4] != 0) {
78 viewCfg.triangulate =
true;
87 setView(
"obj-passive-view", objTgConfig.
passiveView);
88 setView(
"obj-grid-view", objTgConfig.
gridView);
89 objTgConfig.
gridView.
offset = vm[
"obj-grid-offset"].template as<double>();
91 vm[
"obj-grid-thickness"].template as<double>();