adding HSV functions, with native bugs

This commit is contained in:
2020-09-08 22:55:17 +02:00
parent 3cf887e103
commit 44165c0a03
3 changed files with 109 additions and 4 deletions

View File

@@ -402,8 +402,10 @@ return 0;
}
/* --------------------------------------------------------------------- */
/* func in histogram.c */
int fimg_essai_histo(FloatImg *src, char *outpic, int k);
int fimg_essai_histo(FloatImg *src, char *outpic, int k); /* histogram.c */
int fimg_essai_hsv(char *fname); /* hsv.c */
int essai_histogramme(char *fname, int k)
{
@@ -432,7 +434,7 @@ return 0;
}
/* --------------------------------------------------------------------- */
enum nCmd { Equalize=1, Rotate, Sfx0, F3x3, MIRE, Wfits, Wpng, Wtiff,
Histo };
Histo, Hsv };
typedef struct {
char *name;
int Cmd;
@@ -448,6 +450,7 @@ Command commands[] = {
{ "wpng", Wpng },
{ "wtiff", Wtiff },
{ "histo", Histo },
{ "hsv", Hsv },
{ NULL, 0 }
} ;
@@ -541,6 +544,9 @@ switch(opt) {
case Histo:
foo = essai_histogramme(filename, 98765);
break;
case Hsv:
foo = fimg_essai_hsv(filename);
break;
default:
fprintf(stderr, "%s : bad command\n", command);
exit(1);