18template <typename T, fl::size INLINED_SIZE> class FixedVector;
20template <typename T> class vector;
22template <typename T, fl::size INLINED_SIZE> class VectorN;
27template <typename T,
fl::size N> class
array;
115 template <fl::size INLINED_SIZE>
119 template <fl::size INLINED_SIZE>
128 template<
typename U, fl::size INLINED_SIZE>
132 template<
typename U, fl::size INLINED_SIZE>
141 template <fl::size INLINED_SIZE>
145 template <fl::size INLINED_SIZE>
153 template<
typename Container>
162 template<
typename Container>
172 template <fl::size N>
176 template <fl::size N>
181 template <
typename U, fl::size N>
185 template <
typename U, fl::size N>
191 template <fl::size ARRAYSIZE>
196 template <
typename U, fl::size ARRAYSIZE>
201 template <
typename U, fl::size ARRAYSIZE>
206 template <
typename U>
215 template <
typename Iterator>
311 template<fl::size Offset, fl::size Count = dynamic_extent>
323 for (fl::size i = 0; i <
mSize; ++i) {
361 if (
mSize != other.mSize)
return false;
362 for (fl::size i = 0; i <
mSize; ++i) {
363 if (!(
mData[i] == other.mData[i]))
return false;
369 return !(*
this == other);
373 fl::size min_size =
mSize < other.mSize ?
mSize : other.mSize;
374 for (fl::size i = 0; i < min_size; ++i) {
375 if (
mData[i] < other.mData[i])
return true;
376 if (other.mData[i] <
mData[i])
return false;
378 return mSize < other.mSize;
382 return !(other < *
this);
386 return other < *
this;
390 return !(*
this < other);
394 template <
typename U>
400 return static_cast<fl::size
>(
end -
begin);
410template <
typename T, fl::size Extent>
class span {
426 static constexpr fl::size
extent = Extent;
513 template<fl::size Offset, fl::size Count = dynamic_extent>
516 return span<T, Extent - Offset>(
mData + Offset, Extent - Offset);
539 for (fl::size i = 0; i < Extent; ++i) {
540 if (!(
mData[i] == other.mData[i]))
return false;
546 return !(*
this == other);
550 for (fl::size i = 0; i < Extent; ++i) {
551 if (
mData[i] < other.mData[i])
return true;
552 if (other.mData[i] <
mData[i])
return false;
558 return !(other < *
this);
562 return other < *
this;
566 return !(*
this < other);
576template<
typename T, fl::size Extent>
585 return span<const fl::u8, Extent * sizeof(T)>(
592template<
typename T, fl::size Extent>
601 return span<fl::u8, Extent * sizeof(T)>(
613 i32 bottomLeftX, i32 bottomLeftY, i32 topRightX,
617 mTopRight{topRightX, topRightY} {}
vec2< i32 > getParentCoord(i32 x_local, i32 y_local) const FL_NO_EXCEPT
T & at(i32 x, i32 y) FL_NO_EXCEPT
const T & at(i32 x, i32 y) const FL_NO_EXCEPT
MatrixSlice & operator=(const MatrixSlice &other) FL_NO_EXCEPT=default
T * operator[](i32 row) FL_NO_EXCEPT
MatrixSlice() FL_NO_EXCEPT=default
vec2< i32 > getLocalCoord(i32 x_world, i32 y_world) const FL_NO_EXCEPT
MatrixSlice(const MatrixSlice &other) FL_NO_EXCEPT=default
T & operator()(i32 x, i32 y) FL_NO_EXCEPT
A fixed-size array implementation similar to std::array.
static no test(...) FL_NO_EXCEPT
static constexpr bool value
static yes test(decltype(&C::data)) FL_NO_EXCEPT
static constexpr bool value
static yes test(decltype(&C::size)) FL_NO_EXCEPT
static no test(...) FL_NO_EXCEPT
typename fl::remove_cv< T >::type value_type
span(array< U, N > &arr) FL_NO_EXCEPT
const T * const_reverse_iterator
static constexpr fl::size extent
span< T, N > first() const FL_NO_EXCEPT
span(const span &other) FL_NO_EXCEPT
span & operator=(const span &other) FL_NO_EXCEPT
span(Container &c, typename fl::enable_if< has_data_and_size< Container >::value &&!fl::is_same< typename fl::decay< Container >::type, span< T, dynamic_extent > >::value &&!fl::is_base_of< span< T, dynamic_extent >, Container >::value >::type *=nullptr) FL_NO_EXCEPT
span(const VectorN< T, INLINED_SIZE > &vector) FL_NO_EXCEPT
const T * data() const FL_NO_EXCEPT
span(const fl::vector< T > &vector) FL_NO_EXCEPT
const_reverse_iterator rbegin() const FL_NO_EXCEPT
span< T, N > last() const FL_NO_EXCEPT
span< T, Count > subspan() const FL_NO_EXCEPT
const T & const_reference
reverse_iterator rend() FL_NO_EXCEPT
iterator end() FL_NO_EXCEPT
span(const FixedVector< U, INLINED_SIZE > &vector) FL_NO_EXCEPT
const_iterator end() const FL_NO_EXCEPT
span(VectorN< T, INLINED_SIZE > &vector) FL_NO_EXCEPT
span(const Container &c, typename fl::enable_if< has_data_and_size< Container >::value &&!fl::is_same< typename fl::decay< Container >::type, span< T, dynamic_extent > >::value &&!fl::is_base_of< span< T, dynamic_extent >, Container >::value >::type *=nullptr) FL_NO_EXCEPT
bool operator!=(const span< T, dynamic_extent > &other) const FL_NO_EXCEPT
span(fl::vector< T > &vector) FL_NO_EXCEPT
const_reverse_iterator rend() const FL_NO_EXCEPT
const_reverse_iterator crend() const FL_NO_EXCEPT
span(T *data, fl::size size) FL_NO_EXCEPT
T & operator[](fl::size index) FL_NO_EXCEPT
span< T, dynamic_extent > first(fl::size count) const FL_NO_EXCEPT
static fl::size pointer_range_size(U *begin, U *end) FL_NO_EXCEPT
span(T(&array)[ARRAYSIZE]) FL_NO_EXCEPT
const T & operator[](fl::size index) const FL_NO_EXCEPT
span(const VectorN< U, INLINED_SIZE > &vector) FL_NO_EXCEPT
const_iterator cbegin() const FL_NO_EXCEPT
span(Iterator begin, Iterator end, typename fl::enable_if<!fl::is_pointer< Iterator >::value >::type *=nullptr) FL_NO_EXCEPT
const T & front() const FL_NO_EXCEPT
const_iterator begin() const FL_NO_EXCEPT
reverse_iterator rbegin() FL_NO_EXCEPT
span< T, dynamic_extent > slice(fl::size start, fl::size end) const FL_NO_EXCEPT
bool operator<(const span< T, dynamic_extent > &other) const FL_NO_EXCEPT
bool pop_back() FL_NO_EXCEPT
span< T, dynamic_extent > slice(fl::size start) const FL_NO_EXCEPT
const_iterator cend() const FL_NO_EXCEPT
bool empty() const FL_NO_EXCEPT
bool operator==(const span< T, dynamic_extent > &other) const FL_NO_EXCEPT
span(const FixedVector< T, INLINED_SIZE > &vector) FL_NO_EXCEPT
span(FixedVector< T, INLINED_SIZE > &vector) FL_NO_EXCEPT
span(U *begin, U *end, typename fl::enable_if< fl::is_same< typename fl::remove_const< U >::type, typename fl::remove_const< T >::type >::value &&(!fl::is_const< U >::value||fl::is_const< T >::value)>::type *=nullptr) FL_NO_EXCEPT
bool pop_front() FL_NO_EXCEPT
span< T, dynamic_extent > last(fl::size count) const FL_NO_EXCEPT
const_reverse_iterator crbegin() const FL_NO_EXCEPT
bool operator<=(const span< T, dynamic_extent > &other) const FL_NO_EXCEPT
span< T, dynamic_extent > subspan(fl::size offset, fl::size count=dynamic_extent) const FL_NO_EXCEPT
span(U(&array)[ARRAYSIZE]) FL_NO_EXCEPT
iterator begin() FL_NO_EXCEPT
bool operator>=(const span< T, dynamic_extent > &other) const FL_NO_EXCEPT
fl::size size_bytes() const FL_NO_EXCEPT
span(array< T, N > &arr) FL_NO_EXCEPT
fl::size find(const T &value) const FL_NO_EXCEPT
span(const array< U, N > &arr) FL_NO_EXCEPT
span(const fl::vector< U > &vector) FL_NO_EXCEPT
fl::size length() const FL_NO_EXCEPT
const T & back() const FL_NO_EXCEPT
span(fl::initializer_list< value_type > init) FL_NO_EXCEPT=delete
span(const U(&array)[ARRAYSIZE]) FL_NO_EXCEPT
span(const array< T, N > &arr) FL_NO_EXCEPT
bool operator>(const span< T, dynamic_extent > &other) const FL_NO_EXCEPT
fl::size size() const FL_NO_EXCEPT
const_reverse_iterator crend() const FL_NO_EXCEPT
reverse_iterator rbegin() FL_NO_EXCEPT
const_iterator cend() const FL_NO_EXCEPT
span< T, Count > subspan() const FL_NO_EXCEPT
constexpr bool empty() const FL_NO_EXCEPT
span< T, N > first() const FL_NO_EXCEPT
const_iterator cbegin() const FL_NO_EXCEPT
const T & front() const FL_NO_EXCEPT
const T * data() const FL_NO_EXCEPT
const T & const_reference
span< T, dynamic_extent > subspan(fl::size offset, fl::size count=dynamic_extent) const FL_NO_EXCEPT
bool operator>(const span< T, Extent > &other) const FL_NO_EXCEPT
const T * const_reverse_iterator
T & operator[](fl::size index) FL_NO_EXCEPT
bool operator<=(const span< T, Extent > &other) const FL_NO_EXCEPT
const_iterator begin() const FL_NO_EXCEPT
span< T, dynamic_extent > last(fl::size count) const FL_NO_EXCEPT
span(const span &other) FL_NO_EXCEPT
const_iterator end() const FL_NO_EXCEPT
const_reverse_iterator crbegin() const FL_NO_EXCEPT
bool operator>=(const span< T, Extent > &other) const FL_NO_EXCEPT
const_reverse_iterator rend() const FL_NO_EXCEPT
iterator end() FL_NO_EXCEPT
reverse_iterator rend() FL_NO_EXCEPT
span(T(&array)[Extent]) FL_NO_EXCEPT
const T & operator[](fl::size index) const FL_NO_EXCEPT
constexpr fl::size size() const FL_NO_EXCEPT
const_reverse_iterator rbegin() const FL_NO_EXCEPT
constexpr fl::size size_bytes() const FL_NO_EXCEPT
span< T, N > last() const FL_NO_EXCEPT
span & operator=(const span &other) FL_NO_EXCEPT
span< T, dynamic_extent > first(fl::size count) const FL_NO_EXCEPT
bool operator==(const span< T, Extent > &other) const FL_NO_EXCEPT
const T & back() const FL_NO_EXCEPT
static constexpr fl::size extent
bool operator<(const span< T, Extent > &other) const FL_NO_EXCEPT
iterator begin() FL_NO_EXCEPT
bool operator!=(const span< T, Extent > &other) const FL_NO_EXCEPT
span(T *data, fl::size size) FL_NO_EXCEPT
typename fl::remove_cv< T >::type value_type
constexpr fl::size length() const FL_NO_EXCEPT
fl::size size() const FL_NO_EXCEPT
#define constexpr
Declares that it is possible to evaluate a value at compile time, introduced in C++11.
fl::UISlider offset("Offset", 0.0f, 0.0f, 1.0f, 0.01f)
void span_invalid_pointer_range() FL_NO_EXCEPT
Compile-time linker keep-alive hook for a single fl::Bus.
constexpr int type_rank< T >::value
VectorN< T, INLINED_SIZE > InlinedVector
void init(Context &ctx, int w, int h)
span< fl::u8,(Extent==dynamic_extent) ? dynamic_extent :(Extent *sizeof(T))> as_writable_bytes(span< T, Extent > &s) FL_NO_EXCEPT
constexpr enable_if< is_fixed_point< T >::value, T >::type clamp(T x, T lo, T hi) FL_NO_EXCEPT
span< const fl::u8,(Extent==dynamic_extent) ? dynamic_extent :(Extent *sizeof(T))> as_bytes(const span< T, Extent > &s) FL_NO_EXCEPT
InputGamut g FL_NO_EXCEPT
constexpr fl::size dynamic_extent
To bit_cast(const From &from) FL_NO_EXCEPT
Base definition for an LED controller.
typename conditional< is_array< U >::value, typename remove_extent< U >::type *, typename conditional< is_function< U >::value, typename add_pointer< U >::type, typename remove_cv< U >::type >::type >::type type
static constexpr bool value