Merge branch 'bug_274_disable_fast_winding_for_non_ts'
[enigma2.git] / lib / python / Plugins / SystemPlugins / VideoEnhancement / VideoEnhancement.py
index 3fbef7c2094a83a046836817a0071e65c129f7fd..4ba495824e6c049712707b5efaa61be142611829 100755 (executable)
@@ -133,23 +133,6 @@ class VideoEnhancement:
                else:
                        config.pep.digital_contour_removal = NoSave(ConfigNothing())
 
-               if os_path.exists("/proc/stb/vmpeg/0/pep_scaler_sharpness"):
-                       def setScaler_sharpness(config):
-                               myval = int(config.value)
-                               try:
-                                       print "--> setting scaler_sharpness to: %0.8X" % myval
-                                       open("/proc/stb/vmpeg/0/pep_scaler_sharpness", "w").write("%0.8X" % myval)
-                               except IOError:
-                                       print "couldn't write pep_scaler_sharpness"
-
-                               if not VideoEnhancement.firstRun:
-                                       self.setConfiguredValues()
-
-                       config.pep.scaler_sharpness = ConfigSlider(default=13, limits=(0,26))
-                       config.pep.scaler_sharpness.addNotifier(setScaler_sharpness)
-               else:
-                       config.pep.scaler_sharpness = NoSave(ConfigNothing())
-
                if os_path.exists("/proc/stb/vmpeg/0/pep_split"):
                        def setSplitMode(config):
                                try:
@@ -255,6 +238,26 @@ class VideoEnhancement:
                else:
                        config.pep.dynamic_contrast = NoSave(ConfigNothing())
 
+               try:
+                       x = config.av.scaler_sharpness.value
+               except KeyError:
+                       if os_path.exists("/proc/stb/vmpeg/0/pep_scaler_sharpness"):
+                               def setScaler_sharpness(config):
+                                       myval = int(config.value)
+                                       try:
+                                               print "--> setting scaler_sharpness to: %0.8X" % myval
+                                               open("/proc/stb/vmpeg/0/pep_scaler_sharpness", "w").write("%0.8X" % myval)
+                                       except IOError:
+                                               print "couldn't write pep_scaler_sharpness."
+
+                                       if not VideoEnhancement.firstRun:
+                                               self.setConfiguredValues()
+
+                               config.av.scaler_sharpness = ConfigSlider(default=13, limits=(0,26))
+                               config.av.scaler_sharpness.addNotifier(setScaler_sharpness)
+                       else:
+                               config.av.scaler_sharpness = NoSave(ConfigNothing())
+
                if VideoEnhancement.firstRun:
                        self.setConfiguredValues()