HPoint

class HPoint

The HPoint class is the data type of a three-dimensional point.

The HPoint class encapsulates the x, y, and z coordinates of a 3-dimensional point. HPoint simplifies the passing of 3-dimensional point data to all of the MVO and derived classes. It is widely used by public and internal functions as well as by native HOOPS routines.

Methods

HPoint::HPoint()

The default constructor.

HPoint::HPoint(float X, float Y, float Z = 0.0f)

This constructor accepts floats for the x, y and z coordinates.

HPoint::HPoint(HPoint const *p)

This constructor accepts a pointer to an HPoint object.

HPoint::HPoint(HPoint const &p)

This constructor accepts an HPoint reference.

void HPoint::Set(float X, float Y, float Z = 0.0f)

This method packs an HPoint object with coordinate values.

void HPoint::Set(HPoint *p)

This method packs an HPoint object with coordinate values from a given HPoint.

void HPoint::Set(HPoint const *p)

This method packs an HPoint object with coordinate values from a given HPoint.

void HPoint::Set(HPoint &p)

This method packs an HPoint object with coordinate values from a given HPoint that is passed by reference.

void HPoint::Set(HPoint const &p)

This method packs an HPoint object with coordinate values from a given HPoint that is passed by reference.

void HPoint::Add(float X, float Y, float Z = 0.0)

This method increases/decreases the coordinate values of an existing HPoint object.

Parameters

X: The amount in which you want to increment or decrement the x coordinate.

Y: The amount in which you want to increment or decrement the y coordinate.

Z: The amount in which you want to increment or decrement the z coordinate.

HPoint const HPoint::operator-(HPoint const &p2) const

const

HPoint const HPoint::operator+(HPoint const &p2) const

const

HPoint const HPoint::operator*(float const rhs) const

const

HPoint const HPoint::operator/(float const rhs) const

const

HPoint const &HPoint::operator+=(HPoint const &rhs)
HPoint const &HPoint::operator-=(HPoint const &rhs)
HPoint const &HPoint::operator*=(float const rhs)
HPoint const &HPoint::operator/=(float const rhs)
bool HPoint::operator==(HPoint const &rhs) const

const

bool HPoint::operator!=(HPoint const &rhs) const

const

HPoint &HPoint::operator=(HPoint const&) = default
bool HPoint::Equal(HPoint const *p, float epsi = HPOINT_EPSILON) const

const

This method checks if the xyz components of the point are equal.

bool HPoint::Equal(HPoint const &p, float epsi = HPOINT_EPSILON) const

const

This method checks if the xyz components of the point are equal.

Variables

float HPoint::x
float

The x-coordinate of a 3-dimensional point.

float HPoint::y
float

The y-coordinate of a 3-dimensional point.

float HPoint::z
float

The z-coordinate of a 3-dimensional point.