SMTK
@SMTK_VERSION@
Simulation Modeling Tool Kit
|
11 #ifndef smtk_geometry_SelectionFootprint_h
12 #define smtk_geometry_SelectionFootprint_h
14 #include "smtk/CoreExports.h"
16 #include "smtk/geometry/Geometry.h"
17 #include "smtk/geometry/Resource.h"
19 #include "smtk/resource/Component.h"
20 #include "smtk/resource/query/DerivedFrom.h"
21 #include "smtk/resource/query/Query.h"
23 #include <unordered_set>
56 virtual bool operator()(
58 std::unordered_set<smtk::resource::PersistentObject*>& footprint,
78 auto& geom = resource->
geometry(backend);
89 std::unordered_set<smtk::resource::PersistentObject*>& footprint,
97 auto& geom = resource->
geometry(backend);
104 bool hasFootprint =
false;
105 auto visitor = [&hasFootprint, &footprint, &geom](
106 const resource::PersistentObject::Ptr& obj,
111 footprint.insert(obj.get());
115 geom->visit(visitor);
The main namespace for the Simulation Modeling Tool Kit (SMTK).
Definition: doc.h:33
static constexpr GenerationNumber Invalid
A special generation number that marks an object as having no geometric representation.
Definition: Geometry.h:75
std::unique_ptr< Geometry > & geometry(const Backend &backend)
Given a backend, return a provider of geometry for that backend.
Definition: Resource.cxx:48
This is an empty class used by geometry providers to specify their interface.
Definition: Backend.h:28
Query functors can be registered to Resources as the implementation of a base (and often abstract) Qu...
Definition: DerivedFrom.h:34
Component is the base class for records stored in an smtk::resource::Resource.
Definition: Component.h:43
size_t GenerationNumber
An integral type to hold monotonically increasing generation numbers (a.k.a.
Definition: Geometry.h:72
An abstract base class for SMTK resources and their components.
Definition: PersistentObject.h:39
An abstract base class for SMTK resources that provide geometry for themselves and/or their component...
Definition: Resource.h:33