Vector of four elements of type 'int'. More...
#include <helios_vector_types.h>
Public Member Functions | |
constexpr | int4 () |
Default constructor. | |
int4 (const std::vector< int > &v) | |
Construct int3 from a vector of ints. | |
constexpr | int4 (const int v[4]) |
Construct int4 from an array of ints. | |
constexpr | int4 (int v0, int v1, int v2, int v3) |
Construct int4 from four ints. | |
constexpr int4 | operator+ (const int4 &a) const noexcept |
Add two int4 vectors. | |
int4 & | operator+= (const int4 &a) noexcept |
Increment int4 vector. | |
int4 & | operator-= (const int4 &a) noexcept |
Decrement int4 vector. | |
constexpr int4 | operator- (const int4 &a) const noexcept |
Subtract two int4 vectors. | |
constexpr bool | operator== (const int4 &a) const noexcept |
Equality for all elements. | |
constexpr bool | operator!= (const int4 &a) const noexcept |
Inequality for all elements. | |
constexpr int4 | 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. | |
int | w |
Fourth element in vector. | |
Friends | |
std::ostream & | operator<< (std::ostream &os, const helios::int4 &vec) |
Write int4 to output stream. | |
Vector of four elements of type 'int'.
Definition at line 245 of file helios_vector_types.h.
|
inlineconstexpr |
Default constructor.
Definition at line 259 of file helios_vector_types.h.
|
inlineexplicit |
Construct int3 from a vector of ints.
Definition at line 263 of file helios_vector_types.h.
|
inlineexplicitconstexpr |
Construct int4 from an array of ints.
Definition at line 274 of file helios_vector_types.h.
|
inlineconstexpr |
Construct int4 from four ints.
Definition at line 278 of file helios_vector_types.h.
|
constexprnoexcept |
Inequality for all elements.
Definition at line 340 of file helios_vector_types.h.
Add two int4 vectors.
Definition at line 312 of file helios_vector_types.h.
Increment int4 vector.
Definition at line 316 of file helios_vector_types.h.
|
constexprnoexcept |
Multiply each element by -1.
Definition at line 344 of file helios_vector_types.h.
Subtract two int4 vectors.
Definition at line 332 of file helios_vector_types.h.
Decrement int4 vector.
Definition at line 324 of file helios_vector_types.h.
|
constexprnoexcept |
Equality for all elements.
Definition at line 336 of file helios_vector_types.h.
|
friend |
Write int4 to output stream.
Definition at line 297 of file helios_vector_types.h.
int helios::int4::w |
Fourth element in vector.
Definition at line 255 of file helios_vector_types.h.
int helios::int4::x |
First element in vector.
Definition at line 249 of file helios_vector_types.h.
int helios::int4::y |
Second element in vector.
Definition at line 251 of file helios_vector_types.h.
int helios::int4::z |
Third element in vector.
Definition at line 253 of file helios_vector_types.h.