[cgma-dev] r5382 - cgm/trunk/itaps

sjackson at cae.wisc.edu sjackson at cae.wisc.edu
Wed Feb 8 13:34:11 CST 2012


Author: sjackson
Date: 2012-02-08 13:34:10 -0600 (Wed, 08 Feb 2012)
New Revision: 5382

Modified:
   cgm/trunk/itaps/iGeom.h
   cgm/trunk/itaps/iGeom_CGMA.cc
Log:
Make iGeom.h C-compatible again

Remove c++ idioms (bools and references) introduced in r5379.



Modified: cgm/trunk/itaps/iGeom.h
===================================================================
--- cgm/trunk/itaps/iGeom.h	2012-02-07 20:53:47 UTC (rev 5381)
+++ cgm/trunk/itaps/iGeom.h	2012-02-08 19:34:10 UTC (rev 5382)
@@ -3977,7 +3977,7 @@
                           double x,
                           double y,
                           double z,
-                          bool &isOn); 
+                          int *isOn); 
 #ifdef __cplusplus
 } /* extern "C" */
 #endif

Modified: cgm/trunk/itaps/iGeom_CGMA.cc
===================================================================
--- cgm/trunk/itaps/iGeom_CGMA.cc	2012-02-07 20:53:47 UTC (rev 5381)
+++ cgm/trunk/itaps/iGeom_CGMA.cc	2012-02-08 19:34:10 UTC (rev 5382)
@@ -6278,10 +6278,10 @@
                         double x,
                         double y,
                         double z,
-                        bool &IsOn)
+                        int* IsOn)
 {
   CubitVector position(x,y,z);
-  CubitPointContainment pc;
+  CubitPointContainment pc = CUBIT_PNT_UNKNOWN;
   RefFace *ref_face = dynamic_cast<RefFace*>(ENTITY_HANDLE(entity));
   if(ref_face)
     pc = ref_face->point_containment(position);
@@ -6295,10 +6295,10 @@
     pc = body->point_containment(position);
 
   if (pc == CUBIT_PNT_INSIDE || pc == CUBIT_PNT_BOUNDARY)
-    IsOn = true;
+    *IsOn = 1;
 
   else
-    IsOn = false;
+    *IsOn = 0;
   return;
 }
 









More information about the cgma-dev mailing list