47 #ifndef _MIRA_COLORMAPPROPERTY_H_ 48 #define _MIRA_COLORMAPPROPERTY_H_ 79 template <
typename Reflector>
81 r.delegate(mColormapIdentifier);
84 template <
typename Reflector>
86 r.delegate(mColormapIdentifier);
105 mColormapIdentifier = identifier;
111 const std::string&
str()
const {
112 return mColormapIdentifier;
179 void checkValid()
const;
184 std::string mColormapIdentifier;
185 const ColormapDesc* mColormapDesc;
187 boost::function<bool(const Colormap*)> mFilterFunction;
190 template <
typename SerializerTag>
211 class ComboBoxDelegate;
Abstract base class for all derived property node classes.
Definition: PropertyNode.h:212
ColormapPropertyComboBox(PropertyNode *p, QWidget *parent)
Type trait that indicates whether a type should be serialized "transparently", i.e.
Definition: IsTransparentSerializable.h:81
This file contains classes for different color colormaps (like Jet, HSV, etc.)
Declaration and implementation of the property node hierarchy.
Definition: ColormapProperty.h:198
specialize cv::DataType for our ImgPixel and inherit from cv::DataType<Vec>
Definition: IOService.h:67
#define MIRA_SPLIT_REFLECT_MEMBER
Macro that insert a class member reflect() method just splitting reflection into a reflectRead() and ...
Definition: SplitReflect.h:189
Definition: PropertyEditorDelegateUtils.h:73
Base class for continuous color colormaps.
Definition: Colormap.h:217
Provides type trait that indicates whether a type should be serialized "transparently".
static bool filterContinuous(const Colormap *colormap)
A predefined filter function that filters all ContinuousColormap classes.
Definition: ColormapProperty.h:170
Provides MIRA_SPLIT_REFLECT macros.
std::string DelegateTo
Definition: ColormapProperty.h:193
void slotSetValue(int value)
const Colormap & getColormap() const
Returns the chosen color colormap.
bool isValid() const
Returns true, if a valid colormap was chosen.
Utils for PropertyEditor delegates.
A special property class that can be used as member, if you want to provide a ComboBox where the user...
Definition: ColormapProperty.h:73
const QVector< QRgb > & getColorTable() const
Returns the chosen color colormap as color table in Qt compliant form.
void reflectRead(Reflector &r)
Definition: ColormapProperty.h:80
void initFromProperty() override
Definition: ColormapProperty.h:204
void setFilter(boost::function< bool(const Colormap *)> filterFunction)
Allows to specify a filter function.
ColormapProperty()
Creates property with no selected colormap.
Definition: ColormapProperty.h:95
Base class for color colormaps.
Definition: Colormap.h:62
void propertyEdited() override
bool filter(const Colormap *colormap) const
Returns true, if the specified colormap has passed the optional set filter.
void reflectWrite(Reflector &r)
Definition: ColormapProperty.h:85
const std::string & str() const
Returns the set colormap identifier as string.
Definition: ColormapProperty.h:111
ColormapProperty & operator=(const std::string &identifier)
Assigns colormap identifier string.
Definition: ColormapProperty.h:104