TuttleOFX  1
HSLOverlay.hpp
Go to the documentation of this file.
00001 #ifndef HSLOVERLAY_HPP
00002 #define HSLOVERLAY_HPP
00003 
00004 #include "HistogramPlugin.hpp"
00005 #include "HistogramDisplay.hpp"
00006 
00007 #include <tuttle/plugin/global.hpp>
00008 #include <tuttle/plugin/interact/interact.hpp>
00009 #include <tuttle/plugin/interact/InteractInfos.hpp>
00010 
00011 #include <ofxsImageEffect.h>
00012 #include <ofxsInteract.h>
00013 
00014 namespace tuttle {
00015 namespace plugin {
00016 namespace histogram {
00017         
00018 /*
00019  *Enum used to know which RGB channel are selected
00020  */
00021 enum ESelectedChannelHSL
00022 {
00023         eSelectedChannelMoreHSL,                //More than one RGB channel are selected
00024         eSelectedChannelH,                              //Only red is selected
00025         eSelectedChannelS,                              //Only green is selected
00026         eSelectedChannelL,                              //Only blue is selected
00027         eSelectedChannelNoneHSL                 //None channel is selected
00028 };
00029 
00030 /// @todo class HSLOverlay : public OFX::OverlayInteract (when Nuke overlay works)
00031 class HSLOverlay
00032 {
00033 public:
00034         /*Class arguments*/
00035         HistogramPlugin* _plugin;       //plugin reference
00036         //interact::InteractInfos _infos;  (when Nuke overlay works)
00037                 
00038         /*Creator*/
00039         //HSLOverlay(OfxInteractHandle handle, OFX::ImageEffect* effect); (when Nuke overlay works)
00040         HSLOverlay(HistogramPlugin* plugin); //temporary
00041         
00042         /*Destructor*/
00043         ~HSLOverlay();
00044         
00045         /*draw main function*/
00046         bool draw(const OFX::DrawArgs& args);
00047         
00048         /*get selected channels*/
00049         ESelectedChannelHSL getOnlyChannelSelectedHSL()const;
00050         
00051         /*get overlay data*/
00052         OverlayData& getOverlayData();
00053         
00054         /*Display grid*/
00055         void displayGrid(float height, float width);
00056 };
00057 
00058 }
00059 }
00060 }
00061 #endif  /* HSLOVERLAY_HPP */
00062