Template Struct spectral_plot_t

Struct Documentation

template<std::size_t Bins = 512, std::size_t MaxChannels = 3>
struct spectral_plot_t

Public Functions

inline spectral_plot_t(std::string id) noexcept
inline spectral_plot_t(std::string id, const sensor::response::response_t &response, const range_t<wavenumber_t> &krange) noexcept
inline spectral_plot_t(std::string id, const spectrum::discrete_t &spectrum, const range_t<wavenumber_t> &krange) noexcept
inline spectral_plot_t(std::string id, const spectrum::spectrum_real_t &spectrum, const range_t<wavenumber_t> &krange) noexcept
inline spectral_plot_t(std::string id, const spectrum::spectrum_t &spectrum, const range_t<wavenumber_t> &krange) noexcept
inline void compute_spectrum_ticks(const range_t<wavelength_t> &range) noexcept

Public Members

std::int8_t channels = 0
std::array<f_t, MaxChannels * Bins> data
std::array<std::string, xticks_count> xtick_labels
std::array<const char*, xticks_count> xtick_labels_cstr
std::array<double, yticks_count> yticks
std::array<std::string, yticks_count> ytick_labels
std::array<const char*, yticks_count> ytick_labels_cstr
std::array<std::string, MaxChannels + 1> imgui_ids_strs
std::array<const char*, MaxChannels + 1> imgui_ids
bool new_data = true

Public Static Attributes

static constexpr auto bins = Bins
static constexpr bool has_xticks = true
static constexpr bool has_yticks = true
static constexpr auto xticks_count = 3
static constexpr auto yticks_count = 2
static constexpr std::array<double, xticks_count> xticks = {0 * (Bins - 1), .5 * (Bins - 1), 1 * (Bins - 1)}