diff pytouhou/ui/sprite.pyx @ 393:9e2cbb2c2c64

Implement THTX, uncompressed textures stored inside ANM files, and use it instead of pyglet’s own wrapper.
author Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
date Wed, 06 Feb 2013 19:55:54 +0100
parents f3099ebf4f61
children c5ba11ede097
line wrap: on
line diff
--- a/pytouhou/ui/sprite.pyx
+++ b/pytouhou/ui/sprite.pyx
@@ -66,7 +66,7 @@ cpdef object get_sprite_rendering_data(o
 
     (x1, x2 , x3, x4), (y1, y2, y3, y4), (z1, z2, z3, z4), _ = vertmat.data
 
-    key = (sprite.anm.first_name, sprite.anm.secondary_name), sprite.blendfunc
+    key = sprite.anm.texture, sprite.blendfunc
     r, g, b = sprite.color
     values = ((x1, y1, z1), (x2, y2, z2), (x3, y3, z3), (x4, y4, z4)), uvs, [r, g, b, sprite.alpha] * 4
     sprite._rendering_data = key, values