removed extra params from _get_palette_bytes

This commit is contained in:
wiredfool 2017-02-23 07:38:46 -08:00
parent b315b6ecf3
commit 321c6165c9

View File

@ -472,7 +472,7 @@ def _get_local_header(fp, im, offset, flags):
include_color_table = im.encoderinfo.get('include_color_table')
if include_color_table:
palette = im.encoderinfo.get("palette", None)
palette_bytes = _get_palette_bytes(im, palette, im.encoderinfo)
palette_bytes = _get_palette_bytes(im)
color_table_size = _get_color_table_size(palette_bytes)
if color_table_size:
flags = flags | 128 # local color table flag
@ -624,7 +624,7 @@ def _normalize_palette(im, palette, info):
im.palette.palette = source_palette
return im
def _get_palette_bytes(im, *args):
def _get_palette_bytes(im):
"""
Gets the palette for inclusion in the gif header
@ -651,7 +651,7 @@ def _get_global_header(im, palette, info):
if im.info.get("version") == b"89a":
version = b"89a"
palette_bytes = _get_palette_bytes(im, palette, info)
palette_bytes = _get_palette_bytes(im)
color_table_size = _get_color_table_size(palette_bytes)
background = info["background"] if "background" in info else 0