| 10 |
|
#include <stdlib.h> |
| 11 |
|
#include <string.h> |
| 12 |
|
#include "rtio.h" |
| 13 |
+ |
#include "paths.h" |
| 14 |
|
#include "objutil.h" |
| 15 |
|
|
| 15 |
– |
const char *progname; |
| 16 |
|
int verbose = 0; |
| 17 |
|
|
| 18 |
|
int |
| 33 |
|
char cbuf[256]; |
| 34 |
|
double verteps = -1.; |
| 35 |
|
int i, n; |
| 36 |
< |
|
| 37 |
< |
progname = argv[0]; |
| 36 |
> |
/* set global progname */ |
| 37 |
> |
fixargv0(argv[0]); |
| 38 |
|
/* process options */ |
| 39 |
|
for (i = 1; i < argc && (argv[i][0] == '-' || argv[i][0] == '+'); i++) |
| 40 |
|
switch (argv[i][1]) { |
| 185 |
|
} |
| 186 |
|
if (verbose) |
| 187 |
|
fputs("Checking for duplicate faces...\n", stderr); |
| 188 |
< |
if (findDuplicateFaces(myScene)) |
| 188 |
> |
if (findDuplicateFaces(myScene)) { |
| 189 |
|
n = deleteFaces(myScene, FACE_DUPLICATE, 0); |
| 190 |
< |
if (n) { |
| 191 |
< |
sprintf(cbuf, "Removed %d duplicate faces", n); |
| 192 |
< |
addComment(myScene, cbuf); |
| 190 |
> |
if (n) { |
| 191 |
> |
sprintf(cbuf, "Removed %d duplicate faces", n); |
| 192 |
> |
addComment(myScene, cbuf); |
| 193 |
> |
} |
| 194 |
|
} |
| 195 |
|
if (do_triangulate) { |
| 196 |
|
if (verbose) |