PKGBUILD fix libva/vdpau deps
[goodguy/cinelerra.git] / cinelerra-5.1 / plugins / colorbalance / colorbalance.C
index 7b8f0cffd01161201786b006221c299cad595e19..338466ca1a0d49246a48d98dabfb2a89024aa412 100644 (file)
@@ -43,11 +43,28 @@ REGISTER_PLUGIN(ColorBalanceMain)
 
 ColorBalanceConfig::ColorBalanceConfig()
 {
-       cyan = 0;
-       magenta = 0;
-       yellow = 0;
-       lock_params = 0;
-    preserve = 0;
+       reset(RESET_ALL);
+}
+
+void ColorBalanceConfig::reset(int clear)
+{
+       switch(clear) {
+               case RESET_CYAN : cyan = 0;
+                       break;
+               case RESET_MAGENTA : magenta = 0;
+                       break;
+               case RESET_YELLOW : yellow = 0;
+                       break;
+               case RESET_ALL :
+               case RESET_DEFAULT_SETTINGS :
+               default:
+                       cyan = 0;
+                       magenta = 0;
+                       yellow = 0;
+                       lock_params = 0;
+                       preserve = 0;
+                       break;
+       }
 }
 
 int ColorBalanceConfig::equivalent(ColorBalanceConfig &that)