chasse au bug

This commit is contained in:
tTh
2023-06-29 14:29:14 +02:00
parent ed227d6563
commit 2ff17fc54b
2 changed files with 20 additions and 1 deletions

View File

@@ -10,6 +10,11 @@
#include "../floatimg.h"
/* --------------------------------------------------------------------- */
/*
*********************************************
* SEGFAULT SI IMAGE TROP PETITE *
*********************************************
*/
int fimg_test_pattern(FloatImg *fimg, int type, double dval)
{
@@ -26,6 +31,8 @@ if (fimg->type != FIMG_TYPE_RGB) {
return -6;
}
fprintf(stderr, "ENTERING %s\n", __func__);
if (type) {
fprintf(stderr, "%s : %d %f\n", __func__, type, dval);
}
@@ -60,6 +67,7 @@ for (x=0; x<fimg->width; x++) {
// fprintf(stderr, " %6d %f\n", x, val);
}
k = (fimg->height / 4) + 90;
for (x=0; x<fimg->width; x++) {
val = ((x%8)<4) ? dval : 0.0;
@@ -78,6 +86,8 @@ for (x=0; x<fimg->width; x++) {
}
}
fprintf(stderr, "ALIVE %s\n", __func__);
return 0;
}
/* --------------------------------------------------------------------- */