Commit 750ea721 authored by Guido van Rossum's avatar Guido van Rossum

Fix reference to undefined 'memsize' in calcnframes().

parent c83e5d1b
...@@ -476,7 +476,7 @@ class VideoBagOfTricks: ...@@ -476,7 +476,7 @@ class VideoBagOfTricks:
if nframes == 0: if nframes == 0:
maxmem = self.getint(self.in_maxmem, 1.0) maxmem = self.getint(self.in_maxmem, 1.0)
memsize = int(maxmem * 1024 * 1024) memsize = int(maxmem * 1024 * 1024)
nframes = self.calcnframes() nframes = self.calcnframes(memsize)
info = (vformat, x, y, nframes, 1) info = (vformat, x, y, nframes, 1)
try: try:
info2, data, bitvec = self.video.CaptureBurst(info) info2, data, bitvec = self.video.CaptureBurst(info)
...@@ -489,7 +489,7 @@ class VideoBagOfTricks: ...@@ -489,7 +489,7 @@ class VideoBagOfTricks:
self.save_burst(info2, data, bitvec) self.save_burst(info2, data, bitvec)
self.setarrow() self.setarrow()
def calcnframes(self): def calcnframes(self, memsize):
gl.winset(self.window) gl.winset(self.window)
x, y = gl.getsize() x, y = gl.getsize()
pixels = x*y pixels = x*y
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment