[gimp] plug-ins: mask the 3 "Converts *" procedure from file-dds plug-in.



commit ccc8224aa9a500c0ac187043a4d897707f30a2b5
Author: Jehan <jehan girinstud io>
Date:   Mon Sep 16 10:34:28 2019 +0200

    plug-ins: mask the 3 "Converts *" procedure from file-dds plug-in.
    
    They are semantically wrong anyway because they work on drawable,
    assuming that the drawable is encoded in whatever non-RGB pixel (while
    getting data in R'G'B'A format). This is just an internal trick of the
    file-dds plug-in which converts DDS data internally instead of having
    babl doing the job by making appropriate formats.
    
    Anyway we should definitely not expose such procedure publicly. I am not
    deleting the code directly, just hiding it away in `#if 0` for now.

 plug-ins/file-dds/dds.c | 8 ++++++++
 1 file changed, 8 insertions(+)
---
diff --git a/plug-ins/file-dds/dds.c b/plug-ins/file-dds/dds.c
index dd9dab9a18..d22967384e 100644
--- a/plug-ins/file-dds/dds.c
+++ b/plug-ins/file-dds/dds.c
@@ -73,12 +73,14 @@ static GimpValueArray * dds_save             (GimpProcedure        *procedure,
                                               GFile                *file,
                                               const GimpValueArray *args,
                                               gpointer              run_data);
+#if 0
 static GimpValueArray * dds_decode           (GimpProcedure        *procedure,
                                               GimpRunMode           run_mode,
                                               GimpImage            *image,
                                               GimpDrawable         *drawable,
                                               const GimpValueArray *args,
                                               gpointer              run_data);
+#endif
 
 
 G_DEFINE_TYPE (Dds, dds, GIMP_TYPE_PLUG_IN)
@@ -133,9 +135,11 @@ dds_query_procedures (GimpPlugIn *plug_in)
 
   list = g_list_append (list, g_strdup (LOAD_PROC));
   list = g_list_append (list, g_strdup (SAVE_PROC));
+#if 0
   list = g_list_append (list, g_strdup (DECODE_YCOCG_PROC));
   list = g_list_append (list, g_strdup (DECODE_YCOCG_SCALED_PROC));
   list = g_list_append (list, g_strdup (DECODE_ALPHA_EXP_PROC));
+#endif
 
   return list;
 }
@@ -299,6 +303,7 @@ dds_create_procedure (GimpPlugIn  *plug_in,
                             0.0, 1.0, 0.5,
                             G_PARAM_READWRITE);
     }
+#if 0
   else if (! strcmp (name, DECODE_YCOCG_PROC))
     {
       procedure = gimp_image_procedure_new (plug_in, name,
@@ -363,6 +368,7 @@ dds_create_procedure (GimpPlugIn  *plug_in,
                                       "Shawn Kirst",
                                       "2008");
     }
+#endif
 
   return procedure;
 }
@@ -507,6 +513,7 @@ dds_save (GimpProcedure        *procedure,
   return gimp_procedure_new_return_values (procedure, status, error);
 }
 
+#if 0
 static GimpValueArray *
 dds_decode (GimpProcedure        *procedure,
             GimpRunMode           run_mode,
@@ -535,3 +542,4 @@ dds_decode (GimpProcedure        *procedure,
 
   return gimp_procedure_new_return_values (procedure, GIMP_PDB_SUCCESS, NULL);
 }
+#endif


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