00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019 #ifndef OST_COLOR_OPS_MAP_HANDLE_COLOR_OP_HH
00020 #define OST_COLOR_OPS_MAP_HANDLE_COLOR_OP_HH
00021
00022 #include <ost/gfx/gradient.hh>
00023
00024 #include <ost/info/info_fw.hh>
00025
00026 #include <ost/img/map.hh>
00027
00028 #include <ost/gfx/color_ops/gradient_color_op.hh>
00029
00030
00031
00032
00033
00034
00035 namespace ost { namespace gfx {
00036
00037 class DLLEXPORT_OST_GFX MapHandleColorOp: public GradientColorOp {
00038 public:
00039 MapHandleColorOp();
00040 MapHandleColorOp(const String& selection, const String& property, const gfx::Gradient& gradient, float minv, float maxv, const img::MapHandle& mh);
00041 MapHandleColorOp(const String& selection, int mask, const String& property, const gfx::Gradient& gradient, float minv, float maxv, const img::MapHandle& mh);
00042 MapHandleColorOp(const mol::QueryViewWrapper& query_view, const String& property, const gfx::Gradient& gradient, float minv, float maxv, const img::MapHandle& mh);
00043 MapHandleColorOp(const mol::QueryViewWrapper& query_view, int mask, const String& property, const gfx::Gradient& gradient, float minv, float maxv, const img::MapHandle& mh);
00044
00045 virtual bool CanApplyTo(const GfxObjP& obj) const;
00046 virtual void ApplyTo(GfxObjP& obj) const;
00047
00048 virtual void SetMapHandle(const img::MapHandle& mh);
00049 virtual const img::MapHandle& GetMapHandle() const;
00050
00051 virtual void ToInfo(info::InfoGroup& group) const;
00052 static gfx::MapHandleColorOp FromInfo(info::InfoGroup& group);
00053
00054 private:
00055 void Init();
00056 img::MapHandle mh_;
00057 };
00058
00059 }}
00060
00061 #endif
00062