m_CenterPoint.x = ((m_Vertex[VERT_A].x + m_Vertex[VERT_B].x + m_Vertex[VERT_C].x) / 3);
m_CenterPoint.y = ((m_Vertex[VERT_A].y + m_Vertex[VERT_B].y + m_Vertex[VERT_C].y) / 3);
m_CenterPoint.z = ((m_Vertex[VERT_A].z + m_Vertex[VERT_B].z + m_Vertex[VERT_C].z) / 3);
// compute the midpoint of each cell wall
m_WallMidpoint[0] = new Vector3f(
(m_Vertex[VERT_A].x + m_Vertex[VERT_B].x) / 2.0f,
(m_Vertex[VERT_A].y + m_Vertex[VERT_B].y) / 2.0f,
(m_Vertex[VERT_A].z + m_Vertex[VERT_B].z) / 2.0f);
m_WallMidpoint[1] = new Vector3f(
(m_Vertex[VERT_C].x + m_Vertex[VERT_B].x) / 2.0f,
(m_Vertex[VERT_C].y + m_Vertex[VERT_B].y) / 2.0f,
(m_Vertex[VERT_C].z + m_Vertex[VERT_B].z) / 2.0f);
m_WallMidpoint[2] = new Vector3f(
(m_Vertex[VERT_C].x + m_Vertex[VERT_A].x) / 2.0f,
(m_Vertex[VERT_C].y + m_Vertex[VERT_A].y) / 2.0f,
(m_Vertex[VERT_C].z + m_Vertex[VERT_A].z) / 2.0f);
// compute the distances between the wall midpoints
Vector3f WallVector;
WallVector = m_WallMidpoint[0].subtract(m_WallMidpoint[1]);
m_WallDistance[0] = WallVector.length();
WallVector = m_WallMidpoint[1].subtract(m_WallMidpoint[2]);
m_WallDistance[1] = WallVector.length();
WallVector = m_WallMidpoint[2].subtract(m_WallMidpoint[0]);
m_WallDistance[2] = WallVector.length();
}