[MOAB-dev] r5700 - MOAB/trunk/src/moab
xbxu at mcs.anl.gov
xbxu at mcs.anl.gov
Wed Aug 15 13:26:56 CDT 2012
Author: xbxu
Date: 2012-08-15 13:26:56 -0500 (Wed, 15 Aug 2012)
New Revision: 5700
Modified:
MOAB/trunk/src/moab/ScdInterface.hpp
Log:
add check for k dimension of the box when getting vertex
Modified: MOAB/trunk/src/moab/ScdInterface.hpp
===================================================================
--- MOAB/trunk/src/moab/ScdInterface.hpp 2012-08-15 16:10:37 UTC (rev 5699)
+++ MOAB/trunk/src/moab/ScdInterface.hpp 2012-08-15 18:26:56 UTC (rev 5700)
@@ -1189,8 +1189,8 @@
inline EntityHandle ScdBox::get_vertex(int i, int j, int k) const
{
- return (vertDat ? startVertex + (k-boxDims[2])*boxSizeIJ + (j-boxDims[1])*boxSize[0] + i-boxDims[0] :
- get_vertex_from_seq(i, j, k));
+ return (vertDat ? startVertex + (boxDims[2] == -1 && boxDims[5] == -1 ? 0 : (k-boxDims[2]))*boxSizeIJ +
+ (j-boxDims[1])*boxSize[0] + i-boxDims[0] : get_vertex_from_seq(i, j, k));
}
inline EntityHandle ScdBox::get_vertex(HomCoord ijk) const
More information about the moab-dev
mailing list