annotate integer.h @ 2431:d67740c88f86 libavcodec

1l, forgot to remove duplicated error message
author rtognimp
date Sat, 15 Jan 2005 14:05:37 +0000
parents 7523553ca85f
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
2001
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
1 /*
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
2 * arbitrary precision integers
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
3 * Copyright (c) 2004 Michael Niedermayer <michaelni@gmx.at>
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
4 *
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
5 * This library is free software; you can redistribute it and/or
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
6 * modify it under the terms of the GNU Lesser General Public
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
7 * License as published by the Free Software Foundation; either
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
8 * version 2 of the License, or (at your option) any later version.
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
9 *
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
10 * This library is distributed in the hope that it will be useful,
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
13 * Lesser General Public License for more details.
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
14 *
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
15 * You should have received a copy of the GNU Lesser General Public
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
16 * License along with this library; if not, write to the Free Software
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
17 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
18 *
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
19 */
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
20
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
21 /**
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
22 * @file integer.h
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
23 * arbitrary precision integers
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
24 * @author Michael Niedermayer <michaelni@gmx.at>
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
25 */
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
26
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
27 #ifndef INTEGER_H
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
28 #define INTEGER_H
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
29
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
30 #define AV_INTEGER_SIZE 8
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
31
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
32 typedef struct AVInteger{
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
33 uint16_t v[AV_INTEGER_SIZE];
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
34 } AVInteger;
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
35
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
36 AVInteger av_add_i(AVInteger a, AVInteger b);
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
37 AVInteger av_sub_i(AVInteger a, AVInteger b);
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
38 int av_log2_i(AVInteger a);
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
39 AVInteger av_mul_i(AVInteger a, AVInteger b);
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
40 int av_cmp_i(AVInteger a, AVInteger b);
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
41 AVInteger av_shr_i(AVInteger a, int s);
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
42 AVInteger av_mod_i(AVInteger *quot, AVInteger a, AVInteger b);
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
43 AVInteger av_div_i(AVInteger a, AVInteger b);
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
44 AVInteger av_int2i(int64_t a);
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
45 int64_t av_i2int(AVInteger a);
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
46
7523553ca85f arbitrary precision integer support
michael
parents:
diff changeset
47 #endif // INTEGER_H