Skip to content

Commit

Permalink
fix the call to find_volume
Browse files Browse the repository at this point in the history
the find_volume function is located in
the GeomQueryTool-object, so we need to
create one. This is an inefficient
implementation since it creates a new object for each call
  • Loading branch information
ebknudsen committed Aug 17, 2023
1 parent 31a8704 commit a2fcd0d
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/RTI.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
// MOAB
#include "MBTagConventions.hpp"
#include "moab/GeomTopoTool.hpp"
#include "moab/GeomQueryTool.hpp"

// Double-down
#include "double_down/RTI.hpp"
Expand Down Expand Up @@ -766,7 +767,8 @@ RayTracingInterface::find_volume(const double xyz[3],
const double *uvw)
{
moab::ErrorCode rval;
rval = moab::find_volume(xyz,volume,uvw);
auto gqt = std::shared_ptr<moab::GeomQueryTool> ( new moab::GeomQueryTool(this->gttool()) );
rval = gqt->find_volume(xyz,volume,uvw);
return rval;
}

Expand Down

0 comments on commit a2fcd0d

Please sign in to comment.