code cleanup

This commit is contained in:
ZappoMan 2013-06-18 10:28:14 -07:00
parent a6b4bdba53
commit 00438f9d99
2 changed files with 0 additions and 33 deletions

View file

@ -11,37 +11,6 @@
#include <glm/glm.hpp>
#include "VoxelProjectedShadow.h"
//
// depth of polygon is distance from camera to closest point on 3d voxel
// this works because voxels are axis aligned and therefore other voxels
// can only be as close as that if they are on the same axis
//
// scanning octree in "closest" order...
// for each node
// polygon = getShadow(node)
// isOccluded = coverageMap->isOccluded(polygon)
// if (!isOccluded)
// coverageMap->add(polygon)
// sendList->add(node)
// else
// don't need to send or remember
// end each
// adding to coverage map....
//
// at each level of quadtree
// store a list of polygons whose bounding box fit in the bb of the quad but not a smaller quad
// also store 4 smaller quad trees
//
// is it true, that only polygons from higher in the quad tree can occlude a polygon?
// YES - I believe so, because polygon that occluded all the points of the potential occludee
// would have a bounding box that couldn't fit in a lower level of the quad tree
//
//
class CoverageMap {
public:

View file

@ -130,8 +130,6 @@ bool doLineSegmentsIntersect(glm::vec2 r1p1, glm::vec2 r1p2, glm::vec2 r2p1, glm
(d4 == 0 && isOnSegment(r1p1.x, r1p1.y, r1p2.x, r1p2.y, r2p2.x, r2p2.y));
}
// I want these to be inlined for performance
bool isOnSegment(float xi, float yi, float xj, float yj, float xk, float yk) {
return (xi <= xk || xj <= xk) && (xk <= xi || xk <= xj) &&
(yi <= yk || yj <= yk) && (yk <= yi || yk <= yj);