diff options
author | atmos4 <atmos4@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2002-03-27 02:58:55 +0000 |
---|---|---|
committer | atmos4 <atmos4@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2002-03-27 02:58:55 +0000 |
commit | a6723d9346a9fd6bb91ad92fdee57c947cbf7b93 (patch) | |
tree | 4fce8bbab4241c35143f66477fcd101636d62ad2 /libmpcodecs/vd.c | |
parent | cf09259cc242c6076d853d785e093758654678a7 (diff) | |
download | mpv-a6723d9346a9fd6bb91ad92fdee57c947cbf7b93.tar.bz2 mpv-a6723d9346a9fd6bb91ad92fdee57c947cbf7b93.tar.xz |
Issue a warning in VDec if disp_w and disp_h weren't set by codec and try workaround.
Fix ijpg codec to set sh->disp_w and sh->disp_h.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@5366 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libmpcodecs/vd.c')
-rw-r--r-- | libmpcodecs/vd.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/libmpcodecs/vd.c b/libmpcodecs/vd.c index 64ffc48e80..f8d74fafe1 100644 --- a/libmpcodecs/vd.c +++ b/libmpcodecs/vd.c @@ -123,6 +123,18 @@ int mpcodecs_config_vo(sh_video_t *sh, int w, int h, unsigned int preferred_outf int screen_size_y=0;//SCREEN_SIZE_Y; vo_functions_t* video_out=sh->video_out; +#if 1 + if(!(sh->disp_w && sh->disp_h)) + mp_msg(MSGT_DECVIDEO,MSGL_WARN, + "VDec: codec didn't set sh->disp_w and sh->disp_h, trying to workaround!\n"); + /* XXX: HACK, if sh->disp_* aren't set, + * but we have w and h, set them :: atmos */ + if(!sh->disp_w && w) + sh->disp_w=w; + if(!sh->disp_h && h) + sh->disp_h=h; +#endif + mp_msg(MSGT_DECVIDEO,MSGL_INFO,"VDec: vo config request - %d x %d, %s \n", w,h,vo_format_name(preferred_outfmt)); |