diff options
author | Diego Biurrun <diego@biurrun.de> | 2009-03-31 09:32:59 +0000 |
---|---|---|
committer | Diego Biurrun <diego@biurrun.de> | 2009-03-31 09:32:59 +0000 |
commit | 504ffed19f990f91237479be93480d9b597561e2 (patch) | |
tree | 0112de10541e64bca39496011f62f0284ee87470 /libavcodec | |
parent | cafe71c62d87955172dd6d8fcb277988f00e92e2 (diff) | |
download | ffmpeg-504ffed19f990f91237479be93480d9b597561e2.tar.gz |
Mark non-exported functions in test and example programs as static.
Originally committed as revision 18259 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/api-example.c | 11 | ||||
-rw-r--r-- | libavcodec/dct-test.c | 12 | ||||
-rw-r--r-- | libavcodec/fft-test.c | 16 | ||||
-rw-r--r-- | libavcodec/motion-test.c | 8 |
4 files changed, 24 insertions, 23 deletions
diff --git a/libavcodec/api-example.c b/libavcodec/api-example.c index 7f682cde30..2a47fea7f8 100644 --- a/libavcodec/api-example.c +++ b/libavcodec/api-example.c @@ -43,7 +43,7 @@ /* * Audio encoding example */ -void audio_encode_example(const char *filename) +static void audio_encode_example(const char *filename) { AVCodec *codec; AVCodecContext *c= NULL; @@ -111,7 +111,7 @@ void audio_encode_example(const char *filename) /* * Audio decoding. */ -void audio_decode_example(const char *outfilename, const char *filename) +static void audio_decode_example(const char *outfilename, const char *filename) { AVCodec *codec; AVCodecContext *c= NULL; @@ -186,7 +186,7 @@ void audio_decode_example(const char *outfilename, const char *filename) /* * Video encoding example */ -void video_encode_example(const char *filename) +static void video_encode_example(const char *filename) { AVCodec *codec; AVCodecContext *c= NULL; @@ -297,7 +297,8 @@ void video_encode_example(const char *filename) * Video decoding example */ -void pgm_save(unsigned char *buf,int wrap, int xsize,int ysize,char *filename) +static void pgm_save(unsigned char *buf, int wrap, int xsize, int ysize, + char *filename) { FILE *f; int i; @@ -309,7 +310,7 @@ void pgm_save(unsigned char *buf,int wrap, int xsize,int ysize,char *filename) fclose(f); } -void video_decode_example(const char *outfilename, const char *filename) +static void video_decode_example(const char *outfilename, const char *filename) { AVCodec *codec; AVCodecContext *c= NULL; diff --git a/libavcodec/dct-test.c b/libavcodec/dct-test.c index f3daf17aec..b9c0ff42ec 100644 --- a/libavcodec/dct-test.c +++ b/libavcodec/dct-test.c @@ -150,7 +150,7 @@ struct algo algos[] = { uint8_t cropTbl[256 + 2 * MAX_NEG_CROP]; -int64_t gettime(void) +static int64_t gettime(void) { struct timeval tv; gettimeofday(&tv,NULL); @@ -175,7 +175,7 @@ static short idct_simple_mmx_perm[64]={ static const uint8_t idct_sse2_row_perm[8] = {0, 4, 1, 5, 2, 6, 3, 7}; -void idct_mmx_init(void) +static void idct_mmx_init(void) { int i; @@ -198,7 +198,7 @@ static inline void mmx_emms(void) #endif } -void dct_error(const char *name, int is_idct, +static void dct_error(const char *name, int is_idct, void (*fdct_func)(DCTELEM *block), void (*fdct_ref)(DCTELEM *block), int form, int test) { @@ -387,7 +387,7 @@ void dct_error(const char *name, int is_idct, static uint8_t img_dest[64] __attribute__ ((aligned (8))); static uint8_t img_dest1[64] __attribute__ ((aligned (8))); -void idct248_ref(uint8_t *dest, int linesize, int16_t *block) +static void idct248_ref(uint8_t *dest, int linesize, int16_t *block) { static int init; static double c8[8][8]; @@ -467,7 +467,7 @@ void idct248_ref(uint8_t *dest, int linesize, int16_t *block) } } -void idct248_error(const char *name, +static void idct248_error(const char *name, void (*idct248_put)(uint8_t *dest, int line_size, int16_t *block)) { int it, i, it1, ti, ti1, err_max, v; @@ -545,7 +545,7 @@ void idct248_error(const char *name, name, (double)it1 * 1000.0 / (double)ti1); } -void help(void) +static void help(void) { printf("dct-test [-i] [<test-number>]\n" "test-number 0 -> test with random matrixes\n" diff --git a/libavcodec/fft-test.c b/libavcodec/fft-test.c index 4f1ce982de..0a2b93895d 100644 --- a/libavcodec/fft-test.c +++ b/libavcodec/fft-test.c @@ -45,7 +45,7 @@ FFTComplex *exptab; -void fft_ref_init(int nbits, int inverse) +static void fft_ref_init(int nbits, int inverse) { int n, i; double c1, s1, alpha; @@ -64,7 +64,7 @@ void fft_ref_init(int nbits, int inverse) } } -void fft_ref(FFTComplex *tabr, FFTComplex *tab, int nbits) +static void fft_ref(FFTComplex *tabr, FFTComplex *tab, int nbits) { int n, i, j, k, n2; double tmp_re, tmp_im, s, c; @@ -93,7 +93,7 @@ void fft_ref(FFTComplex *tabr, FFTComplex *tab, int nbits) } } -void imdct_ref(float *out, float *in, int nbits) +static void imdct_ref(float *out, float *in, int nbits) { int n = 1<<nbits; int k, i, a; @@ -111,7 +111,7 @@ void imdct_ref(float *out, float *in, int nbits) } /* NOTE: no normalisation by 1 / N is done */ -void mdct_ref(float *output, float *input, int nbits) +static void mdct_ref(float *output, float *input, int nbits) { int n = 1<<nbits; int k, i; @@ -129,21 +129,21 @@ void mdct_ref(float *output, float *input, int nbits) } -float frandom(void) +static float frandom(void) { AVLFG prn; av_lfg_init(&prn, 1); return (float)((av_lfg_get(&prn) & 0xffff) - 32768) / 32768.0; } -int64_t gettime(void) +static int64_t gettime(void) { struct timeval tv; gettimeofday(&tv,NULL); return (int64_t)tv.tv_sec * 1000000 + tv.tv_usec; } -void check_diff(float *tab1, float *tab2, int n) +static void check_diff(float *tab1, float *tab2, int n) { int i; double max= 0; @@ -162,7 +162,7 @@ void check_diff(float *tab1, float *tab2, int n) } -void help(void) +static void help(void) { av_log(NULL, AV_LOG_INFO,"usage: fft-test [-h] [-s] [-i] [-n b]\n" "-h print this help\n" diff --git a/libavcodec/motion-test.c b/libavcodec/motion-test.c index 90f0a2e1bc..fb21ee974b 100644 --- a/libavcodec/motion-test.c +++ b/libavcodec/motion-test.c @@ -41,7 +41,7 @@ uint8_t img1[WIDTH * HEIGHT]; uint8_t img2[WIDTH * HEIGHT]; -void fill_random(uint8_t *tab, int size) +static void fill_random(uint8_t *tab, int size) { int i; AVLFG prn; @@ -56,14 +56,14 @@ void fill_random(uint8_t *tab, int size) } } -void help(void) +static void help(void) { printf("motion-test [-h]\n" "test motion implementations\n"); exit(1); } -int64_t gettime(void) +static int64_t gettime(void) { struct timeval tv; gettimeofday(&tv,NULL); @@ -74,7 +74,7 @@ int64_t gettime(void) int dummy; -void test_motion(const char *name, +static void test_motion(const char *name, me_cmp_func test_func, me_cmp_func ref_func) { int x, y, d1, d2, it; |