ACTS
Experiment-independent tracking
Loading...
Searching...
No Matches
detray::io::material_map_reader< DIM > Class Template Reference

Material map reader backend. More...

#include <detray/io/backend/material_map_reader.hpp>

Collaboration diagram for detray::io::material_map_reader< DIM >:
[legend]

Public Types

using bin_index_type = axis::multi_bin<dim>
 Multi-axis bin index type used by material grids.
using payload_type
 Payload type that the reader processes.

Static Public Member Functions

template<concepts::detector detector_t>
static void from_payload (detector_builder< typename detector_t::metadata, volume_builder > &det_builder, payload_type &&grids_data)
 Convert the material grids grids_data from their IO payload.

Static Public Attributes

static constexpr std::size_t dim {DIM()}
 Dimension of the material-grid bin index.
static constexpr std::string_view tag = "material_maps"
 Tag the reader as "material_maps".

Detailed Description

template<typename DIM = std::integral_constant<std::size_t, 2u>>
class detray::io::material_map_reader< DIM >

Material map reader backend.

Fills a detector_builder from a material detector_grids_payload

Member Typedef Documentation

◆ payload_type

template<typename DIM = std::integral_constant<std::size_t, 2u>>
using detray::io::material_map_reader< DIM >::payload_type
Initial value:
A payload for the grid collections of a detector.
Definition payloads.hpp:344

Payload type that the reader processes.

Member Function Documentation

◆ from_payload()

template<typename DIM = std::integral_constant<std::size_t, 2u>>
template<concepts::detector detector_t>
void detray::io::material_map_reader< DIM >::from_payload ( detector_builder< typename detector_t::metadata, volume_builder > & det_builder,
payload_type && grids_data )
static

Convert the material grids grids_data from their IO payload.

Template Parameters
detector_tDetector type being constructed.
Parameters
det_builderBuilder receiving the material grids.
grids_dataSerialized material-grid payload, consumed by the reader.