[FFmpeg-cvslog] lavu/hwcontext_d3d: Cast src pointers calling av_image_copy*().
Carl Eugen Hoyos
git at videolan.org
Fri Apr 19 15:20:57 EEST 2019
ffmpeg | branch: master | Carl Eugen Hoyos <ceffmpeg at gmail.com> | Thu Apr 18 13:55:29 2019 +0200| [a24a1523e8d7f13e244c5f11e3a9e0cfd6998cfa] | committer: Carl Eugen Hoyos
lavu/hwcontext_d3d: Cast src pointers calling av_image_copy*().
Silences several warnings:
libavutil/hwcontext_d3d11va.c:413:49: warning: passing argument 3 of ‘av_image_copy’ from incompatible pointer type
libavutil/hwcontext_d3d11va.c:425:47: warning: passing argument 3 of ‘av_image_copy’ from incompatible pointer type
libavutil/hwcontext_dxva2.c:351:45: warning: passing argument 3 of ‘av_image_copy’ from incompatible pointer type
libavutil/hwcontext_dxva2.c:382:52: warning: passing argument 3 of ‘av_image_copy_uc_from’ from incompatible pointer type
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=a24a1523e8d7f13e244c5f11e3a9e0cfd6998cfa
---
libavutil/hwcontext_d3d11va.c | 4 ++--
libavutil/hwcontext_dxva2.c | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/libavutil/hwcontext_d3d11va.c b/libavutil/hwcontext_d3d11va.c
index 41330f0ae6..6670c47579 100644
--- a/libavutil/hwcontext_d3d11va.c
+++ b/libavutil/hwcontext_d3d11va.c
@@ -410,7 +410,7 @@ static int d3d11va_transfer_data(AVHWFramesContext *ctx, AVFrame *dst,
fill_texture_ptrs(map_data, map_linesize, ctx, &desc, &map);
- av_image_copy(dst->data, dst->linesize, map_data, map_linesize,
+ av_image_copy(dst->data, dst->linesize, (const uint8_t **)map_data, map_linesize,
ctx->sw_format, w, h);
ID3D11DeviceContext_Unmap(device_hwctx->device_context, staging, 0);
@@ -422,7 +422,7 @@ static int d3d11va_transfer_data(AVHWFramesContext *ctx, AVFrame *dst,
fill_texture_ptrs(map_data, map_linesize, ctx, &desc, &map);
- av_image_copy(map_data, map_linesize, src->data, src->linesize,
+ av_image_copy(map_data, map_linesize, (const uint8_t **)src->data, src->linesize,
ctx->sw_format, w, h);
ID3D11DeviceContext_Unmap(device_hwctx->device_context, staging, 0);
diff --git a/libavutil/hwcontext_dxva2.c b/libavutil/hwcontext_dxva2.c
index 4585f323bb..64366cea89 100644
--- a/libavutil/hwcontext_dxva2.c
+++ b/libavutil/hwcontext_dxva2.c
@@ -348,7 +348,7 @@ static int dxva2_transfer_data_to(AVHWFramesContext *ctx, AVFrame *dst,
if (ret < 0)
goto fail;
- av_image_copy(map->data, map->linesize, src->data, src->linesize,
+ av_image_copy(map->data, map->linesize, (const uint8_t **)src->data, src->linesize,
ctx->sw_format, src->width, src->height);
fail:
@@ -379,7 +379,7 @@ static int dxva2_transfer_data_from(AVHWFramesContext *ctx, AVFrame *dst,
dst_linesize[i] = dst->linesize[i];
src_linesize[i] = map->linesize[i];
}
- av_image_copy_uc_from(dst->data, dst_linesize, map->data, src_linesize,
+ av_image_copy_uc_from(dst->data, dst_linesize, (const uint8_t **)map->data, src_linesize,
ctx->sw_format, src->width, src->height);
fail:
av_frame_free(&map);
More information about the ffmpeg-cvslog
mailing list