File indexing completed on 2025-11-23 09:33:26
0001
0002
0003
0004
0005
0006
0007
0008
0009 #pragma once
0010
0011 #include "Acts/Definitions/Algebra.hpp"
0012 #include "Acts/Geometry/GeometryContext.hpp"
0013 #include "Acts/Plugins/ActSVG/SvgUtils.hpp"
0014 #include <actsvg/core.hpp>
0015 #include <actsvg/meta.hpp>
0016
0017 namespace Acts {
0018
0019 class Surface;
0020
0021 namespace Svg {
0022
0023 using ProtoSurface = actsvg::proto::surface<std::vector<Vector3>>;
0024
0025 namespace SurfaceConverter {
0026
0027
0028 struct Options {
0029
0030 Style style;
0031
0032 bool templateSurface = false;
0033 };
0034
0035
0036
0037
0038
0039
0040
0041
0042 ProtoSurface convert(const GeometryContext& gctx, const Surface& surface,
0043 const SurfaceConverter::Options& cOptions);
0044
0045 }
0046
0047 namespace View {
0048
0049
0050
0051
0052
0053
0054
0055 static inline actsvg::svg::object xy(const ProtoSurface& pSurface,
0056 const std::string& identification) {
0057 actsvg::views::x_y xyView;
0058 return actsvg::display::surface(identification, pSurface, xyView);
0059 }
0060
0061
0062
0063
0064
0065
0066
0067 static inline actsvg::svg::object zr(const ProtoSurface& pSurface,
0068 const std::string& identification) {
0069 actsvg::views::z_r zrView;
0070 return actsvg::display::surface(identification, pSurface, zrView);
0071 }
0072
0073
0074
0075
0076
0077
0078
0079 static inline actsvg::svg::object zphi(const ProtoSurface& pSurface,
0080 const std::string& identification) {
0081 actsvg::views::z_phi zphiView;
0082 return actsvg::display::surface(identification, pSurface, zphiView);
0083 }
0084
0085
0086
0087
0088
0089
0090
0091
0092
0093 static inline actsvg::svg::object zrphi(const ProtoSurface& pSurface,
0094 const std::string& identification) {
0095 actsvg::views::z_rphi zrphiView;
0096 zrphiView._fixed_r = pSurface._radii[0u];
0097 return actsvg::display::surface(identification, pSurface, zrphiView);
0098 }
0099
0100 }
0101
0102 namespace Sheet {
0103
0104
0105
0106
0107
0108
0109
0110 static inline actsvg::svg::object xy(const ProtoSurface& pSurface,
0111 const std::string& identification) {
0112 return actsvg::display::surface_sheet_xy(identification, pSurface);
0113 }
0114
0115 }
0116
0117 }
0118
0119 }