summaryrefslogtreecommitdiffstats
path: root/mplayer.c
diff options
context:
space:
mode:
authornicodvb <nicodvb@b3059339-0415-0410-9bf9-f77b7e298cf2>2007-09-01 15:56:19 +0000
committernicodvb <nicodvb@b3059339-0415-0410-9bf9-f77b7e298cf2>2007-09-01 15:56:19 +0000
commitbe450f82930cc5bc0c8ae65981f1dac7d0bcbd92 (patch)
treee5cd0a6ee7cec9c2605400fd58213e533dc384e4 /mplayer.c
parent1dbfe77925d859624a6ada592c80cf5c2e59dee7 (diff)
downloadmpv-be450f82930cc5bc0c8ae65981f1dac7d0bcbd92.tar.bz2
mpv-be450f82930cc5bc0c8ae65981f1dac7d0bcbd92.tar.xz
if the stream reader supports it assign to the video the stream aspect ratio
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24320 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'mplayer.c')
-rw-r--r--mplayer.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/mplayer.c b/mplayer.c
index 9f66f0bc64..cafdd9eacc 100644
--- a/mplayer.c
+++ b/mplayer.c
@@ -3067,6 +3067,7 @@ mpctx->sh_video=mpctx->d_video->sh;
if(mpctx->sh_video){
+ double ar=-1.0;
current_module="video_read_properties";
if(!video_read_properties(mpctx->sh_video)) {
mp_msg(MSGT_CPLAYER,MSGL_ERR,MSGTR_CannotReadVideoProperties);
@@ -3088,6 +3089,8 @@ if(mpctx->sh_video){
mp_msg(MSGT_CPLAYER,MSGL_ERR,MSGTR_FPSnotspecified);
mpctx->sh_video=mpctx->d_video->sh=NULL;
}
+ if(stream_control(mpctx->demuxer->stream, STREAM_CTRL_GET_ASPECT_RATIO, &ar) != STREAM_UNSUPPORTED)
+ mpctx->sh_video->stream_aspect = ar;
}
}