|
|
|
@ -60,10 +60,9 @@ puts(""); |
|
|
|
|
return 0; |
|
|
|
|
} |
|
|
|
|
/* -------------------------------------------------------------- */ |
|
|
|
|
#define BLANK 50 |
|
|
|
|
|
|
|
|
|
int demarre_la_machine(char *pattern, char *outdir, int szfifo, |
|
|
|
|
int infx, int outfx, int step) |
|
|
|
|
int infx, int outfx, int step, int blk) |
|
|
|
|
{ |
|
|
|
|
int foo, idx, width, height; |
|
|
|
|
glob_t globbuf; |
|
|
|
@ -118,7 +117,7 @@ foo = create_fifo(szfifo, width, height, FIMG_TYPE_RGB); |
|
|
|
|
fprintf(stderr, "init fifo (%d slots) --> %d\n", szfifo, foo); |
|
|
|
|
|
|
|
|
|
/* XXX inject a few strange pics in the fifo */ |
|
|
|
|
insert_blank(&input, BLANK, outfx, maxvalue, outdir); |
|
|
|
|
insert_blank(&input, blk, outfx, maxvalue, outdir); |
|
|
|
|
|
|
|
|
|
for (idx=0; idx<globbuf.gl_pathc; idx++) { |
|
|
|
|
cptr = globbuf.gl_pathv[idx]; |
|
|
|
@ -145,7 +144,7 @@ for (idx=0; idx<globbuf.gl_pathc; idx++) { |
|
|
|
|
} |
|
|
|
|
fputs("\n", stderr); |
|
|
|
|
|
|
|
|
|
insert_blank(&input, BLANK*2, outfx, maxvalue, outdir); |
|
|
|
|
insert_blank(&input, blk, outfx, maxvalue, outdir); |
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
|
* PLEASE, FLUSH THE FIFO ! |
|
|
|
@ -186,14 +185,16 @@ char *out_dir = "p8"; |
|
|
|
|
int in_effect = 0; |
|
|
|
|
int out_effect = 0; |
|
|
|
|
int steps = 1; |
|
|
|
|
int blanks = 20; |
|
|
|
|
|
|
|
|
|
fprintf(stderr, "*** %s :\n\tcompiled by tTh, %s %s\n\tpid %d\n", |
|
|
|
|
argv[0], __DATE__, __TIME__, getpid()); |
|
|
|
|
fimg_print_version(2); |
|
|
|
|
|
|
|
|
|
while ((opt = getopt(argc, argv, "ghI:O:s:T:vw:x:")) != -1) { |
|
|
|
|
while ((opt = getopt(argc, argv, "B:ghI:O:s:T:vw:x:")) != -1) { |
|
|
|
|
switch(opt) { |
|
|
|
|
|
|
|
|
|
case 'B': blanks = atoi(optarg); |
|
|
|
|
break; |
|
|
|
|
case 'g': convert_to_gray = 1; |
|
|
|
|
break; |
|
|
|
|
case 'h': help();
|
|
|
|
@ -221,7 +222,7 @@ if (verbosity) { |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
foo = demarre_la_machine(in_pattern, out_dir, fifosize, in_effect, |
|
|
|
|
out_effect, steps); |
|
|
|
|
out_effect, steps, blanks); |
|
|
|
|
fprintf(stderr, "retour du big-run de la machine -> %d\n", foo); |
|
|
|
|
|
|
|
|
|
return 0; |
|
|
|
|