mirror of https://github.com/GNOME/gimp.git
app: XCF endian swapping was still not correct
The number of pixels is "tile_size / bpp", not "tile_size / n_components".
This commit is contained in:
parent
bda06dd450
commit
2e0035c9df
|
@ -2204,7 +2204,7 @@ xcf_load_tile_rle (XcfInfo *info,
|
|||
gint n_components = babl_format_get_n_components (format);
|
||||
|
||||
xcf_read_from_be (bpp / n_components, tile_data,
|
||||
tile_size / n_components);
|
||||
tile_size / bpp);
|
||||
}
|
||||
|
||||
gegl_buffer_set (buffer, tile_rect, 0, format, tile_data,
|
||||
|
@ -2302,7 +2302,7 @@ xcf_load_tile_zlib (XcfInfo *info,
|
|||
gint n_components = babl_format_get_n_components (format);
|
||||
|
||||
xcf_read_from_be (bpp / n_components, tile_data,
|
||||
tile_size / n_components);
|
||||
tile_size / bpp);
|
||||
}
|
||||
|
||||
gegl_buffer_set (buffer, tile_rect, 0, format, tile_data,
|
||||
|
|
|
@ -1675,7 +1675,7 @@ xcf_save_tile_rle (XcfInfo *info,
|
|||
gint n_components = babl_format_get_n_components (format);
|
||||
|
||||
xcf_write_to_be (bpp / n_components, tile_data,
|
||||
tile_size / n_components);
|
||||
tile_size / bpp);
|
||||
}
|
||||
|
||||
for (i = 0; i < bpp; i++)
|
||||
|
@ -1811,7 +1811,7 @@ xcf_save_tile_zlib (XcfInfo *info,
|
|||
gint n_components = babl_format_get_n_components (format);
|
||||
|
||||
xcf_write_to_be (bpp / n_components, tile_data,
|
||||
tile_size / n_components);
|
||||
tile_size / bpp);
|
||||
}
|
||||
|
||||
/* allocate deflate state */
|
||||
|
|
Loading…
Reference in New Issue