Skip to content

Commit

Permalink
Small hack: Disable backface culling for Z-Clipping
Browse files Browse the repository at this point in the history
  • Loading branch information
Vogtinator committed Jun 2, 2014
1 parent 4bca054 commit 4b7658b
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions chunk.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -262,8 +262,9 @@ bool Chunk::drawTriangle(const IndexedVertex &low, const IndexedVertex &middle,
t1 = perspective(visible[1], *pos_visible[1]);
nglPerspective(&v1);

if(backface_culling && nglIsBackface(&t0, &t1, &v1))
return false;
//TODO: Hack: This doesn't work as expected
/*if(backface_culling && nglIsBackface(&t0, &t1, &v1))
return false;*/

nglPerspective(&v2);
nglDrawTriangleZClipped(&t0, &t1, &v1);
Expand Down

0 comments on commit 4b7658b

Please sign in to comment.