From a382ea5b21796b62a25fc1eb99871735a25db64f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ignacio=20Casta=C3=B1o?= Date: Wed, 2 Sep 2015 12:25:47 -0700 Subject: [PATCH] Fix compiler warning. --- src/nvtt/ClusterFit.h | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/src/nvtt/ClusterFit.h b/src/nvtt/ClusterFit.h index 4f29680..078c9d6 100644 --- a/src/nvtt/ClusterFit.h +++ b/src/nvtt/ClusterFit.h @@ -56,16 +56,18 @@ namespace nv { uint m_count; + // IC: Color and weight arrays are larger than necessary to avoid compiler warning. + #if NVTT_USE_SIMD - NV_ALIGN_16 SimdVector m_weighted[16]; // color | weight - SimdVector m_metric; // vec3 - SimdVector m_metricSqr; // vec3 - SimdVector m_xxsum; // color | weight - SimdVector m_xsum; // color | weight (wsum) - SimdVector m_besterror; // scalar + NV_ALIGN_16 SimdVector m_weighted[17]; // color | weight + SimdVector m_metric; // vec3 + SimdVector m_metricSqr; // vec3 + SimdVector m_xxsum; // color | weight + SimdVector m_xsum; // color | weight (wsum) + SimdVector m_besterror; // scalar #else - Vector3 m_weighted[16]; - float m_weights[16]; + Vector3 m_weighted[17]; + float m_weights[17]; Vector3 m_metric; Vector3 m_metricSqr; Vector3 m_xxsum;