[cgma-dev] r3253 - cgm/trunk/itaps
jvporter at wisc.edu
jvporter at wisc.edu
Thu Oct 29 17:48:07 CDT 2009
Author: jvporter
Date: 2009-10-29 17:48:07 -0500 (Thu, 29 Oct 2009)
New Revision: 3253
Modified:
cgm/trunk/itaps/iGeom_CGMA.cc
Log:
Make iGeom_getArrAdj and iGeom_getArr2ndAdj work like their iMesh
counterparts
Modified: cgm/trunk/itaps/iGeom_CGMA.cc
===================================================================
--- cgm/trunk/itaps/iGeom_CGMA.cc 2009-10-29 20:52:17 UTC (rev 3252)
+++ cgm/trunk/itaps/iGeom_CGMA.cc 2009-10-29 22:48:07 UTC (rev 3253)
@@ -970,7 +970,7 @@
int *offset_size,
int* err)
{
- CHECK_SIZE(*offset, int, entity_handles_size);
+ CHECK_SIZE(*offset, int, entity_handles_size+1);
DLIList<RefEntity*> temp_list, total_list;
for (int i = 0; i < entity_handles_size; ++i) {
(*offset)[i] = total_list.size();
@@ -979,6 +979,7 @@
if (iBase_SUCCESS != *err) return;
total_list += temp_list;
}
+ (*offset)[entity_handles_size] = total_list.size();
CHECK_SIZE(*adj_entity_handles, iBase_EntityHandle, total_list.size());
total_list.copy_to((RefEntity**)*adj_entity_handles);
@@ -1045,7 +1046,7 @@
int *offset_size,
int *err)
{
- CHECK_SIZE(*offset, int, entity_handles_size);
+ CHECK_SIZE(*offset, int, entity_handles_size+1);
DLIList<RefEntity*> bridge_list, temp_list, entity_list, total_list;
for (int i = 0; i < entity_handles_size; ++i) {
@@ -1061,9 +1062,10 @@
entity_list += temp_list;
}
entity_list.uniquify_unordered();
- (*offset)[i] = entity_list.size();
+ (*offset)[i] = total_list.size();
total_list += entity_list;
}
+ (*offset)[entity_handles_size] = total_list.size();
CHECK_SIZE(*adj_entity_handles, iBase_EntityHandle, total_list.size());
total_list.copy_to((RefEntity**)*adj_entity_handles);
More information about the cgma-dev
mailing list