Browse code

spelling/grammar/consistency review part III

Originally committed as revision 16849 to svn://svn.ffmpeg.org/ffmpeg/trunk

Diego Biurrun authored on 2009/01/29 08:16:49
Showing 9 changed files
... ...
@@ -29,7 +29,7 @@
29 29
  *
30 30
  * @param str input string
31 31
  * @param pfx prefix to test
32
- * @param ptr updated after the prefix in str in there is a match
32
+ * @param ptr updated if the prefix is matched inside str
33 33
  * @return non-zero if the prefix matches, zero otherwise
34 34
  */
35 35
 int av_strstart(const char *str, const char *pfx, const char **ptr);
... ...
@@ -41,7 +41,7 @@ int av_strstart(const char *str, const char *pfx, const char **ptr);
41 41
  *
42 42
  * @param str input string
43 43
  * @param pfx prefix to test
44
- * @param ptr updated after the prefix in str in there is a match
44
+ * @param ptr updated if the prefix is matched inside str
45 45
  * @return non-zero if the prefix matches, zero otherwise
46 46
  */
47 47
 int av_stristart(const char *str, const char *pfx, const char **ptr);
... ...
@@ -40,12 +40,13 @@ static AVCRC av_crc_table[AV_CRC_MAX][257];
40 40
 #endif
41 41
 
42 42
 /**
43
- * Inits a crc table.
44
- * @param ctx must be an array of sizeof(AVCRC)*257 or sizeof(AVCRC)*1024
43
+ * Initializes a CRC table.
44
+ * @param ctx must be an array of size sizeof(AVCRC)*257 or sizeof(AVCRC)*1024
45 45
  * @param cts_size size of ctx in bytes
46
- * @param le if 1, lowest bit represents coefficient for highest exponent
47
- *           of corresponding polynomial (both for poly and actual CRC).
48
- *           If 0, you must swap the crc parameter and the result of av_crc
46
+ * @param le If 1, the lowest bit represents the coefficient for the highest
47
+ *           exponent of the corresponding polynomial (both for poly and
48
+ *           actual CRC).
49
+ *           If 0, you must swap the CRC parameter and the result of av_crc
49 50
  *           if you need the standard representation (can be simplified in
50 51
  *           most cases to e.g. bswap16):
51 52
  *           bswap_32(crc << (32-bits))
... ...
@@ -26,13 +26,13 @@
26 26
 #include "common.h"
27 27
 
28 28
 /**
29
- * \brief en- or decrypt an 64-bit block of data with DES
30
- * \param in data to process.
31
- * \param key key to use for en-/decryption.
32
- * \param decrypt if 0 encrypt, else decrypt.
29
+ * \brief Encrypt/decrypt a 64-bit block of data with DES.
30
+ * \param in data to process
31
+ * \param key key to use for encryption/decryption
32
+ * \param decrypt if 0 encrypt, else decrypt
33 33
  * \return processed data
34 34
  *
35
- * If your input data is in 8-bit blocks treat it as big-endian
35
+ * If your input data is in 8-bit blocks, treat it as big-endian
36 36
  * (use e.g. AV_RB64 and AV_WB64).
37 37
  */
38 38
 uint64_t ff_des_encdec(uint64_t in, uint64_t key, int decrypt) av_const;
... ...
@@ -41,8 +41,9 @@ AVInteger av_add_i(AVInteger a, AVInteger b) av_const;
41 41
 AVInteger av_sub_i(AVInteger a, AVInteger b) av_const;
42 42
 
43 43
 /**
44
- * returns the rounded down value of the logarithm of base 2 of the given AVInteger.
45
- * this is simply the index of the most significant bit which is 1. Or 0 of all bits are 0
44
+ * Returns the rounded-down value of the base 2 logarithm of the given
45
+ * AVInteger. This is simply the index of the most significant bit
46
+ * which is 1, or 0 if all bits are 0.
46 47
  */
47 48
 int av_log2_i(AVInteger a) av_const;
48 49
 AVInteger av_mul_i(AVInteger a, AVInteger b) av_const;
... ...
@@ -218,7 +218,7 @@ if((y)<(x)){\
218 218
 }
219 219
 #endif
220 220
 
221
-/* avoid usage of various functions */
221
+/* avoid usage of dangerous/inappropriate system functions */
222 222
 #undef  malloc
223 223
 #define malloc please_use_av_malloc
224 224
 #undef  free
... ...
@@ -21,7 +21,7 @@
21 21
 
22 22
 /**
23 23
  * @file log.c
24
- * log.
24
+ * logging functions
25 25
  */
26 26
 
27 27
 #include "avutil.h"
... ...
@@ -70,21 +70,21 @@ struct AVCLASS {
70 70
 #define AV_LOG_PANIC     0
71 71
 
72 72
 /**
73
- * something went wrong and recovery is not possible
74
- * like no header in a format which depends on it or a combination
75
- * of parameters which are not allowed
73
+ * Something went wrong and recovery is not possible.
74
+ * For example, no header was found for a format which depends
75
+ * on headers or an illegal combination of parameters is used.
76 76
  */
77 77
 #define AV_LOG_FATAL     8
78 78
 
79 79
 /**
80
- * something went wrong and cannot losslessly be recovered
81
- * but not all future data is affected
80
+ * Something went wrong and cannot losslessly be recovered.
81
+ * However, not all future data is affected.
82 82
  */
83 83
 #define AV_LOG_ERROR    16
84 84
 
85 85
 /**
86
- * something somehow does not look correct / something which may or may not
87
- * lead to some problems like use of -vstrict -2
86
+ * Something somehow does not look correct. This may or may not
87
+ * lead to problems. An example would be the use of '-vstrict -2'.
88 88
  */
89 89
 #define AV_LOG_WARNING  24
90 90
 
... ...
@@ -1,5 +1,5 @@
1 1
 /*
2
- * Mersenne Twister Random Algorithm
2
+ * Mersenne Twister PRNG algorithm
3 3
  * Copyright (c) 2006 Ryan Martell
4 4
  * Based on a C program for MT19937, with initialization improved 2002/1/26.
5 5
  * Coded by Takuji Nishimura and Makoto Matsumoto.
... ...
@@ -1,5 +1,5 @@
1 1
 /*
2
- * Mersenne Twister Random Algorithm
2
+ * Mersenne Twister PRNG algorithm
3 3
  * Copyright (c) 2006 Ryan Martell
4 4
  * Based on a C program for MT19937, with initialization improved 2002/1/26.
5 5
  * Coded by Takuji Nishimura and Makoto Matsumoto.
... ...
@@ -44,8 +44,8 @@ void av_random_generate_untempered_numbers(AVRandomState *state); ///< Regenerat
44 44
 /**
45 45
  * Generates a random number from the interval [0,0xffffffff].
46 46
  *
47
- * Please do NOT use the Mersenne Twister, it is slow. Use the random generator
48
- * from lfg.c/h or a simple LCG like state= state*1664525+1013904223.
47
+ * Please do NOT use the Mersenne Twister, it is slow. Use the random number
48
+ * generator from lfg.c/h or a simple LCG like state = state*1664525+1013904223.
49 49
  * If you still choose to use MT, expect that you will have to provide
50 50
  * some evidence that it makes a difference for the case where you use it.
51 51
  */
... ...
@@ -69,7 +69,7 @@ static inline unsigned int av_random(AVRandomState *state)
69 69
     return y;
70 70
 }
71 71
 
72
-/** Return random in range [0-1] as double. */
72
+/** Returns a random number in the range [0-1] as double. */
73 73
 static inline double av_random_real1(AVRandomState *state)
74 74
 {
75 75
     /* divided by 2^32-1 */