Browse Source

avutil/hwcontext_cuda: check for missing pixel format

tags/n3.3
Timo Rothenpieler 9 years ago
parent
commit
52773a2c68
1 changed files with 3 additions and 0 deletions
  1. +3
    -0
      libavutil/hwcontext_cuda.c

+ 3
- 0
libavutil/hwcontext_cuda.c View File

@@ -117,6 +117,9 @@ static int cuda_frames_init(AVHWFramesContext *ctx)
case AV_PIX_FMT_P016:
size = aligned_width * ctx->height * 3;
break;
default:
av_log(ctx, AV_LOG_ERROR, "BUG: Pixel format missing from size calculation.");
return AVERROR_BUG;
}

ctx->internal->pool_internal = av_buffer_pool_init2(size, ctx, cuda_pool_alloc, NULL);


Loading…
Cancel
Save