forked from tTh/FloatImg
experimenting...
This commit is contained in:
parent
6176744de8
commit
f109077b50
20
lib/t.c
20
lib/t.c
@ -88,12 +88,24 @@ verbosity = 1;
|
||||
|
||||
fimg_print_version(1);
|
||||
|
||||
foo = fimg_create_from_png("/home/tth/TMP/floatimg/s2.png", &dessin);
|
||||
foo = fimg_create_from_png("/home/tth/TMP/floatimg/s1.png", &noise);
|
||||
foo = fimg_create_from_png("/home/tth/TMP/floatimg/s1.png", &dessin);
|
||||
if (foo) {
|
||||
fprintf(stderr, "s1 load err %d\n", foo);
|
||||
exit(1);
|
||||
}
|
||||
fimg_describe(&dessin, "s1 dessin");
|
||||
fimg_to_gray(&dessin);
|
||||
|
||||
foo = fimg_create_from_png("/home/tth/TMP/floatimg/s2.png", &noise);
|
||||
if (foo) {
|
||||
fprintf(stderr, "s2 load err %d\n", foo);
|
||||
exit(1);
|
||||
}
|
||||
fimg_describe(&noise, "s2 noise");
|
||||
|
||||
foo = fimg_create(&result, W, H, 3);
|
||||
|
||||
#define NBRE 42
|
||||
#define NBRE 20
|
||||
|
||||
for (idx=0; idx<NBRE; idx++) {
|
||||
|
||||
@ -104,7 +116,7 @@ for (idx=0; idx<NBRE; idx++) {
|
||||
|
||||
foo = fimg_interpolate(&dessin, &noise, &result, coef);
|
||||
printf("%6d %9.6f\n", idx, coef);
|
||||
fimg_to_gray(&result);
|
||||
// fimg_to_gray(&result);
|
||||
sprintf(outname, "/home/tth/TMP/floatimg/%05d.pnm", idx);
|
||||
foo = fimg_save_as_pnm(&result, outname, 0);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user