[MOAB-dev] r5265 - MOAB/trunk/itaps/igeom

iulian at mcs.anl.gov iulian at mcs.anl.gov
Thu Dec 15 16:10:30 CST 2011


Author: iulian
Date: 2011-12-15 16:10:30 -0600 (Thu, 15 Dec 2011)
New Revision: 5265

Modified:
   MOAB/trunk/itaps/igeom/FBiGeom_MOAB.cpp
Log:
more functions implemented:
FBiGeom_getEntNrmlSense
FBiGeom_getFaceType
FBiGeom_getParametric
FBiGeom_getEgEvalXYZ



Modified: MOAB/trunk/itaps/igeom/FBiGeom_MOAB.cpp
===================================================================
--- MOAB/trunk/itaps/igeom/FBiGeom_MOAB.cpp	2011-12-15 21:35:46 UTC (rev 5264)
+++ MOAB/trunk/itaps/igeom/FBiGeom_MOAB.cpp	2011-12-15 22:10:30 UTC (rev 5265)
@@ -825,8 +825,13 @@
   // not implemented
 }
 
-void FBiGeom_getEntNrmlSense(FBiGeom_Instance, iBase_EntityHandle face,
+void FBiGeom_getEntNrmlSense(FBiGeom_Instance instance, iBase_EntityHandle face,
       iBase_EntityHandle region, int* sense_out, int* err) {
+  moab::EntityHandle mbregion = (moab::EntityHandle) region;
+  moab::EntityHandle mbface = (moab::EntityHandle) face;
+  moab::ErrorCode rval = FBE_cast(instance)->getEgFcSense(  mbface, mbregion, *sense_out );
+  CHKERR(rval,"can't get normal sense ");
+  RETURN(iBase_SUCCESS);
 }
 void FBiGeom_getArrNrmlSense(FBiGeom_Instance,
       iBase_EntityHandle const* face_handles, int face_handles_size,
@@ -888,8 +893,14 @@
   RETURN(iBase_SUCCESS);
 }
 
-void FBiGeom_getFaceType(FBiGeom_Instance, iBase_EntityHandle face_handle,
+void FBiGeom_getFaceType(FBiGeom_Instance instance, iBase_EntityHandle face_handle,
       char* face_type, int* err, int* face_type_length) {
+  std::string type = "nonplanar"; // for swept faces created with rays between surfaces,
+  // we could actually create planar surfaces; maybe we should recognize them as such
+  face_type = new char[type.length()+1];
+  strcpy(face_type, type.c_str());
+  *face_type_length = type.length()+1;
+  RETURN(iBase_SUCCESS);
 }
 void FBiGeom_getParametric(FBiGeom_Instance instance, int* is_parametric, int* err) {
   *is_parametric = 0; //(false)
@@ -1226,6 +1237,8 @@
 void FBiGeom_getNumEntSets(FBiGeom_Instance instance,
       iBase_EntitySetHandle entity_set_handle, int num_hops, int *num_sets,
       int *err) {
+  // TODO  here, we should really get only the entity sets that have gents as members
+  // we have the convention that entity sets of geom dimension 4
    iMesh_getNumEntSets(IMESH_INSTANCE(instance), entity_set_handle, num_hops,
          num_sets, err);
 }
@@ -1235,6 +1248,8 @@
       iBase_EntitySetHandle** contained_set_handles,
       int* contained_set_handles_allocated, int* contained_set_handles_size,
       int *err) {
+  // TODO  here, we should really get only the entity sets that have gents as members
+    // we have the convention that entity sets of geom dimension 4
    iMesh_getEntSets(IMESH_INSTANCE(instance), entity_set_handle, num_hops,


More information about the moab-dev mailing list