ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/src/px/protate.c
(Generate patch)

Comparing ray/src/px/protate.c (file contents):
Revision 1.1 by greg, Thu Feb 2 10:49:27 1989 UTC vs.
Revision 1.2 by greg, Tue Sep 12 13:04:27 1989 UTC

# Line 50 | Line 50 | char   *argv[];
50                                          /* add new header info. */
51          printf("%s\n\n", progname);
52                                          /* get picture size */
53 <        if (fgets(buf, sizeof(buf), fin) == NULL ||
54 <                        sscanf(buf, "-Y %d +X %d\n", &yres, &xres) != 2) {
53 >        if (fgetresolu(&xres, &yres, fin) != (YMAJOR|YDECR)) {
54                  fprintf(stderr, "%s: bad picture size\n", progname);
55                  exit(1);
56          }
57                                          /* write new picture size */
58 <        printf("-Y %d +X %d\n", xres, yres);
58 >        fputresolu(YMAJOR|YDECR, yres, xres, stdout);
59                                          /* compute buffer capacity */
60          nrows = sizeof(buf)/sizeof(COLR)/yres;
61          rotate(fin);                    /* rotate the image */

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines