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:
@ -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
|
||||
|
Reference in New Issue
Block a user