Beispiel #1
0
 def _updateState(self):
     self._log.debug("_updateState()")
     self._windowTickMin = PlayingSongState.getCurrentTick()
     ticksOnScreen = self._beatsOnScreen * PlayingSongState.getTicksPerBeat(
     )
     self._windowTickMax = self._windowTickMin + ticksOnScreen
     self._log.debug(
         "windowTickMin={} windowTickMax={} ticksOnScreen={}".format(
             self._windowTickMin, self._windowTickMax, ticksOnScreen))
    def update(self, drawingSurface):
        # TODO: this is computed for each track/channel/program tuple. It should
        # be done once per frame.
        self.minVisibleTick = PlayingSongState.getCurrentTick()
        ticksOnScreen = self._beatsOnScreen * PlayingSongState.getTicksPerBeat()
        self.maxVisibleTick = self.minVisibleTick + ticksOnScreen

        drawingSurface.drawBox(
            self._x, self._y, self._x + self._width, self._y + self._height, colour=(128, 128, 128, 255)
        )

        for note in self._guiNotes:
            note.update(drawingSurface)
Beispiel #3
0
    def update(self, drawingSurface):
        # TODO: this is computed for each track/channel/program tuple. It should
        # be done once per frame.
        self.minVisibleTick = PlayingSongState.getCurrentTick()
        ticksOnScreen = self._beatsOnScreen * PlayingSongState.getTicksPerBeat()
        self.maxVisibleTick = self.minVisibleTick + ticksOnScreen

        drawingSurface.drawBox(self._x, self._y,
                               self._x + self._width, self._y + self._height,
                               colour=(128, 128, 128, 255))

        for note in self._guiNotes:
            note.update(drawingSurface)
Beispiel #4
0
 def _updateState(self):
     self._log.debug("_updateState()")
     self._windowTickMin = PlayingSongState.getCurrentTick()
     ticksOnScreen = self._beatsOnScreen * PlayingSongState.getTicksPerBeat()
     self._windowTickMax = self._windowTickMin + ticksOnScreen
     self._log.debug("windowTickMin={} windowTickMax={} ticksOnScreen={}".format(self._windowTickMin, self._windowTickMax, ticksOnScreen))