Removed usage of Boost static assert.

This commit is contained in:
Sherief Farouk
2016-03-18 17:02:39 -07:00
parent 76e4e82ecb
commit 397fa374a3
8 changed files with 20 additions and 27 deletions

View File

@@ -51,7 +51,6 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "Vertex.h"
#include "TinyFormatter.h"
#include <stdio.h>
#include <boost/static_assert.hpp>
using namespace Assimp;
// ------------------------------------------------------------------------------------------------
@@ -117,8 +116,8 @@ void JoinVerticesProcess::Execute( aiScene* pScene)
// Unites identical vertices in the given mesh
int JoinVerticesProcess::ProcessMesh( aiMesh* pMesh, unsigned int meshIndex)
{
BOOST_STATIC_ASSERT( AI_MAX_NUMBER_OF_COLOR_SETS == 8);
BOOST_STATIC_ASSERT( AI_MAX_NUMBER_OF_TEXTURECOORDS == 8);
static_assert( AI_MAX_NUMBER_OF_COLOR_SETS == 8, "AI_MAX_NUMBER_OF_COLOR_SETS == 8");
static_assert( AI_MAX_NUMBER_OF_TEXTURECOORDS == 8, "AI_MAX_NUMBER_OF_TEXTURECOORDS == 8");
// Return early if we don't have any positions
if (!pMesh->HasPositions() || !pMesh->HasFaces()) {
@@ -134,7 +133,7 @@ int JoinVerticesProcess::ProcessMesh( aiMesh* pMesh, unsigned int meshIndex)
// whether a new vertex was created for the index (true) or if it was replaced by an existing
// unique vertex (false). This saves an additional std::vector<bool> and greatly enhances
// branching performance.
BOOST_STATIC_ASSERT(AI_MAX_VERTICES == 0x7fffffff);
static_assert(AI_MAX_VERTICES == 0x7fffffff, "AI_MAX_VERTICES == 0x7fffffff");
std::vector<unsigned int> replaceIndex( pMesh->mNumVertices, 0xffffffff);
// A little helper to find locally close vertices faster.