Revision 48bf1325

View differences:

libavcodec/vaapi_h264.c
198 198
        /* VA API also wants the inferred (default) values, not
199 199
           only what is available in the bitstream (7.4.3.2). */
200 200
        if (h->luma_weight_flag[list]) {
201
            luma_weight[i] = h->luma_weight[list][i];
202
            luma_offset[i] = h->luma_offset[list][i];
201
            luma_weight[i] = h->luma_weight[list][i][0];
202
            luma_offset[i] = h->luma_weight[list][i][1];
203 203
        } else {
204 204
            luma_weight[i] = 1 << h->luma_log2_weight_denom;
205 205
            luma_offset[i] = 0;
206 206
        }
207 207
        for (j = 0; j < 2; j++) {
208 208
            if (h->chroma_weight_flag[list]) {
209
                chroma_weight[i][j] = h->chroma_weight[list][i][j];
210
                chroma_offset[i][j] = h->chroma_offset[list][i][j];
209
                chroma_weight[i][j] = h->chroma_weight[list][i][j][0];
210
                chroma_offset[i][j] = h->chroma_weight[list][i][j][1];
211 211
            } else {
212 212
                chroma_weight[i][j] = 1 << h->chroma_log2_weight_denom;
213 213
                chroma_offset[i][j] = 0;

Also available in: Unified diff