diff options
author | reimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2006-11-05 12:10:44 +0000 |
---|---|---|
committer | reimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2006-11-05 12:10:44 +0000 |
commit | 710879686b7b68cccb662cf9e9337f3e5eec2fa4 (patch) | |
tree | 63d90c735c6cfa52c0aeca0c9bcec3773af05ecf /libmpcodecs/vd.c | |
parent | fcffd03e9f64de88fcfaa78a39d8e8a389317d38 (diff) | |
download | mpv-710879686b7b68cccb662cf9e9337f3e5eec2fa4.tar.bz2 mpv-710879686b7b68cccb662cf9e9337f3e5eec2fa4.tar.xz |
Always respect w and h params to mpcodecs_config_vo over
sh->disp_w and sh->disp_h, otherwise it will break when the
resolution changes mid-stream, like in
http://samples.mplayerhq.hu/MPEG2/res_change_ffmpeg_aspect.ts
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@20687 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libmpcodecs/vd.c')
-rw-r--r-- | libmpcodecs/vd.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/libmpcodecs/vd.c b/libmpcodecs/vd.c index e7c10056a2..9ad39fd936 100644 --- a/libmpcodecs/vd.c +++ b/libmpcodecs/vd.c @@ -140,13 +140,9 @@ int mpcodecs_config_vo(sh_video_t *sh, int w, int h, unsigned int preferred_outf int palette=0; int vocfg_flags=0; - if(!sh->disp_w || !sh->disp_h) - mp_msg(MSGT_DECVIDEO,MSGL_WARN, MSGTR_CodecDidNotSet); - /* XXX: HACK, if sh->disp_* aren't set, - * but we have w and h, set them :: atmos */ - if(!sh->disp_w && w) + if(w) sh->disp_w=w; - if(!sh->disp_h && h) + if(h) sh->disp_h=h; if(!sh->disp_w || !sh->disp_h) |