aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/dvbsubdec.c
diff options
context:
space:
mode:
authorPierre Yves MORDRET <pierre-yves.mordret@st.com>2013-12-13 14:29:09 +0100
committerMichael Niedermayer <michaelni@gmx.at>2013-12-13 16:53:22 +0100
commit0f02ea0afe969fb5d37a879ef77ceb6d86f6dc4e (patch)
treebbddc7694672d0282f5d9ad1dfc3fd0579e297e0 /libavcodec/dvbsubdec.c
parent1d0995e3a59eb37509888cfc7c2b173fd3dbb4f7 (diff)
downloadffmpeg-0f02ea0afe969fb5d37a879ef77ceb6d86f6dc4e.tar.gz
libavcodec/dvbsub: fix for Display Definition Segment
Given ETSI EN 300 743 V1.3.1 (2006-11), 7.2.1 Display definition segment display window parameters are given in this order XMin, XMax, YMin, YMax if display_window_flag is set, but here this is not the case. As a consequence the DVB subtitles are not displayed upon some videos. Signed-off-by: Pierre-Yves MORDRET <pierre-yves.mordret@st.com> Reviewed-by: Kieran Kunhya <kierank@obe.tv> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/dvbsubdec.c')
-rw-r--r--libavcodec/dvbsubdec.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/dvbsubdec.c b/libavcodec/dvbsubdec.c
index b8b414343d..8f4e984802 100644
--- a/libavcodec/dvbsubdec.c
+++ b/libavcodec/dvbsubdec.c
@@ -1357,8 +1357,8 @@ static void dvbsub_parse_display_definition_segment(AVCodecContext *avctx,
if (info_byte & 1<<3) { // display_window_flag
display_def->x = bytestream_get_be16(&buf);
- display_def->y = bytestream_get_be16(&buf);
display_def->width = bytestream_get_be16(&buf) - display_def->x + 1;
+ display_def->y = bytestream_get_be16(&buf);
display_def->height = bytestream_get_be16(&buf) - display_def->y + 1;
}
}