TuttleOFX
1
|
00001 #ifndef _TUTTLE_HOST_OFX_PARAM_PARAMGROUP_HPP_ 00002 #define _TUTTLE_HOST_OFX_PARAM_PARAMGROUP_HPP_ 00003 00004 #include "OfxhParam.hpp" 00005 #include "OfxhParamSet.hpp" 00006 #include "OfxhParamDescriptor.hpp" 00007 00008 namespace tuttle { 00009 namespace host { 00010 namespace ofx { 00011 namespace attribute { 00012 00013 class OfxhParamGroup 00014 : public OfxhParam 00015 , public OfxhParamSet 00016 { 00017 public: 00018 OfxhParamGroup( const OfxhParamDescriptor& descriptor, const std::string& name, OfxhParamSet& setInstance ) : OfxhParam( descriptor, name, setInstance ) {} 00019 virtual ~OfxhParamGroup() {} 00020 00021 void deleteChildrens() 00022 { 00023 _paramVector.clear(); 00024 } 00025 00026 void setChildrens( const OfxhParamSet* childrens ); 00027 OfxhParamSet* getChildrens() const; 00028 void addChildren( OfxhParam* children ); 00029 00030 property::OfxhSet& getParamSetProps() 00031 { 00032 return _paramSetInstance->getParamSetProps(); 00033 } 00034 00035 virtual OfxhParam* newParam( const OfxhParamDescriptor& descriptor ) OFX_EXCEPTION_SPEC 00036 { 00037 BOOST_THROW_EXCEPTION( exception::Bug() ); 00038 // return _paramSetInstance->newParam( descriptor ); 00039 } 00040 00041 /// The inheriting plugin instance needs to set this up to deal with 00042 /// plug-ins changing their own values. 00043 virtual void paramChanged( const attribute::OfxhParam& param, const EChange change ) 00044 { 00045 _paramSetInstance->paramChanged( param, change ); 00046 } 00047 00048 /// Triggered when the plug-in calls OfxParameterSuiteV1::paramEditBegin 00049 virtual void editBegin( const std::string& name ) OFX_EXCEPTION_SPEC 00050 { 00051 return _paramSetInstance->editBegin( name ); 00052 } 00053 00054 /// Triggered when the plug-in calls OfxParameterSuiteV1::paramEditEnd 00055 virtual void editEnd() OFX_EXCEPTION_SPEC 00056 { 00057 return _paramSetInstance->editEnd(); 00058 } 00059 00060 bool paramTypeHasData() const { return false; } 00061 00062 std::size_t getHashAtTime( const OfxTime time ) const { return 0; } 00063 }; 00064 00065 } 00066 } 00067 } 00068 } 00069 00070 #endif 00071