diff options
author | rcoh <rcoh@mit.edu> | 2011-01-27 16:50:59 -0500 |
---|---|---|
committer | rcoh <rcoh@mit.edu> | 2011-01-27 16:50:59 -0500 |
commit | 5fb3ea060025241105dc8e9a174513c112f9a133 (patch) | |
tree | e98b1b3eab0b05b0e518b08cbab086d224fd9250 /renderers/IndoorRenderer.py | |
parent | 5d29906fff79bc6e4ba83be7028e1380a0014d21 (diff) |
A metric $#%$-ton of changes. Added doc-strings to EVERYTHING. Phew. Fixed a massive bug that
increases performance in by up to a factor of 60. A bunch of new behaviors for the class.
Diffstat (limited to 'renderers/IndoorRenderer.py')
-rw-r--r-- | renderers/IndoorRenderer.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/renderers/IndoorRenderer.py b/renderers/IndoorRenderer.py index 76ec172..531a732 100644 --- a/renderers/IndoorRenderer.py +++ b/renderers/IndoorRenderer.py @@ -4,8 +4,9 @@ import util.NetworkOps as network import util.TimeOps as timeops import socket,pdb sock_port = 6038 -#Renderer for a Specific Light System. class IndoorRenderer(Renderer): + """IndoorRenderer is a renderer for a specific Light System""" + def initRenderer(self): self.stripLocations = {} #Dict that stores info necessary to render to #strips @@ -20,6 +21,7 @@ class IndoorRenderer(Renderer): for stripId in stripsInPowerSupply: self.stripLocations[stripId] = (ip, \ stripsInPowerSupply[stripId]) + def render(self, lightSystem, currentTime=timeops.time()): #try: for pixelStrip in lightSystem.pixelStrips: @@ -30,6 +32,4 @@ class IndoorRenderer(Renderer): self.sockets[ip] = network.getConnectedSocket(ip,sock_port) packet = composer.composePixelStripPacket(pixelStrip, port, currentTime) self.sockets[ip].send(packet, 0x00) - #except Exception as inst: - # print inst |