summaryrefslogtreecommitdiffstats
path: root/input/input.c
diff options
context:
space:
mode:
authorarpi <arpi@b3059339-0415-0410-9bf9-f77b7e298cf2>2002-12-23 01:37:43 +0000
committerarpi <arpi@b3059339-0415-0410-9bf9-f77b7e298cf2>2002-12-23 01:37:43 +0000
commit725ff339e7093f11e1da39156cf7266dd6582f09 (patch)
treebdbd9ed7cb6e62dfa5798acfa251efab26d4b8a7 /input/input.c
parent38c4cdcfc587804cdb2dbb9f980ded0ca2659978 (diff)
downloadmpv-725ff339e7093f11e1da39156cf7266dd6582f09.tar.bz2
mpv-725ff339e7093f11e1da39156cf7266dd6582f09.tar.xz
This patch adds support for vertical subtitle alignment
control. Possible values are top, center, and bottom, with bottom being the default. Alignment is relevant when it comes to positioning subtitles with one line (or fewer lines) of text relative to multi-line subtitles. It is implemented as a new command (sub_alignment) that without an argument cycles the alignment (between top, center, and bottom), or with an argument sets the alignment (0 for top, 1 for center, 2 for bottom). The key 'i' is bound to this command. patch by Oskar Liljeblad (oskar@osk.mine.nu) git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@8535 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'input/input.c')
-rw-r--r--input/input.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/input/input.c b/input/input.c
index 3b580bd06b..b6b245a0f1 100644
--- a/input/input.c
+++ b/input/input.c
@@ -69,6 +69,7 @@ static mp_cmd_t mp_cmds[] = {
{ MP_CMD_SATURATION, "saturation",1, { {MP_CMD_ARG_INT,{0}}, {MP_CMD_ARG_INT,{0}}, {-1,{0}} } },
{ MP_CMD_FRAMEDROPPING, "frame_drop",0, { { MP_CMD_ARG_INT,{-1} }, {-1,{0}} } },
{ MP_CMD_SUB_POS, "sub_pos", 1, { {MP_CMD_ARG_INT,{0}}, {MP_CMD_ARG_INT,{0}}, {-1,{0}} } },
+ { MP_CMD_SUB_ALIGNMENT, "sub_alignment",0, { {MP_CMD_ARG_INT,{-1}}, {-1,{0}} } },
{ MP_CMD_SUB_VISIBILITY, "sub_visibility", 0, { {-1,{0}} } },
{ MP_CMD_VOBSUB_LANG, "vobsub_lang", 0, { {-1,{0}} } },
{ MP_CMD_GET_PERCENT_POS, "get_percent_pos", 0, { {-1,{0}} } },
@@ -247,6 +248,7 @@ static mp_cmd_bind_t def_cmd_binds[] = {
{ { 'd', 0 }, "frame_drop" },
{ { 'r', 0 }, "sub_pos -1" },
{ { 't', 0 }, "sub_pos +1" },
+ { { 'i', 0 }, "sub_alignment" },
{ { 'v', 0 }, "sub_visibility" },
{ { 'j', 0 }, "vobsub_lang" },
#ifdef USE_EDL