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



commit 01e0675f67c2efd67afdb10bc9a21c934e388582
Author: Jehan <jehan girinstud io>
Date:   Sat Jun 11 00:01:06 2022 +0200

    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.

 plug-ins/common/file-raw-data.c | 24 +-----------------------
 1 file changed, 1 insertion(+), 23 deletions(-)
---
diff --git a/plug-ins/common/file-raw-data.c b/plug-ins/common/file-raw-data.c
index 9f60daced0..dddc9991ee 100644
--- a/plug-ins/common/file-raw-data.c
+++ b/plug-ins/common/file-raw-data.c
@@ -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);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]