13 Vector posSum(0, 0, 0);
14 for (
auto det : dets) {
15 posSum += (*det).surface().position().basicVector();
27 std::pair<RectangularPlaneBounds*, GlobalVector> bo =
computeRectBounds(dets, tmpPlane);
28 return new Plane(meanPos + bo.second, rotation, newmp, bo.first);
32 const std::vector<const GeomDetUnit*>& dets,
const Plane& plane)
const {
34 std::vector<GlobalPoint> corners;
35 for (
auto det : dets) {
36 const Plane& bplane =
dynamic_cast<const Plane&
>(det->surface());
38 corners.insert(corners.end(), dc.begin(), dc.end());
42 for (std::vector<GlobalPoint>::const_iterator
i = corners.begin(), cend = corners.end();
i != cend; ++
i) {
61 std::pair<RectangularPlaneBounds*, GlobalVector>
result(
79 if (planeYAxis.
z() < 0)
87 if (n.
x() * meanPos.
x() + n.
y() * meanPos.
y() > 0) {
GlobalPoint toGlobal(const Point2DBase< Scalar, LocalTag > lp) const
Surface::RotationType computeRotation(const std::vector< const GeomDetUnit * > &dets, const Surface::PositionType &meanPos) const
Vector3DBase< typename PreciseFloatType< T, U >::Type, FrameTag > cross(const Vector3DBase< U, FrameTag > &v) const
Local3DVector LocalVector
ROOT::Math::Plane3D::Vector Vector
ResultType plane(const std::vector< const GeomDetUnit * > &dets) const
LocalPoint toLocal(const GlobalPoint &gp) const
std::pair< RectangularPlaneBounds *, GlobalVector > computeRectBounds(const std::vector< const GeomDetUnit * > &dets, const Plane &plane) const
static std::vector< GlobalPoint > corners(const Plane &)
TkRotation< float > RotationType