rt300@0: // rt300@0: // sliderPanel.h rt300@0: // tweakathlon rt300@0: // rt300@0: // Created by Robert Tubb on 11/02/2014. rt300@0: // rt300@0: // rt300@0: rt300@0: #ifndef __tweakathlon__sliderPanel__ rt300@0: #define __tweakathlon__sliderPanel__ rt300@0: rt300@0: #include rt300@0: #include "UIElementContainer.h" rt300@0: #include rt300@0: #include "globalVariables.h" rt300@0: #include "ofMain.h" rt300@0: #include "UIElement.h" rt300@0: #include "boost/bind.hpp" rt300@0: #include "boost/function.hpp" rt300@0: #include "timeController.h" rt300@0: #include "ButtronSlider.h" rt300@0: #include "ButtronXY.h" rt300@0: #include "3Dbox.h" rt300@0: #include "3DboxGL.h" rt300@27: #include "6Dbox.h" rt300@21: #include "ButtronSlider.h" rt300@0: // panel with sliders and xy pads rt300@27: rt300@27: // AND 6DOF BOXES !!!!! rt300@0: class SliderPanel : public UIElementContainer{ rt300@0: rt300@0: public: rt300@0: SliderPanel(float ax, rt300@0: float ay, rt300@0: float awidth, rt300@0: float aheight, rt300@0: const UIProps& aprops, rt300@0: vector elemList); rt300@27: rt300@27: void setAndShowHint(vector values, ofImage* texture); rt300@31: void setHintNoShow(vector values, ofImage* texture); rt300@27: rt300@27: void showHint(bool value); rt300@0: // rt300@27: void setHintValues(vector vals); rt300@28: void setValues(vector vals); rt300@27: void setHintColor(ofColor c); rt300@27: void setSliderColors(ofColor c); rt300@27: void flash(); rt300@27: void setBgColor(ofColor c); rt300@0: vector generateControls(vector elemList, controlPanelType panelType); rt300@27: rt300@27: UIElement* getSlider(int index); rt300@27: void setHintTexture(ofImage* texture); rt300@37: void setIndicatorTexture(ofImage* texture = NULL); rt300@28: void animateToNewHintValues(vector newTargetValues, float timeToTake, ofImage* newTexture); rt300@31: void animateToNewValues(vector newTargetValues, float timeToTake); rt300@27: void showValueIndicators(bool show); rt300@28: void update(); rt300@28: controlPanelType getPanelType(){ rt300@28: return thisPanelType; rt300@28: } rt300@28: void flashResultLight(ofColor c, int howLong); rt300@28: void turnOffResultLight(); rt300@0: private: rt300@0: bool flashing; rt300@27: controlPanelType thisPanelType; rt300@28: bool animating; rt300@28: ofLight resultLight; rt300@0: }; rt300@0: rt300@0: #endif /* defined(__tweakathlon__sliderPanel__) */