28 vertsColorMap_ = obj->getVertsColorMap();
38 vertsColorMap_ = std::move( newVertsColorMap );
39 obj_->updateVertsColorMap( vertsColorMap_ );
43 virtual std::string
name()
const override
52 obj_->updateVertsColorMap( vertsColorMap_ );
61 [[nodiscard]]
virtual size_t heapBytes()
const override
63 return name_.capacity() + vertsColorMap_.capacity();
67 std::shared_ptr<T> obj_;
68 VertColors vertsColorMap_;
static void setObjectDirty(const std::shared_ptr< T > &obj)
Definition MRChangeVertsColorMapAction.h:55
ChangeVertsColorMapAction(const std::string &name, const std::shared_ptr< T > &obj, VertColors &&newVertsColorMap)
use this constructor to remember object's vertex colors and immediate set new value
Definition MRChangeVertsColorMapAction.h:32
virtual std::string name() const override
Definition MRChangeVertsColorMapAction.h:43
T Obj
Definition MRChangeVertsColorMapAction.h:20
virtual size_t heapBytes() const override
returns the amount of memory this object occupies on heap
Definition MRChangeVertsColorMapAction.h:61
virtual void action(HistoryAction::Type) override
This function is called on history action (undo, redo, etc.)
Definition MRChangeVertsColorMapAction.h:48
Type
Definition MRHistoryAction.h:27
HistoryAction()=default
explicitly define ctors to avoid warning C5267: definition of implicit copy constructor is deprecated...
ChangeVertsColorMapAction(const std::string &name, const std::shared_ptr< T > &obj)
use this constructor to remember object's vertex colors before making any changes in them
Definition MRChangeVertsColorMapAction.h:23
@ DIRTY_VERTS_COLORMAP
Definition MRVisualObject.h:86
only for bindings generation
Definition MRCameraOrientationPlugin.h:8