mirror of
git://projects.qi-hardware.com/ben-scans.git
synced 2024-11-22 09:50:38 +02:00
ecf993e0f2
- solidify/Makefile, solidify/histo.h, solidify/histo.c: generate a Z histogram and find the median height - solidify/face.c (read_face): set z_ref to the median, not the average - solidify/face.c (read_face): uncompress .bz2 files on the fly - solidify/face.c (read_face): don't close standard input (for style)
18 lines
257 B
C
18 lines
257 B
C
#ifndef HISTO_H
|
|
#define HISTO_H
|
|
|
|
#include "array.h"
|
|
|
|
|
|
struct histo {
|
|
int n; /* number of bins */
|
|
int *b; /* bins */
|
|
};
|
|
|
|
|
|
struct histo *make_histo(struct array *a);
|
|
void free_histo(struct histo *h);
|
|
int median(const struct histo *h);
|
|
|
|
#endif /* HISTO_H */
|