Browse Source

a new tool: singlepass

master
tonton th 2 years ago
parent
commit
0d536187fd
  1. 5
      Fonderie/Makefile
  2. 73
      Fonderie/singlepass.c

5
Fonderie/Makefile

@ -21,7 +21,7 @@ t: t.c Makefile ${OBJS} @@ -21,7 +21,7 @@ t: t.c Makefile ${OBJS}
# ---------------------------------------------------------
#
# the two main programms
# the three main programms
#
fonderie: fonderie.c ${DEPS} ${OBJS} Makefile
@ -31,6 +31,9 @@ fonderie: fonderie.c ${DEPS} ${OBJS} Makefile @@ -31,6 +31,9 @@ fonderie: fonderie.c ${DEPS} ${OBJS} Makefile
interpolator: interpolator.c ${DEPS} ${OBJS} Makefile
gcc ${COPT} $< ${OBJS} ${LIBS} -lz -o $@
singlepass: singlepass.c ${DEPS} ${OBJS} Makefile
gcc ${COPT} $< ${OBJS} ${LIBS} -lz -o $@
# ---------------------------------------------------------
#
# some files are magically generated, sorry.

73
Fonderie/singlepass.c

@ -0,0 +1,73 @@ @@ -0,0 +1,73 @@
/*
* +-------------------------+
* | S I N G L E P A S S |
* +-------------------------+
*/
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include "../floatimg.h"
#include "single.h"
/* ----------------------------------------------------------- */
int verbosity;
/* ----------------------------------------------------------- */
/* ----------------------------------------------------------- */
static void help(void)
{
puts("--- Single pass serial filter ---\nusage:");
puts("\t-F\tdefine:the:filter:chain");
puts("\t-g\tinput glob pattern");
puts("\t-L\tlist available filters");
puts("\t-O\t/output/directory");
// puts("\t-s\tdo single test");
puts("\t-v\tspit more messages");
exit(0);
}
/* ----------------------------------------------------------- */
int main(int argc, char *argv[])
{
int foo, opt;
char *filterchain = "none";
char *globbing = "./capture/?????.fimg";
char *outdir = "./png/";
int do_xper = 0;
fprintf(stderr, "*** %s : compiled %s %s\n", __FILE__,
__DATE__, __TIME__);
fimg_print_version(2);
while ((opt = getopt(argc, argv, "hF:g:LO:svx")) != -1) {
switch (opt) {
case 'h': help(); break;
case 'F': filterchain = optarg; break;
case 'g': globbing = optarg; break;
case 'L':
list_crapulors("available filters");
exit(0);
case 'O': outdir = optarg; break;
case 'v': verbosity++; break;
case 'x': do_xper = 1; break;
}
}
return 0;
}
/* ----------------------------------------------------------- */
Loading…
Cancel
Save