From 155ed74e2b2af0913a9cf0d889f6d60fe480447f Mon Sep 17 00:00:00 2001 From: tth Date: Fri, 1 Jul 2022 02:36:54 +0200 Subject: [PATCH] tuning on applymap tool --- Lib/combine5.c | 4 ++-- Lib/mustopen.c | 8 ++++++++ Tools/README.md | 4 +++- Tools/tga_applymap.c | 4 +++- 4 files changed, 16 insertions(+), 4 deletions(-) diff --git a/Lib/combine5.c b/Lib/combine5.c index 1119356..a26356e 100644 --- a/Lib/combine5.c +++ b/Lib/combine5.c @@ -120,7 +120,7 @@ int Image_combine_Vsplit(Image_Desc *s1, Image_Desc *s2, Image_Desc *d, int foo, x, y; #if DEBUG_LEVEL -fprintf(stderr, "%s (%p %p %p %d %d)\n", __func__, s1, s2, d, xv, uh); +fprintf(stderr, "%s ( %p %p %p %d %d )\n", __func__, s1, s2, d, xv, uh); #endif if (0 != uh) @@ -152,7 +152,7 @@ for (y=0; yheight; y++) } } -return FUNC_IS_BETA; +return OLL_KORRECT; } /*::------------------------------------------------------------------::*/ /* nouveau 29 novembre 2013 diff --git a/Lib/mustopen.c b/Lib/mustopen.c index db69516..5b006c4 100644 --- a/Lib/mustopen.c +++ b/Lib/mustopen.c @@ -29,6 +29,10 @@ int fd; char *path, *tmp; int l1, l2; +#if DEBUG_LEVEL +fprintf(stderr, ">>> %s ( '%s' '%s' %d )\n", __func__, filename, mode, type); +#endif + if (type != 0) { fprintf(stderr, "Image must Open: type (%d) must be 0\n", type); @@ -112,6 +116,10 @@ FILE *fp; char *path, *tmp; int l1, l2; +#if DEBUG_LEVEL +fprintf(stderr, ">>> %s ( '%s' '%s' %d )\n", __func__, filename, mode, type); +#endif + /* filter for the reserved parameter */ if (type != 0) { diff --git a/Tools/README.md b/Tools/README.md index 07efbbe..987dbef 100644 --- a/Tools/README.md +++ b/Tools/README.md @@ -19,7 +19,7 @@ Usage: prewitt | i | rotation [0..8] random | ii | try it... ``` -La colonne du milieu undique le type des paramètres : +La colonne du milieu indique le type des paramètres : - `i` pour un nombre entier - `d` pour un flottant en double précision @@ -33,6 +33,8 @@ est globalement mal géré par l'ensemble de libtthimage. ## tga_applymap +La gestion de la ligne de commande est désastreuse. **À REFAIRE** + ## tga_cadre Pas mal de façons de mettre un cadre sur l'image. diff --git a/Tools/tga_applymap.c b/Tools/tga_applymap.c index a51183d..4de3f83 100644 --- a/Tools/tga_applymap.c +++ b/Tools/tga_applymap.c @@ -13,7 +13,9 @@ void usage(int flag) { fprintf(stderr, "* tga_applymap v 0.0.14 [%s] (dwtfywl) Krabulator 1910\n", TGA_OUTILS_VERSION); -fprintf(stderr, "Usage: tga_applymap M src.tga color.map dst.tga\n"); +fprintf(stderr, " compiled %s at %s\n", __DATE__, __TIME__); + +fprintf(stderr, "Usage:\n\ttga_applymap M src.tga color.map dst.tga\n"); fprintf(stderr, " M is 1 or 2\n"); Image_print_version(0); exit(5);