CARLA
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | Friends | List of all members
carla::geom::Vector3DInt Class Reference

#include <Vector3DInt.h>

Public Member Functions

double Length () const
 
template<typename MSGPACK_OBJECT >
void msgpack_object (MSGPACK_OBJECT *o, clmdep_msgpack::zone &sneaky_variable_that_shadows_z) const
 
template<typename Packer >
void msgpack_pack (Packer &pk) const
 
void msgpack_unpack (clmdep_msgpack::object const &o)
 
bool operator!= (const Vector3DInt &rhs) const
 
Vector3DInt & operator*= (int32_t rhs)
 
Vector3DInt & operator+= (const Vector3DInt &rhs)
 
Vector3DInt & operator-= (const Vector3DInt &rhs)
 
Vector3DInt & operator/= (int32_t rhs)
 
Vector3DInt & operator= (const FIntVector &rhs)=delete
 
bool operator== (const Vector3DInt &rhs) const
 
int64_t SquaredLength () const
 
Vector3DInt ToCentimeters () const
 Return a Vector3DInt converted from meters to centimeters.
 
FIntVector ToFIntVector () const
 
Vector3DInt ToMeters () const
 Return a Vector3DInt converted from centimeters to meters.
 
 Vector3DInt ()=default
 
 Vector3DInt (const FIntVector &v)=delete
 
 Vector3DInt (int32_t ix, int32_t iy, int32_t iz)
 

Public Attributes

int32_t x = 0
 
int32_t y = 0
 
int32_t z = 0
 

Friends

Vector3DInt operator* (int32_t lhs, Vector3DInt rhs)
 
Vector3DInt operator* (Vector3DInt lhs, int32_t rhs)
 
Vector3DInt operator+ (Vector3DInt lhs, const Vector3DInt &rhs)
 
Vector3DInt operator- (Vector3DInt lhs, const Vector3DInt &rhs)
 
Vector3DInt operator/ (int32_t lhs, Vector3DInt rhs)
 
Vector3DInt operator/ (Vector3DInt lhs, int32_t rhs)
 

Detailed Description

Definition at line 17 of file Vector3DInt.h.

Constructor & Destructor Documentation

◆ Vector3DInt() [1/3]

carla::geom::Vector3DInt::Vector3DInt ( )
default

◆ Vector3DInt() [2/3]

carla::geom::Vector3DInt::Vector3DInt ( int32_t  ix,
int32_t  iy,
int32_t  iz 
)
inline

Definition at line 36 of file Vector3DInt.h.

◆ Vector3DInt() [3/3]

carla::geom::Vector3DInt::Vector3DInt ( const FIntVector &  v)
delete

Member Function Documentation

◆ Length()

double carla::geom::Vector3DInt::Length ( ) const
inline

Definition at line 49 of file Vector3DInt.h.

References SquaredLength().

◆ msgpack_object()

template<typename MSGPACK_OBJECT >
void carla::geom::Vector3DInt::msgpack_object ( MSGPACK_OBJECT *  o,
clmdep_msgpack::zone &  sneaky_variable_that_shadows_z 
) const
inline

Definition at line 168 of file Vector3DInt.h.

References x, y, and z.

◆ msgpack_pack()

template<typename Packer >
void carla::geom::Vector3DInt::msgpack_pack ( Packer &  pk) const
inline
Todo:
The following is copy-pasted from MSGPACK_DEFINE_ARRAY. This is a workaround for an issue in msgpack library. The MSGPACK_DEFINE_ARRAY macro is shadowing our z variable. https://github.com/msgpack/msgpack-c/issues/709

Definition at line 159 of file Vector3DInt.h.

References x, y, and z.

◆ msgpack_unpack()

void carla::geom::Vector3DInt::msgpack_unpack ( clmdep_msgpack::object const &  o)
inline

Definition at line 163 of file Vector3DInt.h.

References x, y, and z.

◆ operator!=()

bool carla::geom::Vector3DInt::operator!= ( const Vector3DInt &  rhs) const
inline

Definition at line 123 of file Vector3DInt.h.

◆ operator*=()

Vector3DInt & carla::geom::Vector3DInt::operator*= ( int32_t  rhs)
inline

Definition at line 81 of file Vector3DInt.h.

References x, y, and z.

◆ operator+=()

Vector3DInt & carla::geom::Vector3DInt::operator+= ( const Vector3DInt &  rhs)
inline

Definition at line 57 of file Vector3DInt.h.

References x, y, and z.

◆ operator-=()

Vector3DInt & carla::geom::Vector3DInt::operator-= ( const Vector3DInt &  rhs)
inline

Definition at line 69 of file Vector3DInt.h.

References x, y, and z.

◆ operator/=()

Vector3DInt & carla::geom::Vector3DInt::operator/= ( int32_t  rhs)
inline

Definition at line 98 of file Vector3DInt.h.

References x, y, and z.

◆ operator=()

Vector3DInt & carla::geom::Vector3DInt::operator= ( const FIntVector &  rhs)
delete

◆ operator==()

bool carla::geom::Vector3DInt::operator== ( const Vector3DInt &  rhs) const
inline

Definition at line 119 of file Vector3DInt.h.

References x, y, and z.

◆ SquaredLength()

int64_t carla::geom::Vector3DInt::SquaredLength ( ) const
inline

Definition at line 45 of file Vector3DInt.h.

References x, y, and z.

Referenced by Length().

◆ ToCentimeters()

Vector3DInt carla::geom::Vector3DInt::ToCentimeters ( ) const
inline

Return a Vector3DInt converted from meters to centimeters.

Definition at line 142 of file Vector3DInt.h.

◆ ToFIntVector()

FIntVector carla::geom::Vector3DInt::ToFIntVector ( ) const
inline

Definition at line 146 of file Vector3DInt.h.

References x, y, and z.

◆ ToMeters()

Vector3DInt carla::geom::Vector3DInt::ToMeters ( ) const
inline

Return a Vector3DInt converted from centimeters to meters.

Definition at line 137 of file Vector3DInt.h.

Friends And Related Symbol Documentation

◆ operator* [1/2]

Vector3DInt operator* ( int32_t  lhs,
Vector3DInt  rhs 
)
friend

Definition at line 93 of file Vector3DInt.h.

◆ operator* [2/2]

Vector3DInt operator* ( Vector3DInt  lhs,
int32_t  rhs 
)
friend

Definition at line 88 of file Vector3DInt.h.

◆ operator+

Vector3DInt operator+ ( Vector3DInt  lhs,
const Vector3DInt &  rhs 
)
friend

Definition at line 64 of file Vector3DInt.h.

◆ operator-

Vector3DInt operator- ( Vector3DInt  lhs,
const Vector3DInt &  rhs 
)
friend

Definition at line 76 of file Vector3DInt.h.

◆ operator/ [1/2]

Vector3DInt operator/ ( int32_t  lhs,
Vector3DInt  rhs 
)
friend

Definition at line 110 of file Vector3DInt.h.

◆ operator/ [2/2]

Vector3DInt operator/ ( Vector3DInt  lhs,
int32_t  rhs 
)
friend

Definition at line 105 of file Vector3DInt.h.

Member Data Documentation

◆ x

int32_t carla::geom::Vector3DInt::x = 0

◆ y

int32_t carla::geom::Vector3DInt::y = 0

◆ z

int32_t carla::geom::Vector3DInt::z = 0

The documentation for this class was generated from the following file: