Vector of three elements of type 'int'. More...
#include <helios_vector_types.h>
Public Member Functions | |
constexpr | int3 () |
Default constructor. | |
int3 (const std::vector< int > &v) | |
Construct int3 from a vector of ints. | |
constexpr | int3 (const int v[3]) |
Construct int3 from an array of ints. | |
constexpr | int3 (int v0, int v1, int v2) |
Construct int3 from three ints. | |
constexpr int3 | operator+ (const int3 &a) const noexcept |
Add two int3 vectors. | |
int3 & | operator+= (const int3 &a) noexcept |
Increment int3 vector. | |
int3 & | operator-= (const int3 &a) noexcept |
Decrement int3 vector. | |
constexpr int3 | operator- (const int3 &a) const noexcept |
Subtract two int3 vectors. | |
constexpr bool | operator== (const int3 &a) const noexcept |
Equality for all elements. | |
constexpr bool | operator!= (const int3 &a) const noexcept |
Inequality for all elements. | |
constexpr int3 | operator- () const noexcept |
Multiply each element by -1. | |
Data Fields | |
int | x |
First element in vector. | |
int | y |
Second element in vector. | |
int | z |
Third element in vector. | |
Friends | |
std::ostream & | operator<< (std::ostream &os, const helios::int3 &vec) |
Write int3 to output stream. | |
Vector of three elements of type 'int'.
Definition at line 147 of file helios_vector_types.h.
|
inlineconstexpr |
Default constructor.
Definition at line 158 of file helios_vector_types.h.
|
inlineexplicit |
Construct int3 from a vector of ints.
Definition at line 162 of file helios_vector_types.h.
|
inlineexplicitconstexpr |
Construct int3 from an array of ints.
Definition at line 171 of file helios_vector_types.h.
|
inlineconstexpr |
Construct int3 from three ints.
Definition at line 175 of file helios_vector_types.h.
|
constexprnoexcept |
Inequality for all elements.
Definition at line 235 of file helios_vector_types.h.
Add two int3 vectors.
Definition at line 209 of file helios_vector_types.h.
Increment int3 vector.
Definition at line 213 of file helios_vector_types.h.
|
constexprnoexcept |
Multiply each element by -1.
Definition at line 239 of file helios_vector_types.h.
Subtract two int3 vectors.
Definition at line 227 of file helios_vector_types.h.
Decrement int3 vector.
Definition at line 220 of file helios_vector_types.h.
|
constexprnoexcept |
Equality for all elements.
Definition at line 231 of file helios_vector_types.h.
|
friend |
Write int3 to output stream.
Definition at line 194 of file helios_vector_types.h.
int helios::int3::x |
First element in vector.
Definition at line 150 of file helios_vector_types.h.
int helios::int3::y |
Second element in vector.
Definition at line 152 of file helios_vector_types.h.
int helios::int3::z |
Third element in vector.
Definition at line 154 of file helios_vector_types.h.