Mercurial > libavcodec.hg
comparison h264_parser.c @ 8503:7c82ed8d4824 libavcodec
Explain the lack of +3/7
author | michael |
---|---|
date | Sun, 28 Dec 2008 23:26:12 +0000 |
parents | 60be1c7d8345 |
children | f8c091bb5779 |
comparison
equal
deleted
inserted
replaced
8502:e6909fa99317 | 8503:7c82ed8d4824 |
---|---|
43 state= 7; | 43 state= 7; |
44 | 44 |
45 for(i=0; i<buf_size; i++){ | 45 for(i=0; i<buf_size; i++){ |
46 if(state==7){ | 46 if(state==7){ |
47 #ifdef HAVE_FAST_UNALIGNED | 47 #ifdef HAVE_FAST_UNALIGNED |
48 /* we check i<buf_size instead of i+3/7 because its simpler | |
49 * and there should be FF_INPUT_BUFFER_PADDING_SIZE bytes at the end | |
50 */ | |
48 # ifdef HAVE_FAST_64BIT | 51 # ifdef HAVE_FAST_64BIT |
49 while(i<buf_size && !((~*(uint64_t*)(buf+i) & (*(uint64_t*)(buf+i) - 0x0101010101010101ULL)) & 0x8080808080808080ULL)) | 52 while(i<buf_size && !((~*(uint64_t*)(buf+i) & (*(uint64_t*)(buf+i) - 0x0101010101010101ULL)) & 0x8080808080808080ULL)) |
50 i+=8; | 53 i+=8; |
51 # else | 54 # else |
52 while(i<buf_size && !((~*(uint32_t*)(buf+i) & (*(uint32_t*)(buf+i) - 0x01010101U)) & 0x80808080U)) | 55 while(i<buf_size && !((~*(uint32_t*)(buf+i) & (*(uint32_t*)(buf+i) - 0x01010101U)) & 0x80808080U)) |