[MOAB-dev] r5427 - MOAB/trunk/src/io
iulian at mcs.anl.gov
iulian at mcs.anl.gov
Tue Mar 13 14:33:07 CDT 2012
Author: iulian
Date: 2012-03-13 14:33:07 -0500 (Tue, 13 Mar 2012)
New Revision: 5427
Modified:
MOAB/trunk/src/io/Tqdcfr.cpp
Log:
read the id and uid from a cubit file with composite geometry
a simple file with composite curves is processed fine
Modified: MOAB/trunk/src/io/Tqdcfr.cpp
===================================================================
--- MOAB/trunk/src/io/Tqdcfr.cpp 2012-03-13 15:51:30 UTC (rev 5426)
+++ MOAB/trunk/src/io/Tqdcfr.cpp 2012-03-13 19:33:07 UTC (rev 5427)
@@ -2346,6 +2346,21 @@
num_read = sscanf(records[current_attrib].att_string.c_str(), "UNIQUE_ID 1 0 1 %d", &uid);
if (1 != num_read) return MB_FAILURE;
}
+ else if (strncmp(records[current_attrib].att_string.c_str(), "COMPOSITE_ATTRIB @9 UNIQUE_ID", 29) == 0) {
+ // parse uid
+ int dum1, dum2, dum3, dum4;
+ num_read = sscanf(records[current_attrib].att_string.c_str(), "COMPOSITE_ATTRIB @9 UNIQUE_ID %d %d %d %d %d",
+ &dum1, &dum2, &dum3, &dum4, &uid);
+ if (5 != num_read) return MB_FAILURE;
+ }
+ else if (strncmp(records[current_attrib].att_string.c_str(), "COMPOSITE_ATTRIB @9 ENTITY_ID", 29) == 0) {
+ // parse id
+ int dum1, dum2, dum3;
+ num_read = sscanf(records[current_attrib].att_string.c_str(), "COMPOSITE_ATTRIB @9 ENTITY_ID %d %d %d %d",
+ &dum1, &dum2, &dum3, &id);
+ if (4 != num_read) return MB_FAILURE;
+ }
+
else {
attrib_vec.push_back(records[current_attrib].att_string);
}
More information about the moab-dev
mailing list