Changeset - 5bcb950024af
bin/bumppad
Show inline comments
 
@@ -55,7 +55,8 @@ class pad(tk.Frame):
 
        self.master.after_idle(self.output)
 

	
 
    def output(self):
 
        dmx = sub_maxes(*[s * l for s, l in list(self.levs.items())]).get_dmx_list()
 
        dmx = sub_maxes(*[s * l
 
                          for s, l in list(self.levs.items())]).get_dmx_list()
 
        dmxclient.outputlevels(dmx, clientid="bumppad")
 

	
 

	
bin/collector
Show inline comments
 
@@ -7,7 +7,6 @@ custom code for some attributes.
 
Input can be over http or zmq.
 
"""
 

	
 

	
 
from run_local import log
 

	
 
from rdflib import URIRef, Literal
bin/curvecalc
Show inline comments
 
@@ -9,7 +9,6 @@ todo: curveview should preserve more obj
 

	
 
"""
 

	
 

	
 
import sys
 
import imp
 
sys.path.append('/usr/lib/python2.7/dist-packages')  # For gtk
 
@@ -413,7 +412,8 @@ class Main(object):
 
            ('input time', lambda t: "%.2fs" % t),
 
            ('output levels', lambda levels: textwrap.fill(
 
                "; ".join([
 
                    "%s:%.2f" % (n, v) for n, v in list(levels.items())[:2] if v > 0
 
                    "%s:%.2f" % (n, v) for n, v in list(levels.items())[:2] if v
 
                    > 0
 
                ]), 70)),
 
            ('update period', lambda t: "%.1fms" % (t * 1000)),
 
            ('update status', lambda x: str(x)),
bin/dmxserver
Show inline comments
 
@@ -24,7 +24,6 @@ todo:
 
  if parport fails, run in dummy mode (and make an option for that too)
 
"""
 

	
 

	
 
from twisted.internet import reactor
 
from twisted.web import xmlrpc, server
 
import sys, time, os
 
@@ -184,8 +183,8 @@ class XMLRPCServe(xmlrpc.XMLRPC):
 

	
 
    def printlevels(self):
 
        """write all the levels to stdout"""
 
        print("Levels:", "".join(
 
            ["% 2d " % (x * 100) for x in self.combinedlevels]))
 
        print("Levels:",
 
              "".join(["% 2d " % (x * 100) for x in self.combinedlevels]))
 

	
 
    def printstats(self):
 
        """print the clock, freq, etc, with a \r at the end"""
bin/effecteval
Show inline comments
 
#!bin/python
 

	
 

	
 
from run_local import log
 
from twisted.internet import reactor
 
from twisted.internet.defer import inlineCallbacks, returnValue
bin/keyboardcomposer
Show inline comments
 
#!bin/python
 

	
 

	
 
from run_local import log
 
import cgi, time, logging
 
from optparse import OptionParser
 
@@ -501,9 +500,8 @@ class KeyboardComposer(tk.Frame, SubClie
 
        row['bg'] = 'black'
 

	
 
    def get_levels(self):
 
        return dict([
 
            (uri, box.slider_var.get()) for uri, box in list(self.subbox.items())
 
        ])
 
        return dict([(uri, box.slider_var.get())
 
                     for uri, box in list(self.subbox.items())])
 

	
 
    def get_output_settings(self, _graph=None):
 
        _graph = _graph or self.graph
bin/lightsim
Show inline comments
 
#!bin/python
 

	
 

	
 
import run_local
 
import sys, logging
 

	
bin/paintserver
Show inline comments
 
#!bin/python
 

	
 

	
 
from run_local import log
 
import json
 
from twisted.internet import reactor
bin/subcomposer
Show inline comments
 
@@ -16,7 +16,6 @@ subcomposer
 

	
 
"""
 

	
 

	
 
from run_local import log
 
import time, logging
 

	
 
@@ -161,8 +160,8 @@ class Subcomposer(tk.Frame):
 
        graph = self.graph
 

	
 
        def ann():
 
            print("currently: session=%s currentSub=%r _currentChoice=%r" % (
 
                self.session, self.currentSub(), self._currentChoice()))
 
            print("currently: session=%s currentSub=%r _currentChoice=%r" %
 
                  (self.session, self.currentSub(), self._currentChoice()))
 

	
 
        @graph.addHandler
 
        def graphChanged():
bin/tracker
Show inline comments
 
#!/usr/bin/python
 

	
 

	
 
import sys
 
sys.path.append("../../editor/pour")
 
sys.path.append("../light8")
light9/collector/collector.py
Show inline comments
 

	
 
import time
 
import logging
 
from rdflib import Literal
light9/collector/collector_client.py
Show inline comments
 

	
 
from light9 import networking
 
from light9.effect.settings import DeviceSettings
 
from twisted.internet import defer
light9/collector/device.py
Show inline comments
 

	
 
import logging
 
import math
 
from light9.namespaces import L9, RDF, DEV
light9/collector/output.py
Show inline comments
 

	
 
from rdflib import URIRef
 
import sys
 
import time
light9/curvecalc/client.py
Show inline comments
 
@@ -12,8 +12,10 @@ def sendLiveInputPoint(curve, value):
 
                                 method='POST',
 
                                 timeout=1,
 
                                 postdata=urllib.parse.urlencode({
 
                                     'curve': curve,
 
                                     'value': str(value),
 
                                     'curve':
 
                                     curve,
 
                                     'value':
 
                                     str(value),
 
                                 }))
 

	
 
    @f.addCallback
light9/curvecalc/curve.py
Show inline comments
 

	
 
import glob, time, logging, ast, os
 
from bisect import bisect_left, bisect
 
import louie as dispatcher
light9/curvecalc/curveview.py
Show inline comments
 

	
 
import math, logging, traceback
 
from gi.repository import Gtk
 
from gi.repository import Gdk
 
@@ -555,8 +554,8 @@ class Curveview(object):
 

	
 
    def print_state(self, msg=""):
 
        if 0:
 
            print("%s: dragging_dots=%s selecting=%s" % (
 
                msg, self.dragging_dots, self.selecting))
 
            print("%s: dragging_dots=%s selecting=%s" %
 
                  (msg, self.dragging_dots, self.selecting))
 

	
 
    def select_points(self, pts):
 
        """set selection to the given point values (tuples, not indices)"""
light9/curvecalc/zoomcontrol.py
Show inline comments
 

	
 
from gi.repository import Gtk
 
from gi.repository import GObject
 
from gi.repository import GooCanvas
light9/effect/effecteval.py
Show inline comments
 

	
 
from rdflib import URIRef, Literal
 
from light9.namespaces import L9, RDF, DEV
 
from webcolors import rgb_to_hex, hex_to_rgb
light9/effect/scale.py
Show inline comments
 

	
 
from rdflib import Literal
 
from decimal import Decimal
 
from webcolors import rgb_to_hex, hex_to_rgb
light9/effect/sequencer.py
Show inline comments
 
@@ -2,7 +2,6 @@
 
copies from effectloop.py, which this should replace
 
'''
 

	
 

	
 
from louie import dispatcher
 
from rdflib import URIRef
 
from twisted.internet import reactor
light9/effect/settings.py
Show inline comments
 

	
 
"""
 
Data structure and convertors for a table of (device,attr,value)
 
rows. These might be effect attrs ('strength'), device attrs ('rx'),
light9/effect/simple_outputs.py
Show inline comments
 

	
 
import traceback
 
from light9.namespaces import L9, RDF
 
from light9.effect.scale import scale
light9/effecteval/effectloop.py
Show inline comments
 

	
 
import time, json, logging, traceback
 
import numpy
 
import serial
 
@@ -182,8 +181,9 @@ class EffectLoop(object):
 
                self.lastLogTime = now
 

	
 
    def logMessage(self, out):
 
        return ("send dmx: {%s}" % ", ".join(
 
            "%r: %.3g" % (str(k), v) for k, v in list(out.get_levels().items())))
 
        return ("send dmx: {%s}" %
 
                ", ".join("%r: %.3g" % (str(k), v)
 
                          for k, v in list(out.get_levels().items())))
 

	
 

	
 
Z = numpy.zeros((50, 3), dtype=numpy.float16)
light9/io/__init__.py
Show inline comments
 

	
 
import sys
 

	
 

	
light9/io/udmx.py
Show inline comments
 

	
 
import logging
 
import usb.core
 
from usb.util import CTRL_TYPE_VENDOR, CTRL_RECIPIENT_DEVICE, CTRL_OUT
light9/paint/solve.py
Show inline comments
 

	
 
from light9.namespaces import RDF, L9, DEV
 
from PIL import Image
 
import numpy
light9/vidref/replay.py
Show inline comments
 

	
 
import os, gtk, shutil, logging, time
 
from bisect import bisect_left
 
from decimal import Decimal
0 comments (0 inline, 0 general)