OSSIA
Open Scenario System for Interactive Application
ossia::detail Namespace Reference

Detailed Description

Utility functions taken from Jamoma TTBase.h

Classes

struct  domain_min_visitor_helper
 Min ///. More...
 
struct  domain_max_visitor_helper
 Max ///. More...
 
struct  destination_index_retriever
 The destination_index_retriever struct Get the value associated with an index in a list. If the index cannot be reached, an exception is thrown. More...
 

Typedefs

template<class T , std::size_t N>
using is_braces_constructible_n = decltype(test_is_braces_constructible_n< T >(std::make_index_sequence< N >{}))
 
template<class T >
using to_tuple_size = std::integral_constant< std::size_t, to_tuple_size_f< T >()>
 
using vec_behavior = ossia::static_vector< curve< double, float > *, 4 >
 
template<typename T >
using strong_value_impl_t = decltype(T::dataspace_value)
 
template<typename T , typename U >
using enable_if_both_iterable = std::enable_if_t< both_iterable< T, U > >
 
template<typename T , typename U >
using enable_if_first_iterable = std::enable_if_t< first_iterable< T, U > >
 
template<typename T , typename U >
using enable_if_second_iterable = std::enable_if_t< second_iterable< T, U > >
 
template<typename T , typename U >
using enable_if_neither_iterable = std::enable_if_t< neither_iterable< T, U > >
 
using unit_map = string_view_map< ossia::unit_t >
 
template<typename Unit >
using enable_if_multidimensional = std::enable_if_t< Unit::is_multidimensional::value >
 
using unit_pretty_text_map = ossia::hash_map< ossia::unit_t, std::string >
 
using float_minmax = std::pair< std::optional< float >, std::optional< float > >
 

Functions

void union_successor_sets (const std::vector< std::size_t > &s1, const std::vector< std::size_t > &s2, std::vector< std::size_t > &s3)
 
template<typename TheContainer >
subscript_t< TheContainer > subscript (TheContainer &c)
 
template<class T , std::size_t N, std::size_t... I>
constexpr std::array< std::remove_cv_t< T >, N > to_array_impl (T(&a)[N], std::index_sequence< I... >) noexcept
 
template<class T , std::size_t... I>
decltype(void(T{(I, std::declval< any_type >())...}), std::true_type{}) test_is_braces_constructible_n (std::index_sequence< I... >)
 
template<class , class... >
std::false_type test_is_braces_constructible_n (...)
 
template<class T , std::size_t L = 0u, std::size_t R = sizeof(T) + 1u>
constexpr std::size_t to_tuple_size_f ()
 
template<class T >
auto to_tuple_impl (T &&, std::integral_constant< std::size_t, 0 >) noexcept
 
template<class T , class = struct current_value, std::size_t = TO_TUPLE_MAX, class = struct required_value, std::size_t N>
auto to_tuple_impl (T &&, std::integral_constant< std::size_t, N >) noexcept
 
template<int N>
ossia::value make_filled_vec (ossia::curve_abstract *base_curve, ossia::curve_segment_type t, double position)
 
template<typename Dataspace , typename Unit >
std::string make_pretty_unit_text ()
 
template<typename InsertFun >
void list_units (InsertFun fun)
 
template<typename T >
LinearGainToDecibels (const T value)
 
template<typename T >
LinearGainToDecibelsClipped (const T value)
 
template<typename T >
DecibelsToLinearGain (const T value)
 
template<typename T >
DecibelsToLinearGainClipped (const T value)
 
template<typename T >
MidiToLinearGain (const T value)
 
template<typename T >
DecibelsToMidi (const T value)
 
template<typename T >
LinearGainToMidi (const T value)
 

Variables

template<typename T , typename U >
constexpr const bool both_iterable
 
template<typename T , typename U >
constexpr const bool first_iterable = is_array<strong_value_impl_t<T>>::value && !is_array<U>::value
 
template<typename T , typename U >
constexpr const bool second_iterable
 
template<typename T , typename U >
constexpr const bool neither_iterable = !is_array<strong_value_impl_t<T>>::value && !is_array<U>::value
 

Variable Documentation

◆ both_iterable

template<typename T , typename U >
constexpr const bool ossia::detail::both_iterable
constexpr
Initial value:
= is_array<strong_value_impl_t<T>>::value&& is_array<U>::value&&
ossia::value_trait<U>::ossia_enum
@ MAP
std::vector<value>

◆ second_iterable

template<typename T , typename U >
constexpr const bool ossia::detail::second_iterable
constexpr
Initial value:
= !is_array<strong_value_impl_t<T>>::value && is_array<U>::value
&& ossia::value_trait<U>::ossia_enum != ossia::val_type::MAP