summaryrefslogtreecommitdiffstats
path: root/video
diff options
context:
space:
mode:
Diffstat (limited to 'video')
-rw-r--r--video/decode/dec_video.c4
-rw-r--r--video/decode/dec_video.h4
-rw-r--r--video/decode/vd_lavc.c4
3 files changed, 5 insertions, 7 deletions
diff --git a/video/decode/dec_video.c b/video/decode/dec_video.c
index f8441f005d..1b461a619a 100644
--- a/video/decode/dec_video.c
+++ b/video/decode/dec_video.c
@@ -385,9 +385,7 @@ int mpcodecs_reconfig_vo(struct dec_video *d_video,
d_video->vf_initialized = 1;
- if (!d_video->vf_input)
- d_video->vf_input = talloc(sh, struct mp_image_params);
- *d_video->vf_input = p;
+ d_video->vf_input = p;
if (opts->gamma_gamma != 1000)
video_set_colors(d_video, "gamma", opts->gamma_gamma);
diff --git a/video/decode/dec_video.h b/video/decode/dec_video.h
index c9601efb7b..ebb2624037 100644
--- a/video/decode/dec_video.h
+++ b/video/decode/dec_video.h
@@ -34,8 +34,8 @@ struct dec_video {
const struct vd_functions *vd_driver;
int vf_initialized; // -1 failed, 0 not done, 1 done
long vf_reconfig_count; // incremented each mpcodecs_reconfig_vo() call
- struct mp_image_params *vf_input; // video filter input params
- struct mp_hwdec_info *hwdec_info; // video output hwdec handles
+ struct mp_image_params vf_input; // video filter input params
+ struct mp_hwdec_info hwdec_info; // video output hwdec handles
struct sh_stream *header;
char *decoder_desc;
diff --git a/video/decode/vd_lavc.c b/video/decode/vd_lavc.c
index 37c94fa881..332de553a6 100644
--- a/video/decode/vd_lavc.c
+++ b/video/decode/vd_lavc.c
@@ -224,7 +224,7 @@ static bool probe_hwdec(struct dec_video *vd, bool autoprobe, enum hwdec_type ap
return false;
}
const char *hw_decoder = NULL;
- int r = hwdec_probe(hwdec, vd->hwdec_info, decoder, &hw_decoder);
+ int r = hwdec_probe(hwdec, &vd->hwdec_info, decoder, &hw_decoder);
if (r >= 0) {
*use_hwdec = hwdec;
*use_decoder = hw_decoder;
@@ -380,7 +380,7 @@ static void init_avctx(struct dec_video *vd, const char *decoder,
if (!lavc_codec)
return;
- ctx->hwdec_info = vd->hwdec_info;
+ ctx->hwdec_info = &vd->hwdec_info;
ctx->do_dr1 = ctx->do_hw_dr1 = 0;
ctx->pix_fmt = PIX_FMT_NONE;