Week6 [02/11] - [04/11]

Added Camera Class
Added *= operator to the matrix class
Added Transformation Queue vector to the Model Class
Added Get Vertex, Polygon and Polygon Vertex methods to the Model Class
Added DehomogenizeAllVerticies method to the Model Class
Added GetPolygonVertexCount method to Polygon Class
Added Ability to have multiple models in a "scene" in the Rasterizer
Added DrawWireFrame method to the Rasterizer Class
Added Aspect Ratio and View Matrix to the Rasterizer Class
Added TransformTools namespace to hold shared transformation functions
Added Dehomogenize method to the Vector Class
Moved Transformation methods to a new shared name space
This commit is contained in:
IDunnoDev
2021-12-11 14:15:02 +00:00
committed by iDunnoDev
parent 3b374c1e17
commit 19639d70d1
19 changed files with 493 additions and 72 deletions

View File

@ -69,6 +69,14 @@ void Vertex::SetW(const float w)
_w = w;
}
void Vertex::Dehomogenize()
{
_x = _x / _w;
_y = _y / _w;
_z = _z / _w;
_w = _w / _w;
}
Vertex& Vertex::operator=(const Vertex& rhs)
{
// Only do the assignment if we are not assigning