22 vertsColorMap_ = obj->getVertsColorMap();
32 vertsColorMap_ = std::move( newVertsColorMap );
33 obj_->updateVertsColorMap( vertsColorMap_ );
37 virtual std::string
name()
const override
46 obj_->updateVertsColorMap( vertsColorMap_ );
55 [[nodiscard]]
virtual size_t heapBytes()
const override
57 return name_.capacity() + vertsColorMap_.capacity();
61 std::shared_ptr<VisualObject> obj_;
62 VertColors vertsColorMap_;
Definition MRChangeVertsColorMapAction.h:12
virtual void action(HistoryAction::Type) override
This function is called on history action (undo, redo, etc.)
Definition MRChangeVertsColorMapAction.h:42
virtual size_t heapBytes() const override
returns the amount of memory this object occupies on heap
Definition MRChangeVertsColorMapAction.h:55
ChangeVertsColorMapAction(const std::string &name, const std::shared_ptr< VisualObject > &obj)
use this constructor to remember object's vertex colors before making any changes in them
Definition MRChangeVertsColorMapAction.h:17
static void setObjectDirty(const std::shared_ptr< VisualObject > &obj)
Definition MRChangeVertsColorMapAction.h:49
ChangeVertsColorMapAction(const std::string &name, const std::shared_ptr< VisualObject > &obj, VertColors &&newVertsColorMap)
use this constructor to remember object's vertex colors and immediate set new value
Definition MRChangeVertsColorMapAction.h:26
virtual std::string name() const override
Definition MRChangeVertsColorMapAction.h:37
Definition MRHistoryAction.h:12
Type
Definition MRHistoryAction.h:19
Visual Object.
Definition MRVisualObject.h:131
@ DIRTY_VERTS_COLORMAP
Definition MRVisualObject.h:100
Definition MRCameraOrientationPlugin.h:8