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

Comparing ray/src/util/ranimove1.c (file contents):
Revision 3.1 by greg, Sat Feb 22 02:07:30 2003 UTC vs.
Revision 3.4 by schorsch, Mon Jun 30 14:59:13 2003 UTC

# Line 9 | Line 9 | static const char      RCSid[] = "$Id$";
9   *  Created by Gregory Ward on Wed Jan 08 2003.
10   */
11  
12 < /* ====================================================================
13 < * The Radiance Software License, Version 1.0
14 < *
15 < * Copyright (c) 1990 - 2002 The Regents of the University of California,
16 < * through Lawrence Berkeley National Laboratory.   All rights reserved.
17 < *
18 < * Redistribution and use in source and binary forms, with or without
19 < * modification, are permitted provided that the following conditions
20 < * are met:
21 < *
22 < * 1. Redistributions of source code must retain the above copyright
23 < *         notice, this list of conditions and the following disclaimer.
24 < *
25 < * 2. Redistributions in binary form must reproduce the above copyright
26 < *       notice, this list of conditions and the following disclaimer in
27 < *       the documentation and/or other materials provided with the
28 < *       distribution.
29 < *
30 < * 3. The end-user documentation included with the redistribution,
31 < *           if any, must include the following acknowledgment:
32 < *             "This product includes Radiance software
33 < *                 (http://radsite.lbl.gov/)
34 < *                 developed by the Lawrence Berkeley National Laboratory
35 < *               (http://www.lbl.gov/)."
36 < *       Alternately, this acknowledgment may appear in the software itself,
37 < *       if and wherever such third-party acknowledgments normally appear.
38 < *
39 < * 4. The names "Radiance," "Lawrence Berkeley National Laboratory"
40 < *       and "The Regents of the University of California" must
41 < *       not be used to endorse or promote products derived from this
42 < *       software without prior written permission. For written
43 < *       permission, please contact [email protected].
44 < *
45 < * 5. Products derived from this software may not be called "Radiance",
46 < *       nor may "Radiance" appear in their name, without prior written
47 < *       permission of Lawrence Berkeley National Laboratory.
48 < *
49 < * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
50 < * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
51 < * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
52 < * DISCLAIMED.   IN NO EVENT SHALL Lawrence Berkeley National Laboratory OR
53 < * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
54 < * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
55 < * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
56 < * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
57 < * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
58 < * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
59 < * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
60 < * SUCH DAMAGE.
61 < * ====================================================================
62 < *
63 < * This software consists of voluntary contributions made by many
64 < * individuals on behalf of Lawrence Berkeley National Laboratory.   For more
65 < * information on Lawrence Berkeley National Laboratory, please see
66 < * <http://www.lbl.gov/>.
67 < */
12 > #include "copyright.h"
13  
14 + #include <string.h>
15 +
16 + #include "platform.h"
17   #include "ranimove.h"
18   #include "otypes.h"
19   #include "random.h"
# Line 193 | Line 141 | next_frame()                   /* prepare next frame buffer */
141                  fp = zprev; zprev = zbuffer; zbuffer = fp;
142                  op = oprev; oprev = obuffer; obuffer = op;
143                  bp = aprev; aprev = abuffer; abuffer = bp;
144 <                bzero(abuffer, sizeof(BYTE)*hres*vres);
145 <                bzero(sbuffer, sizeof(BYTE)*hres*vres);
144 >                memset(abuffer, '\0', sizeof(BYTE)*hres*vres);
145 >                memset(sbuffer, '\0', sizeof(BYTE)*hres*vres);
146                  frm_stop += rtperfrm;
147          }
148          cerrmap = NULL;
# Line 811 | Line 759 | write_map(cerrmap, "outcmap.pic");
759                  int     n2;
760                  int     cnt;
761                                          /* sum in motion streaks */
762 <                bzero(outbuffer, sizeof(COLOR)*hres*vres);
763 <                bzero(wbuffer, sizeof(float)*hres*vres);
762 >                memset(outbuffer, '\0', sizeof(COLOR)*hres*vres);
763 >                memset(wbuffer, '\0', sizeof(float)*hres*vres);
764                  for (y = vres; y--; )
765                      for (x = hres; x--; ) {
766                          n = fndx(x, y);
# Line 928 | Line 876 | send_frame()                   /* send frame to destination */
876                  sprintf(errmsg, "cannot open output frame \"%s\"", pfname);
877                  error(SYSTEM, errmsg);
878          }
879 < #ifdef MSDOS
932 <        setmode(fileno(fp), O_BINARY);
933 < #endif
879 >        SET_FILE_BINARY(fp);
880          if (!silent) {
881                  printf("\tWriting to \"%s\"\n", pfname);
882                  fflush(stdout);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines