summaryrefslogtreecommitdiffstats
path: root/command.c
diff options
context:
space:
mode:
Diffstat (limited to 'command.c')
-rw-r--r--command.c107
1 files changed, 0 insertions, 107 deletions
diff --git a/command.c b/command.c
index fb40a0b60f..842a9359e0 100644
--- a/command.c
+++ b/command.c
@@ -51,7 +51,6 @@
#include "mixer.h"
#include "libmpcodecs/dec_video.h"
#include "libmpcodecs/dec_audio.h"
-#include "libmpcodecs/dec_teletext.h"
#include "osdep/strsep.h"
#include "sub/vobsub.h"
#include "sub/spudec.h"
@@ -2110,91 +2109,6 @@ static int mp_property_tv_color(m_option_t *prop, int action, void *arg,
#endif
-static int mp_property_teletext_common(m_option_t *prop, int action, void *arg,
- MPContext *mpctx)
-{
- int val, result;
- int base_ioctl = prop->offset;
- /*
- for teletext's GET,SET,STEP ioctls this is not 0
- SET is GET+1
- STEP is GET+2
- */
- if (!mpctx->demuxer || !mpctx->demuxer->teletext)
- return M_PROPERTY_UNAVAILABLE;
- if (!base_ioctl)
- return M_PROPERTY_ERROR;
-
- switch (action) {
- case M_PROPERTY_GET:
- if (!arg)
- return M_PROPERTY_ERROR;
- result = teletext_control(mpctx->demuxer->teletext, base_ioctl, arg);
- break;
- case M_PROPERTY_SET:
- if (!arg)
- return M_PROPERTY_ERROR;
- M_PROPERTY_CLAMP(prop, *(int *) arg);
- result = teletext_control(mpctx->demuxer->teletext, base_ioctl + 1,
- arg);
- break;
- case M_PROPERTY_STEP_UP:
- case M_PROPERTY_STEP_DOWN:
- result = teletext_control(mpctx->demuxer->teletext, base_ioctl, &val);
- val += (arg ? *(int *) arg : 1) * (action == M_PROPERTY_STEP_DOWN ?
- -1 : 1);
- result = teletext_control(mpctx->demuxer->teletext, base_ioctl + 1,
- &val);
- break;
- default:
- return M_PROPERTY_NOT_IMPLEMENTED;
- }
-
- return result == VBI_CONTROL_TRUE ? M_PROPERTY_OK : M_PROPERTY_ERROR;
-}
-
-static int mp_property_teletext_mode(m_option_t *prop, int action, void *arg,
- MPContext *mpctx)
-{
- int result;
- int val;
-
- //with tvh==NULL will fail too
- result = mp_property_teletext_common(prop, action, arg, mpctx);
- if (result != M_PROPERTY_OK)
- return result;
-
- if (teletext_control(mpctx->demuxer->teletext,
- prop->offset, &val) == VBI_CONTROL_TRUE && val)
- mp_input_set_section(mpctx->input, "teletext");
- else
- mp_input_set_section(mpctx->input, "tv");
- return M_PROPERTY_OK;
-}
-
-static int mp_property_teletext_page(m_option_t *prop, int action, void *arg,
- MPContext *mpctx)
-{
- int result;
- int val;
- if (!mpctx->demuxer->teletext)
- return M_PROPERTY_UNAVAILABLE;
- switch (action) {
- case M_PROPERTY_STEP_UP:
- case M_PROPERTY_STEP_DOWN:
- //This should be handled separately
- val = (arg ? *(int *) arg : 1) * (action == M_PROPERTY_STEP_DOWN ?
- -1 : 1);
- result = teletext_control(mpctx->demuxer->teletext,
- TV_VBI_CONTROL_STEP_PAGE, &val);
- break;
- default:
- result = mp_property_teletext_common(prop, action, arg, mpctx);
- }
- return result;
-}
-
-
/// All properties available in MPlayer.
/** \ingroup Properties
*/
@@ -2357,17 +2271,6 @@ static const m_option_t mp_properties[] = {
{ "tv_hue", mp_property_tv_color, CONF_TYPE_INT,
M_OPT_RANGE, -100, 100, .offset = TV_COLOR_HUE },
#endif
- { "teletext_page", mp_property_teletext_page, CONF_TYPE_INT,
- M_OPT_RANGE, 100, 899, .offset = TV_VBI_CONTROL_GET_PAGE },
- { "teletext_subpage", mp_property_teletext_common, CONF_TYPE_INT,
- M_OPT_RANGE, 0, 64, .offset = TV_VBI_CONTROL_GET_SUBPAGE },
- { "teletext_mode", mp_property_teletext_mode, CONF_TYPE_FLAG,
- M_OPT_RANGE, 0, 1, .offset = TV_VBI_CONTROL_GET_MODE },
- { "teletext_format", mp_property_teletext_common, CONF_TYPE_INT,
- M_OPT_RANGE, 0, 3, .offset = TV_VBI_CONTROL_GET_FORMAT },
- { "teletext_half_page", mp_property_teletext_common, CONF_TYPE_INT,
- M_OPT_RANGE, 0, 2, .offset = TV_VBI_CONTROL_GET_HALF_PAGE },
- { NULL, NULL, NULL, 0, 0, 0, NULL }
};
@@ -3356,16 +3259,6 @@ void run_command(MPContext *mpctx, mp_cmd_t *cmd)
tv_step_chanlist((tvi_handle_t *) (mpctx->demuxer->priv));
break;
#endif /* CONFIG_TV */
- case MP_CMD_TV_TELETEXT_ADD_DEC:
- if (mpctx->demuxer->teletext)
- teletext_control(mpctx->demuxer->teletext, TV_VBI_CONTROL_ADD_DEC,
- &(cmd->args[0].v.s));
- break;
- case MP_CMD_TV_TELETEXT_GO_LINK:
- if (mpctx->demuxer->teletext)
- teletext_control(mpctx->demuxer->teletext, TV_VBI_CONTROL_GO_LINK,
- &(cmd->args[0].v.i));
- break;
case MP_CMD_SUB_LOAD:
if (sh_video) {