You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 

24 lines
594 B

#!/usr/bin/python
import sys
import blup.animation
import writebml
anim = blup.animation.load(sys.argv[1])
plasmaanim = blup.animation.load('/tmp/plasma.bml')
newanim = blup.animation.Animation(anim.dimension)
plasmaFrame = 0
for f in anim:
newframe = blup.animation.AnimationFrame(f.dimension, f.delay)
for x in range(anim.dimension.width):
for y in range(anim.dimension.height):
p = f.getPixel(x,y)
if max(p) > 14:
newframe.setPixel(x,y, plasmaanim[plasmaFrame].getPixel(x,y))
newanim.addFrame(newframe)
plasmaFrame += 1
writebml.writeBml(newanim, '/tmp/colormarq.bml')