From b719c544ad07521a2ab2817831b6dd646a48867f Mon Sep 17 00:00:00 2001 From: j <0x006A@0x2620.org> Date: Fri, 28 Oct 2011 01:16:43 +0200 Subject: [PATCH] fix data path --- pandora/scripts/item_icon | 6 +++--- pandora/scripts/list_icon | 2 +- pandora/scripts/oxdb_poster | 4 ++-- pandora/scripts/padma_poster | 2 +- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/pandora/scripts/item_icon b/pandora/scripts/item_icon index c5eb76461..f1054ee82 100755 --- a/pandora/scripts/item_icon +++ b/pandora/scripts/item_icon @@ -40,14 +40,14 @@ def render_icon(frame, timeline, icon): timeline_width = 896 timeline_height = 128 timeline_image = Image.new('RGB', (timeline_width + 8, timeline_height + 8), (255, 255, 255)) - mask_image = Image.open(os.path.join(static_root, 'png', 'iconTimelineOuterMask.png')) + mask_image = Image.open(os.path.join(static_root, 'iconTimelineOuterMask.png')) icon_image.paste(timeline_image, (timeline_left - 4, timeline_top - 4), mask=mask_image) timeline_image = Image.open(timeline) if timeline else Image.new('RGB', (timeline_width, timeline_height), (0, 0, 0)) timeline_image = timeline_image.resize((timeline_width, timeline_height), Image.ANTIALIAS) - mask_image = Image.open(os.path.join(static_root, 'png', 'iconTimelineInnerMask.png')) + mask_image = Image.open(os.path.join(static_root, 'iconTimelineInnerMask.png')) icon_image.paste(timeline_image, (timeline_left, timeline_top), mask=mask_image) # we're using jpegs with border-radius - # mask_image = Image.open(os.path.join(static_root, 'png', 'iconMask.png')) + # mask_image = Image.open(os.path.join(static_root, 'iconMask.png')) # icon_image.putalpha(mask_image) icon_image.save(icon) diff --git a/pandora/scripts/list_icon b/pandora/scripts/list_icon index 47ec213e5..c2611ab80 100755 --- a/pandora/scripts/list_icon +++ b/pandora/scripts/list_icon @@ -39,7 +39,7 @@ def render_list_icon(frames, icon): frame_image = frame_image.crop((0, top, frame_width_, top + frame_height)) icon_image.paste(frame_image, (i % 2 * frame_width + (1 if i % 2 == 2 else 0), int(i / 2) * frame_height)) - mask_image = Image.open(os.path.join(static_root, 'png', 'iconMask.png')) + mask_image = Image.open(os.path.join(static_root, 'iconMask.png')) mask_image = mask_image.resize((icon_width, icon_height)) icon_image.putalpha(mask_image) icon_image.save(icon) diff --git a/pandora/scripts/oxdb_poster b/pandora/scripts/oxdb_poster index 54d898eb1..49630db1b 100755 --- a/pandora/scripts/oxdb_poster +++ b/pandora/scripts/oxdb_poster @@ -43,7 +43,7 @@ def render_poster(title, director, year, series, oxdb_id, imdb_id, frame, timeli poster_ratio = poster_width / poster_height poster_image = Image.new('RGB', (poster_width, poster_height)) draw = ImageDraw.Draw(poster_image) - font_file = os.path.join(static_root, 'ttf', 'DejaVuSansCondensedBold.ttf') + font_file = os.path.join(static_root, 'DejaVuSansCondensedBold.ttf') font_size = { 'small': 28, @@ -107,7 +107,7 @@ def render_poster(title, director, year, series, oxdb_id, imdb_id, frame, timeli # logo logo_height = 32 - logo_image = Image.open(os.path.join(static_root, 'png', 'logo.png')) + logo_image = Image.open(os.path.join(static_root, 'logo.png')) logo_width = int(round(logo_height * logo_image.size[0] / logo_image.size[1])) logo_image = logo_image.resize((logo_width, logo_height), Image.ANTIALIAS) logo_left = text_width - text_margin - logo_width diff --git a/pandora/scripts/padma_poster b/pandora/scripts/padma_poster index 6abc80725..07ee23fae 100755 --- a/pandora/scripts/padma_poster +++ b/pandora/scripts/padma_poster @@ -24,7 +24,7 @@ def render_poster(id, title, frame, timeline, poster): poster_ratio = poster_width / poster_height poster_color = (255, 255, 0) poster_image = Image.new('RGB', (poster_width, poster_height)) - font_file = os.path.join(static_root, 'ttf', 'DejaVuSansCondensedBold.ttf') + font_file = os.path.join(static_root, 'DejaVuSansCondensedBold.ttf') font_size = 48 # timeline