| 239 | } |
| 240 | |
| 241 | static int vaapi_encode_make_tile_slice(AVCodecContext *avctx, |
| 242 | VAAPIEncodePicture *pic) |
| 243 | { |
| 244 | VAAPIEncodeContext *ctx = avctx->priv_data; |
| 245 | VAAPIEncodeSlice *slice; |
| 246 | int i, j, index; |
| 247 | |
| 248 | for (i = 0; i < ctx->tile_cols; i++) { |
| 249 | for (j = 0; j < ctx->tile_rows; j++) { |
| 250 | index = j * ctx->tile_cols + i; |
| 251 | slice = &pic->slices[index]; |
| 252 | slice->index = index; |
| 253 | |
| 254 | pic->slices[index].block_start = ctx->col_bd[i] + |
| 255 | ctx->row_bd[j] * ctx->slice_block_cols; |
| 256 | pic->slices[index].block_size = ctx->row_height[j] * ctx->col_width[i]; |
| 257 | |
| 258 | av_log(avctx, AV_LOG_DEBUG, "Slice %2d: (%2d, %2d) start at: %4d " |
| 259 | "width:%2d height:%2d (%d blocks).\n", index, ctx->col_bd[i], |
| 260 | ctx->row_bd[j], slice->block_start, ctx->col_width[i], |
| 261 | ctx->row_height[j], slice->block_size); |
| 262 | } |
| 263 | } |
| 264 | |
| 265 | return 0; |
| 266 | } |
| 267 | |
| 268 | static int vaapi_encode_issue(AVCodecContext *avctx, |
| 269 | FFHWBaseEncodePicture *base_pic) |
no test coverage detected