示例#1
0
    def __init__(self, matrix, data, dimmer, sleepEvent):
        self.matrix = Matrix(matrix, (64, 32))
        self.data = data
        self.sleepEvent = sleepEvent

        self.screen_config = screenConfig("64x32_config")
        self.width = 64
        self.height = 32

        self._dimmer = dimmer
示例#2
0
 def __init__(self, matrix, data):
     self.matrix = matrix
     self.data = data
     self.screen_config = screenConfig("64x32_config")
     self.canvas = matrix.CreateFrameCanvas()
     self.width = 64
     self.height = 32
     # Create a new data image.
     self.image = Image.new('RGB', (self.width, self.height))
     self.draw = ImageDraw.Draw(self.image)
     # Load the fonts
     self.font = ImageFont.truetype("fonts/score_large.otf", 16)
     self.font_mini = ImageFont.truetype("fonts/04B_24__.TTF", 8)
示例#3
0
 def __init__(self, matrix, data):
     self.matrix = matrix
     self.data = data
     self.screen_config = screenConfig("64x32_config")
     self.canvas = matrix.CreateFrameCanvas()
     self.width = 64
     self.height = 32
     self.avsize = 19
     # use this to check if week has changed
     self.week = data.week
     # Create a new data image.
     self.image = Image.new('RGB', (self.width, self.height))
     self.draw = ImageDraw.Draw(self.image)
     # Load the fonts
     self.font = ImageFont.truetype("fonts/score_large.otf", 16)
     self.font_mini = ImageFont.truetype("fonts/04B_24__.TTF", 8)
     self.font_vs = ImageFont.truetype("fonts/CG pixel 3x5.ttf", 10)
     self.font_res = ImageFont.truetype("fonts/CG pixel 3x5.ttf", 6)