Issue #7091: Exporting 16-bit precision images to raw *.data.

Just use the image format as-is. The only problem now is that we don't
support all formats for loading in file-raw yet.
This commit is contained in:
Jehan 2022-06-11 00:01:06 +02:00
parent 97d0337f92
commit 01e0675f67

View file

@ -1074,29 +1074,7 @@ save_image (GFile *file,
buffer = gimp_drawable_get_buffer (drawable);
switch (gimp_drawable_type (drawable))
{
case GIMP_RGB_IMAGE:
format = babl_format ("R'G'B' u8");
break;
case GIMP_RGBA_IMAGE:
format = babl_format ("R'G'B'A u8");
break;
case GIMP_GRAY_IMAGE:
format = babl_format ("Y' u8");
break;
case GIMP_GRAYA_IMAGE:
format = babl_format ("Y'A u8");
break;
case GIMP_INDEXED_IMAGE:
case GIMP_INDEXEDA_IMAGE:
format = gimp_drawable_get_format (drawable);
break;
}
format = gimp_drawable_get_format (drawable);
n_components = babl_format_get_n_components (format);
bpp = babl_format_get_bytes_per_pixel (format);