aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/nvenc.c
diff options
context:
space:
mode:
authorTimo Rothenpieler <timo@rothenpieler.org>2017-02-10 15:00:21 +0100
committerTimo Rothenpieler <timo@rothenpieler.org>2017-02-13 11:30:52 +0100
commit8a3fea14ae94f715fc508098aa7d8ad89ee80054 (patch)
tree39e2c293fd5d69df538f605985267ad1c1cecbae /libavcodec/nvenc.c
parent50708f4aa40ce96122cf93d9e36cca8024baf025 (diff)
downloadffmpeg-8a3fea14ae94f715fc508098aa7d8ad89ee80054.tar.gz
avcodec/nvenc: set frame buffer format for mapped frames
Diffstat (limited to 'libavcodec/nvenc.c')
-rw-r--r--libavcodec/nvenc.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/libavcodec/nvenc.c b/libavcodec/nvenc.c
index 7005465df6..51e794e76b 100644
--- a/libavcodec/nvenc.c
+++ b/libavcodec/nvenc.c
@@ -1421,6 +1421,7 @@ static int nvenc_upload_frame(AVCodecContext *avctx, const AVFrame *frame,
ctx->registered_frames[reg_idx].mapped = 1;
nvenc_frame->reg_idx = reg_idx;
nvenc_frame->input_surface = nvenc_frame->in_map.mappedResource;
+ nvenc_frame->format = nvenc_frame->in_map.mappedBufferFmt;
nvenc_frame->pitch = frame->linesize[0];
return 0;
} else {