[svn] / trunk / xvidcore / src / bitstream / cbp.c Repository:
ViewVC logotype

Diff of /trunk/xvidcore/src/bitstream/cbp.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 46, Thu Mar 21 15:25:32 2002 UTC revision 195, Wed Jun 12 20:38:41 2002 UTC
# Line 7  Line 7 
7   * Returns a field of bits that indicates non zero ac blocks   * Returns a field of bits that indicates non zero ac blocks
8   * for this macro block   * for this macro block
9   */   */
10  uint32_t calc_cbp_c(const int16_t codes[6][64])  uint32_t
11    calc_cbp_c(const int16_t codes[6 * 64])
12  {  {
13          uint32_t i, j;          uint32_t i, j;
14          uint32_t cbp = 0;          uint32_t cbp = 0;
15    
16          for (i = 0; i < 6; i++) {          for (i = 0; i < 6; i++) {
17                  for (j = 1; j < 61; j+=4) {                  for (j = 1; j < 61; j+=4) {
18                          if (codes[i][j]  |codes[i][j+1]|                          if (codes[i * 64 + j] | codes[i * 64 + j + 1] |
19                              codes[i][j+2]|codes[i][j+3]) {                                  codes[i * 64 + j + 2] | codes[i * 64 + j + 3]) {
20                                  cbp |= 1 << (5 - i);                                  cbp |= 1 << (5 - i);
21                                  break;                                  break;
22                          }                          }
23                  }                  }
24    
25                  if(codes[i][j]|codes[i][j+1]|codes[i][j+2])                  if (codes[i * 64 + j] | codes[i * 64 + j + 1] | codes[i * 64 + j + 2])
26                          cbp |= 1 << (5 - i);                          cbp |= 1 << (5 - i);
27    
28          }          }

Legend:
Removed from v.46  
changed lines
  Added in v.195

No admin address has been configured
ViewVC Help
Powered by ViewVC 1.0.4