From 050b17ca9ced0811aeeb27f8ad628954d1f146cd Mon Sep 17 00:00:00 2001 From: wm4 Date: Fri, 15 Apr 2016 15:48:02 +0200 Subject: mp_image: make mp_image_copy_fields_* private Future code should always use mp_image_{to,from}_av_frame(). Everything else is way too messy and fragile. --- video/mp_image.c | 8 ++++---- video/mp_image.h | 4 ---- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/video/mp_image.c b/video/mp_image.c index 0910bb9abc..0ca59c62c9 100644 --- a/video/mp_image.c +++ b/video/mp_image.c @@ -666,8 +666,8 @@ void mp_image_params_guess_csp(struct mp_image_params *params) // Copy properties and data of the AVFrame into the mp_image, without taking // care of memory management issues. -void mp_image_copy_fields_from_av_frame(struct mp_image *dst, - struct AVFrame *src) +static void mp_image_copy_fields_from_av_frame(struct mp_image *dst, + struct AVFrame *src) { mp_image_setfmt(dst, pixfmt2imgfmt(src->format)); mp_image_set_size(dst, src->width, src->height); @@ -690,8 +690,8 @@ void mp_image_copy_fields_from_av_frame(struct mp_image *dst, // Copy properties and data of the mp_image into the AVFrame, without taking // care of memory management issues. -void mp_image_copy_fields_to_av_frame(struct AVFrame *dst, - struct mp_image *src) +static void mp_image_copy_fields_to_av_frame(struct AVFrame *dst, + struct mp_image *src) { dst->format = imgfmt2pixfmt(src->imgfmt); dst->width = src->w; diff --git a/video/mp_image.h b/video/mp_image.h index c808b5cf07..ef55dc5478 100644 --- a/video/mp_image.h +++ b/video/mp_image.h @@ -154,10 +154,6 @@ void mp_image_set_attributes(struct mp_image *image, const struct mp_image_params *params); struct AVFrame; -void mp_image_copy_fields_from_av_frame(struct mp_image *dst, - struct AVFrame *src); -void mp_image_copy_fields_to_av_frame(struct AVFrame *dst, - struct mp_image *src); struct mp_image *mp_image_from_av_frame(struct AVFrame *av_frame); struct AVFrame *mp_image_to_av_frame(struct mp_image *img); struct AVFrame *mp_image_to_av_frame_and_unref(struct mp_image *img); -- cgit v1.2.3