summaryrefslogtreecommitdiffstats
path: root/video/mp_image.h
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2014-04-29 13:31:59 +0200
committerwm4 <wm4@nowhere>2014-04-29 13:31:59 +0200
commitf6f8dc7782a411d1befadcc8425990451047f6cf (patch)
tree9747621e21d3c9ca674a571dbd63623cdfc0e18b /video/mp_image.h
parenta69e91756d77cff367c0def6211baf27da88677f (diff)
downloadmpv-f6f8dc7782a411d1befadcc8425990451047f6cf.tar.bz2
mpv-f6f8dc7782a411d1befadcc8425990451047f6cf.tar.xz
video: remove redundant mp_image display_w/_h members
Commit 5e4e248 added a mp_image_params field to mp_image, and moved many parameters to that struct. display_w/h was left redundant with mp_image_params.d_w/d_h. These fields were supposed to be always in sync, but it seems some code forgot to do this correctly, such as vf_fix_img_params() or mp_image_copy_attributes(). This led to the problem in github issue #756, because display_w/_h could become incorrect. It turns out that most code didn't use the old fields anyway. Just remove them. Note that mp_image_params.d_w/d_h are supposed to be always valid, so the additional checks for 0 shouldn't be needed. Remove these checks as well. Fixes #756.
Diffstat (limited to 'video/mp_image.h')
-rw-r--r--video/mp_image.h2
1 files changed, 0 insertions, 2 deletions
diff --git a/video/mp_image.h b/video/mp_image.h
index 16bdbfc2eb..9b2ef38c80 100644
--- a/video/mp_image.h
+++ b/video/mp_image.h
@@ -85,7 +85,6 @@ typedef struct mp_image {
int chroma_y_shift; // vertical
int w,h; // visible dimensions
- int display_w,display_h; // if set (!= 0), anamorphic size
uint8_t *planes[MP_MAX_PLANES];
int stride[MP_MAX_PLANES];
@@ -125,7 +124,6 @@ void mp_image_crop_rc(struct mp_image *img, struct mp_rect rc);
void mp_image_vflip(struct mp_image *img);
void mp_image_set_size(struct mp_image *mpi, int w, int h);
-void mp_image_set_display_size(struct mp_image *mpi, int dw, int dh);
void mp_image_setfmt(mp_image_t* mpi, int out_fmt);
void mp_image_steal_data(struct mp_image *dst, struct mp_image *src);