--- ray/src/px/clrtab.c 2003/05/13 17:58:33 2.14 +++ ray/src/px/clrtab.c 2003/06/30 14:59:12 2.15 @@ -1,13 +1,17 @@ #ifndef lint -static const char RCSid[] = "$Id: clrtab.c,v 2.14 2003/05/13 17:58:33 greg Exp $"; +static const char RCSid[] = "$Id: clrtab.c,v 2.15 2003/06/30 14:59:12 schorsch Exp $"; #endif /* * Simple median-cut color quantization based on colortab.c */ -#include "standard.h" +#include "copyright.h" +#include + +#include "standard.h" #include "color.h" + /* histogram resolution */ #define NRED 36 #define NGRN 48 @@ -45,7 +49,7 @@ static unsigned dist(); new_histo(n) /* clear our histogram */ int n; { - bzero((void *)histo, sizeof(histo)); + memset((void *)histo, '\0', sizeof(histo)); return(0); } @@ -130,7 +134,7 @@ int n; return; } N = n; - bzero((void *)cerr, 3*N*sizeof(short)); + memset((void *)cerr, '\0', 3*N*sizeof(short)); } err[0] = err[1] = err[2] = 0; for (x = 0; x < n; x++) { @@ -169,7 +173,7 @@ int c0, c1; } /* split box */ branch = split(box); - bcopy((void *)box, (void *)kb, sizeof(kb)); + memcpy((void *)kb, (void *)box, sizeof(kb)); /* do left (lesser) branch */ kb[prim(branch)][1] = part(branch); cut(kb, c0, (c0+c1)>>1);