mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-06-23 15:30:45 -04:00
Fix Cybook cover size being a postage stamp withing the thumbnail generated.
This commit is contained in:
parent
21619e1b4f
commit
480a3cd3bb
@ -35,6 +35,8 @@ class CYBOOKG3(USBMS):
|
|||||||
EBOOK_DIR_CARD = "eBooks"
|
EBOOK_DIR_CARD = "eBooks"
|
||||||
SUPPORTS_SUB_DIRS = True
|
SUPPORTS_SUB_DIRS = True
|
||||||
|
|
||||||
|
THUMBNAIL_HEIGHT = 144
|
||||||
|
|
||||||
def upload_books(self, files, names, on_card=False, end_session=True,
|
def upload_books(self, files, names, on_card=False, end_session=True,
|
||||||
metadata=None):
|
metadata=None):
|
||||||
if on_card and not self._card_prefix:
|
if on_card and not self._card_prefix:
|
||||||
|
@ -30,7 +30,7 @@ def write_t2b(t2bfile, coverdata=None):
|
|||||||
if coverdata != None:
|
if coverdata != None:
|
||||||
coverdata = StringIO.StringIO(coverdata)
|
coverdata = StringIO.StringIO(coverdata)
|
||||||
cover = Image.open(coverdata).convert("L")
|
cover = Image.open(coverdata).convert("L")
|
||||||
cover.thumbnail((96, 144))
|
cover.thumbnail((96, 144), Image.ANTIALIAS)
|
||||||
t2bcover = Image.new('L', (96, 144), 'white')
|
t2bcover = Image.new('L', (96, 144), 'white')
|
||||||
|
|
||||||
x, y = cover.size
|
x, y = cover.size
|
||||||
|
Loading…
x
Reference in New Issue
Block a user