30 lines
481 B
C++
30 lines
481 B
C++
#pragma once
|
|
class Vertex
|
|
{
|
|
public:
|
|
Vertex();
|
|
Vertex(float x, float y, float w);
|
|
Vertex(const Vertex& other);
|
|
|
|
// Accessors
|
|
float GetX() const;
|
|
void SetX(const float x);
|
|
float GetY() const;
|
|
void SetY(const float y);
|
|
float GetW() const;
|
|
void SetW(const float w);
|
|
|
|
// Assignment operator
|
|
Vertex& operator= (const Vertex& rhs);
|
|
|
|
bool operator== (const Vertex& rhs) const;
|
|
|
|
const Vertex operator+ (const Vertex& rhs) const;
|
|
|
|
private:
|
|
float _x;
|
|
float _y;
|
|
float _w;
|
|
};
|
|
|