add queue tasks

This commit is contained in:
MaZderMind 2016-06-16 00:18:07 +02:00
parent ff66b8bb00
commit 6bcdcef060

View file

@ -118,4 +118,32 @@ def debug():
)
def tasks(queue, args):
raise NotImplementedError('call with --debug to render your intro/outro')
# iterate over all events extracted from the schedule xml-export
for event in events(scheduleUrl, titlemap):
# generate a task description and put them into the queue
queue.put(Rendertask(
infile = 'intro.svg',
outfile = str(event['id'])+".ts",
sequence = introFrames,
parameters = {
'$id': event['id'],
'$title': event['title'],
'$subtitle': event['subtitle'],
'$personnames': event['personnames']
}
))
# place a task for the outro into the queue
queue.put(Rendertask(
infile = 'outro.svg',
outfile = 'outro.dv',
sequence = outroFrames
))
# place the pause-sequence into the queue
queue.put(Rendertask(
infile = 'pause.svg',
outfile = 'pause.dv',
sequence = pauseFrames
))