Mercurial > libavcodec.hg
diff h264_refs.c @ 11349:33f8308382f5 libavcodec
Reorder indexes in weight tables.
5 cpu cycles faster.
author | michael |
---|---|
date | Wed, 03 Mar 2010 21:10:08 +0000 |
parents | a82cdda1f507 |
children | 44c5c540722c |
line wrap: on
line diff
--- a/h264_refs.c Wed Mar 03 20:36:56 2010 +0000 +++ b/h264_refs.c Wed Mar 03 21:10:08 2010 +0000 @@ -315,11 +315,11 @@ field[1].reference = PICT_BOTTOM_FIELD; field[1].poc= field[1].field_poc[1]; - h->luma_weight[list][16+2*i][0] = h->luma_weight[list][16+2*i+1][0] = h->luma_weight[list][i][0]; - h->luma_weight[list][16+2*i][1] = h->luma_weight[list][16+2*i+1][1] = h->luma_weight[list][i][1]; + h->luma_weight[16+2*i][list][0] = h->luma_weight[16+2*i+1][list][0] = h->luma_weight[i][list][0]; + h->luma_weight[16+2*i][list][1] = h->luma_weight[16+2*i+1][list][1] = h->luma_weight[i][list][1]; for(j=0; j<2; j++){ - h->chroma_weight[list][16+2*i][j][0] = h->chroma_weight[list][16+2*i+1][j][0] = h->chroma_weight[list][i][j][0]; - h->chroma_weight[list][16+2*i][j][1] = h->chroma_weight[list][16+2*i+1][j][1] = h->chroma_weight[list][i][j][1]; + h->chroma_weight[16+2*i][list][j][0] = h->chroma_weight[16+2*i+1][list][j][0] = h->chroma_weight[i][list][j][0]; + h->chroma_weight[16+2*i][list][j][1] = h->chroma_weight[16+2*i+1][list][j][1] = h->chroma_weight[i][list][j][1]; } } }