Ver Fonte

disabel: c/print to speedup exec time

micha há 3 anos atrás
pai
commit
e62a62311f
2 ficheiros alterados com 8 adições e 8 exclusões
  1. 5 5
      _LibreLightDesk.py
  2. 3 3
      console.py

+ 5 - 5
_LibreLightDesk.py

@@ -275,7 +275,7 @@ def update_raw_dmx(data ,value=None,args=[],xfade=0,flash=0,pfx="d",fx=0):
                 else:
                     v=row["VALUE"]
                     xcmd = "{:0.4f}".format(v)
-                    cprint([v])
+                    #cprint([v])
                     if type(v) is float:
                         jxcmd["VALUE"]  = v #round(v,3)
                     else:
@@ -1547,7 +1547,7 @@ class GUI(Base):
                 #elif vcmd[i]["VALUE"] is not None or ("FX" in vcmd[i] and vcmd[i]["FX"]):
                 #    cprint("jvcmd",vcmd[i])
                 #    cmd.append(vcmd[i])
-                cprint("jvcmd",vcmd[i])
+                #cprint("jvcmd",vcmd[i])
                 cmd.append(vcmd[i])
 
         if cmd and not modes.val("BLIND"):
@@ -2177,7 +2177,7 @@ class Fixtures(Base):
             text = str(attr)+' '+str(round(v,2))
             #self.gui.update(fix,attr,args={"text":text})
             #print("END 5454 _=_=_=_=_==_")
-        cprint("update_raw",cmd,color="red")
+        #cprint("update_raw",cmd,color="red")
         return cmd
 
     def encoder(self,fix,attr,xval="",xfade=0):
@@ -2403,7 +2403,7 @@ class Presets(Base):
 
         sdata = self.val_presets[nr]
         for fix in sdata:
-            print("exec.clear()",nr,fix,sdata[fix])
+            #print("exec.clear()",nr,fix,sdata[fix])
             for attr in sdata[fix]:
                 row = sdata[fix][attr]
                 if fix == "CFG":
@@ -2435,7 +2435,7 @@ class Presets(Base):
                         row["FX2"]["BASE"] = x[5] 
                     row["FXOLD"] = row["FX"]
                     row["FX"] = ""
-                cprint("exec.clear()",nr,fix,row)
+                #cprint("exec.clear()",nr,fix,row)
 
             
     def get_raw_map(self,nr):

+ 3 - 3
console.py

@@ -440,8 +440,8 @@ def JCB(data):
             #print(j)
             cmds = json.loads(jdata)
             for x in cmds:
-                cprint(int(clock.time()*1000)/1000,end=" ",color="yellow")#time.time())
-                cprint("json", x,type(x),color="yellow")#,cmds[x])
+                #cprint(int(clock.time()*1000)/1000,end=" ",color="yellow")#time.time())
+                #cprint("json", x,type(x),color="yellow")#,cmds[x])
 
                 if "DMX" in x:
                     DMX = int(x["DMX"])
@@ -479,7 +479,7 @@ def JCB(data):
                 
                 if type(fx2) is dict and fx2:
 
-                    cprint("FX2",DMX,fx2,color="green")
+                    #cprint("FX2",DMX,fx2,color="green")
                     xtype="fade"
                     size  = 10
                     speed = 10