# HG changeset patch # User Emmanuel Gil Peyrot # Date 1428516673 -7200 # Node ID dd393fa6e98869e4a6c41c9342c9e45eb42f0d6b # Parent df6ae915ebaa65364e0a453b12a86856b0031b07 Simplify the invert code in Animation. diff -r df6ae915ebaa -r dd393fa6e988 pytouhou/formats/animation.pyx --- a/pytouhou/formats/animation.pyx Wed Apr 08 18:53:13 2015 +0200 +++ b/pytouhou/formats/animation.pyx Wed Apr 08 20:11:13 2015 +0200 @@ -23,5 +23,6 @@ property size: def __set__(self, tuple value): + cdef double width, height width, height = value - self.size_inv[:] = [1. / width, 1. / height] + self.size_inv[:] = [1 / width, 1 / height]