Leptonica 1.68
C Image Processing Library

viewertest.c

Go to the documentation of this file.
00001 /*====================================================================*
00002  -  Copyright (C) 2001 Leptonica.  All rights reserved.
00003  -  This software is distributed in the hope that it will be
00004  -  useful, but with NO WARRANTY OF ANY KIND.
00005  -  No author or distributor accepts responsibility to anyone for the
00006  -  consequences of using this software, or for whether it serves any
00007  -  particular purpose or works at all, unless he or she says so in
00008  -  writing.  Everyone is granted permission to copy, modify and
00009  -  redistribute this source code, for commercial or non-commercial
00010  -  purposes, with the following restrictions: (1) the origin of this
00011  -  source code must not be misrepresented; (2) modified versions must
00012  -  be plainly marked as such; and (3) this notice may not be removed
00013  -  or altered from any source or modified source distribution.
00014  *====================================================================*/
00015 
00016 /*
00017  * viewertest.c
00018  *
00019  *    Input:  dirin:  directory of input image files
00020  *            dirout: directory for output files
00021  *            rootname: root name for output files
00022  *            thumbwidth: width of thumb images, in pixels; use 0 for default
00023  *            viewwidth: max width of view images, in pixels; use 0 for default
00024  *
00025  *    Note: This program is Unix only; it will not link to pixHtmlViewer()
00026  *          under cygwin.
00027  */
00028 
00029 #include <stdio.h>
00030 #include <stdlib.h>
00031 #include "allheaders.h"
00032 
00033 main(int    argc,
00034      char **argv)
00035 {
00036 char        *dirin, *dirout, *rootname;
00037 l_int32      thumbwidth, viewwidth;
00038 static char  mainName[] = "viewertest";
00039 
00040     if (argc != 6)
00041         exit(ERROR_INT(
00042             " Syntax:  viewertest dirin dirout rootname thumbwidth viewwidth",
00043              mainName, 1));
00044 
00045     dirin = argv[1];
00046     dirout = argv[2];
00047     rootname = argv[3];
00048     thumbwidth = atoi(argv[4]);
00049     viewwidth = atoi(argv[5]);
00050 
00051     pixHtmlViewer(dirin, dirout, rootname, thumbwidth, viewwidth, 0);
00052     return 0;
00053 }
00054 
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines