more modulo

This commit is contained in:
j 2012-06-15 16:15:41 +02:00
parent fed701b0c8
commit 951fcdf837
1 changed files with 2 additions and 2 deletions

View File

@ -307,7 +307,7 @@ class Timelines():
self.large_tile_last_w = self.frame_n % self.large_tile_w or self.large_tile_w
if self.render_small_tiles:
self.small_tile_n = int(math.ceil(self.duration / self.small_tile_w))
self.small_tile_last_w =int(math.ceil(self.duration % self.small_tile_w))
self.small_tile_last_w =int(math.ceil(self.duration % self.small_tile_w)) or self.small_tile_w
if self.render_antialias:
self._open_full_tile()
@ -599,7 +599,7 @@ class Timelines():
if small_tile_x <= self.small_tile_image[small_mode].size[0] - 60:
w = 60
else:
w = self.small_tile_last_w % 60
w = self.small_tile_last_w % 60 or 60
resize = (w, self.small_tile_h)
resized = self.large_tile_image[mode].resize(resize, Image.ANTIALIAS)
paste = (small_tile_x, 0)