Skip to content

Commit

Permalink
fix: SVG portal arrow drawing (#2728)
Browse files Browse the repository at this point in the history
Was approved - will merge.
  • Loading branch information
asalzburger authored Nov 29, 2023
1 parent 103a2c9 commit ee8375f
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Plugins/ActSVG/src/PortalSvgConverter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ std::vector<Acts::Svg::ProtoLink> convertMultiLink(
if constexpr (decltype(multiLink.indexedUpdator)::grid_type::DIM == 1u) {
// Get the binning value
Acts::BinningValue bValue = casts[0u];
// Get the boundaries
// Get the boundaries - take care, they are in local coordinates
const auto& boundaries =
multiLink.indexedUpdator.grid.axes()[0u]->getBinEdges();

Expand All @@ -81,6 +81,8 @@ std::vector<Acts::Svg::ProtoLink> convertMultiLink(
refPosition.z());
} else if (bValue == Acts::binZ) {
position[2] = refC;
// correct to global
refC += surface.transform(gctx).translation().z();
} else if (bValue == Acts::binPhi) {
Acts::ActsScalar r = Acts::VectorHelpers::perp(refPosition);
position = Acts::Vector3(r * std::cos(refC), r * std::sin(refC),
Expand Down

0 comments on commit ee8375f

Please sign in to comment.