Update TinyRenderer.cpp

create a cube using x,y,z not x,y,y
This commit is contained in:
erwincoumans
2019-07-30 17:48:59 -07:00
committed by GitHub
parent 1feb186204
commit a8e1be3b33

View File

@@ -396,7 +396,7 @@ void TinyRenderObjectData::createCube(float halfExtentsX, float halfExtentsY, fl
{
m_model->addVertex(halfExtentsX * cube_vertices_textured[i * 9],
halfExtentsY * cube_vertices_textured[i * 9 + 1],
halfExtentsY * cube_vertices_textured[i * 9 + 2],
halfExtentsZ * cube_vertices_textured[i * 9 + 2],
cube_vertices_textured[i * 9 + 4],
cube_vertices_textured[i * 9 + 5],
cube_vertices_textured[i * 9 + 6],