Go to the documentation of this file.
3 #include <RobotAPI/interface/ArViz/Elements.h>
5 #include <Inventor/nodes/SoSeparator.h>
6 #include <Inventor/nodes/SoSwitch.h>
44 std::unique_ptr<ElementVisualization>
create(data::Element
const& element);
52 template <
typename NodeT>
71 template <
typename DataT>
82 result->switch_->addChild(result->node);
88 auto const& element =
static_cast<ElementType const&
>(element_);
93 bool hidden = (element.flags & armarx::viz::data::ElementFlags::HIDDEN);
98 data->separator->removeChild(
data->node);
99 data->visible =
false;
102 else if (!
data->visible)
104 data->visible =
true;
105 data->separator->addChild(
data->node);
109 return data->update(element);
virtual ~ElementVisualization()=default
TypedElementVisualization()
virtual ElementVisualization * createDerived()=0
typename DataType::ElementType ElementType
bool update(data::Element const &element, ElementVisualization *visu)
void updateBase(data::Element const &element)
bool updateDerived(data::Element const &element_, ElementVisualization *data_) final
virtual bool updateDerived(data::Element const &element, ElementVisualization *data)=0
virtual ~ElementVisualizer()=default
DataType * createDerived() final
std::unique_ptr< ElementVisualization > create(data::Element const &element)
~TypedElementVisualization()