[MOAB-dev] Closing/opening moab instances

Patrick Shriwise shriwise at wisc.edu
Tue Jan 14 09:46:59 CST 2014


On 01/09/2014 12:43 PM, Tim Tautges (ANL) wrote:
> Either declare the Core instance in a local variable, e.g. as in the 
> test/MBTest.cpp test (mb_vertex_coordinate_test function and the ones 
> following), or use Interface::delete_mesh.  I'd recommend the former, 
> as that gives you a clean instance.
>
> - tim
>
> On 01/09/2014 12:22 PM, Patrick Shriwise wrote:
>> Hi all,
>>
>> Working on a set of tests in which I would like to read an ACIS file 
>> independently in several different functions using
>> moab::Core::load_file. I believe that I am creating a new moab 
>> instance in every function. However when I load the file
>> in a new function, the data from the original load seems to remain. 
>> Any advice on how to load the file without having it
>> overlap between functions?
>>
>> Cheers,
>>
> I've setup my local moab instance calls just as in MBTest.cpp and 
> mb_vertex_coordinate_test but am still having the same problem. When I 
> load a simple cube geometry and check that it has the appropriate 
> number of vertices it works the first time, but if I repeat the test 
> in main it will find twice the number of vertices as expected upon a 
> repeated test run. Any thoughts?

-- 
Patrick C. Shriwise
Research Assistant
University of Wisconsin - Madison
Engineering Research Building - Rm. 428
1500 Engineering Drive
Madison, WI 53706
(608) 446-8173



More information about the moab-dev mailing list