|   | 
 | |||
File indexing completed on 2025-10-29 07:53:44
0001 // This file is part of the ACTS project. 0002 // 0003 // Copyright (C) 2016 CERN for the benefit of the ACTS project 0004 // 0005 // This Source Code Form is subject to the terms of the Mozilla Public 0006 // License, v. 2.0. If a copy of the MPL was not distributed with this 0007 // file, You can obtain one at https://mozilla.org/MPL/2.0/. 0008 0009 #pragma once 0010 0011 #include "Acts/Material/MaterialSlab.hpp" 0012 0013 namespace Acts { 0014 0015 class Material; 0016 0017 /// Accumulate and average volume-based material properties. 0018 /// 0019 /// This class is intended to be used during the mapping process. 0020 class AccumulatedVolumeMaterial { 0021 public: 0022 /// Add one entry with the given material properties. 0023 /// @param mat The material slab to accumulate 0024 void accumulate(const MaterialSlab& mat); 0025 0026 /// Compute the average material collected so far. 0027 /// 0028 /// @returns Vacuum properties if no matter has been accumulated yet. 0029 const Material& average() { return m_average.material(); } 0030 0031 private: 0032 MaterialSlab m_average = MaterialSlab::Nothing(); 0033 }; 0034 0035 } // namespace Acts
| [ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] | 
| This page was automatically generated by the 2.3.7 LXR engine.The LXR team |     |