src/basics.h

changeset 300
3a4b132b8353
parent 299
cf9a854b56a9
child 309
d862721d19a3
equal deleted inserted replaced
299:cf9a854b56a9 300:3a4b132b8353
44 using opt = std::optional<T>; 44 using opt = std::optional<T>;
45 45
46 //! \brief Return type of qHash. unsigned int on Qt5, unsigned long on Qt6. 46 //! \brief Return type of qHash. unsigned int on Qt5, unsigned long on Qt6.
47 using hash_t = decltype(qHash(0)); 47 using hash_t = decltype(qHash(0));
48 48
49 //! \brief Index type of QVector, int on Qt5, qsizetype on Qt6
50 using index_t = QVector<int>::size_type;
51
49 Q_DECLARE_METATYPE(glm::vec3) 52 Q_DECLARE_METATYPE(glm::vec3)
50 Q_DECLARE_METATYPE(glm::mat4) 53 Q_DECLARE_METATYPE(glm::mat4)
51 54
52 //! \brief count the amount of elements in a basic array 55 //! \brief count the amount of elements in a basic array
53 template<typename T, int N> 56 template<typename T, int N>

mercurial