From ba6cd1c872d82bce7ca502757c031ba3bfb918ca Mon Sep 17 00:00:00 2001 From: David Williams Date: Tue, 29 Mar 2011 20:48:38 +0000 Subject: [PATCH] Removed redundant comparison operators from VoxelTypes. --- library/PolyVoxCore/include/Density.h | 10 ---------- library/PolyVoxCore/include/Material.h | 10 ---------- library/PolyVoxCore/include/MaterialDensityPair.h | 14 -------------- 3 files changed, 34 deletions(-) diff --git a/library/PolyVoxCore/include/Density.h b/library/PolyVoxCore/include/Density.h index 30da0053..69322c12 100644 --- a/library/PolyVoxCore/include/Density.h +++ b/library/PolyVoxCore/include/Density.h @@ -58,16 +58,6 @@ namespace PolyVox return !(*this == rhs); } - bool operator<(const Density& rhs) const throw() - { - if (m_uDensity < rhs.m_uDensity) - return true; - if (rhs.m_uDensity < m_uDensity) - return false; - - return false; - } - Type getDensity() const throw() { return m_uDensity; } Type getMaterial() const throw() { return 1; } diff --git a/library/PolyVoxCore/include/Material.h b/library/PolyVoxCore/include/Material.h index 5e166568..ba6bc3e6 100644 --- a/library/PolyVoxCore/include/Material.h +++ b/library/PolyVoxCore/include/Material.h @@ -61,16 +61,6 @@ namespace PolyVox return !(*this == rhs); } - bool operator<(const Material& rhs) const throw() - { - if (m_uMaterial < rhs.m_uMaterial) - return true; - if (rhs.m_uMaterial < m_uMaterial) - return false; - - return false; - } - Type getDensity() const throw() { //We don't actually have a density, so make one up based on the material. diff --git a/library/PolyVoxCore/include/MaterialDensityPair.h b/library/PolyVoxCore/include/MaterialDensityPair.h index 65c532e7..e0f38e4a 100644 --- a/library/PolyVoxCore/include/MaterialDensityPair.h +++ b/library/PolyVoxCore/include/MaterialDensityPair.h @@ -60,20 +60,6 @@ namespace PolyVox return !(*this == rhs); } - bool operator<(const MaterialDensityPair& rhs) const throw() - { - if (m_uMaterial < rhs.m_uMaterial) - return true; - if (rhs.m_uMaterial < m_uMaterial) - return false; - if (m_uDensity < rhs.m_uDensity) - return true; - if (rhs.m_uDensity < m_uDensity) - return false; - - return false; - } - Type getDensity() const throw() { return m_uDensity; } Type getMaterial() const throw() { return m_uMaterial; }