Cybook Gen3:Fix thumbnail generation.

This commit is contained in:
Kovid Goyal 2009-02-21 11:38:24 -08:00
parent 2eee9da901
commit 0467af0c29
2 changed files with 2 additions and 1 deletions

View File

@ -33,6 +33,7 @@ class CYBOOKG3(USBMS):
EBOOK_DIR_MAIN = "eBooks"
EBOOK_DIR_CARD = "eBooks"
THUMBNAIL_HEIGHT = 144
SUPPORTS_SUB_DIRS = True
def upload_books(self, files, names, on_card=False, end_session=True,

View File

@ -30,7 +30,7 @@ def write_t2b(t2bfile, coverdata=None):
if coverdata != None:
coverdata = StringIO.StringIO(coverdata)
cover = Image.open(coverdata).convert("L")
cover.thumbnail((96, 144))
cover.thumbnail((96, 144), Image.ANTIALIAS)
t2bcover = Image.new('L', (96, 144), 'white')
x, y = cover.size