comparison mplayer.c @ 18206:4bc744cb60e7

Handle the tv color control commands with the properties.
author albeu
date Sat, 22 Apr 2006 19:29:02 +0000
parents 11d7992b37cf
children 8c35bd43135f
comparison
equal deleted inserted replaced
18205:07fad66caa44 18206:4bc744cb60e7
2153 { "sub_pos", MP_CMD_SUB_POS, 0, 0, -1, MSGTR_SubPosStatus }, 2153 { "sub_pos", MP_CMD_SUB_POS, 0, 0, -1, MSGTR_SubPosStatus },
2154 { "sub_alignment", MP_CMD_SUB_ALIGNMENT, 1, 0, -1, MSGTR_SubAlignStatus }, 2154 { "sub_alignment", MP_CMD_SUB_ALIGNMENT, 1, 0, -1, MSGTR_SubAlignStatus },
2155 { "sub_delay", MP_CMD_SUB_DELAY, 0, 0, OSD_MSG_SUB_DELAY, MSGTR_SubDelayStatus }, 2155 { "sub_delay", MP_CMD_SUB_DELAY, 0, 0, OSD_MSG_SUB_DELAY, MSGTR_SubDelayStatus },
2156 { "sub_visibility", MP_CMD_SUB_VISIBILITY, 1, 0, -1, MSGTR_SubVisibleStatus }, 2156 { "sub_visibility", MP_CMD_SUB_VISIBILITY, 1, 0, -1, MSGTR_SubVisibleStatus },
2157 { "sub_forced_only", MP_CMD_SUB_FORCED_ONLY, 1, 0, -1, MSGTR_SubForcedOnlyStatus }, 2157 { "sub_forced_only", MP_CMD_SUB_FORCED_ONLY, 1, 0, -1, MSGTR_SubForcedOnlyStatus },
2158 2158 #ifdef USE_TV
2159 { "tv_brightness", MP_CMD_TV_SET_BRIGHTNESS, 0, OSD_BRIGHTNESS, -1, MSGTR_Brightness },
2160 { "tv_hue", MP_CMD_TV_SET_HUE, 0, OSD_HUE, -1, MSGTR_Hue },
2161 { "tv_saturation", MP_CMD_TV_SET_SATURATION, 0, OSD_SATURATION, -1, MSGTR_Saturation },
2162 { "tv_contrast", MP_CMD_TV_SET_CONTRAST, 0, OSD_CONTRAST, -1, MSGTR_Contrast },
2163 #endif
2159 { NULL, 0, 0, 0, -1, NULL } 2164 { NULL, 0, 0, 0, -1, NULL }
2160 }; 2165 };
2161 2166
2162 static int set_property_command(mp_cmd_t* cmd) { 2167 static int set_property_command(mp_cmd_t* cmd) {
2163 int i,r; 2168 int i,r;
4272 } break; 4277 } break;
4273 case MP_CMD_TV_SET_NORM : { 4278 case MP_CMD_TV_SET_NORM : {
4274 if (file_format == DEMUXER_TYPE_TV) 4279 if (file_format == DEMUXER_TYPE_TV)
4275 tv_set_norm((tvi_handle_t*)(demuxer->priv), cmd->args[0].v.s); 4280 tv_set_norm((tvi_handle_t*)(demuxer->priv), cmd->args[0].v.s);
4276 } break; 4281 } break;
4277 case MP_CMD_TV_SET_BRIGHTNESS : {
4278 if (file_format == DEMUXER_TYPE_TV)
4279 tv_set_color_options((tvi_handle_t*)(demuxer->priv), TV_COLOR_BRIGHTNESS, cmd->args[0].v.i);
4280 } break;
4281 case MP_CMD_TV_SET_HUE : {
4282 if (file_format == DEMUXER_TYPE_TV)
4283 tv_set_color_options((tvi_handle_t*)(demuxer->priv), TV_COLOR_HUE, cmd->args[0].v.i);
4284 } break;
4285 case MP_CMD_TV_SET_SATURATION : {
4286 if (file_format == DEMUXER_TYPE_TV)
4287 tv_set_color_options((tvi_handle_t*)(demuxer->priv), TV_COLOR_SATURATION, cmd->args[0].v.i);
4288 } break;
4289 case MP_CMD_TV_SET_CONTRAST : {
4290 if (file_format == DEMUXER_TYPE_TV)
4291 tv_set_color_options((tvi_handle_t*)(demuxer->priv), TV_COLOR_CONTRAST, cmd->args[0].v.i);
4292 } break;
4293 case MP_CMD_TV_STEP_CHANNEL : { 4282 case MP_CMD_TV_STEP_CHANNEL : {
4294 if (file_format == DEMUXER_TYPE_TV) { 4283 if (file_format == DEMUXER_TYPE_TV) {
4295 int v = cmd->args[0].v.i; 4284 int v = cmd->args[0].v.i;
4296 if(v > 0){ 4285 if(v > 0){
4297 tv_step_channel((tvi_handle_t*)(demuxer->priv), TV_CHANNEL_HIGHER); 4286 tv_step_channel((tvi_handle_t*)(demuxer->priv), TV_CHANNEL_HIGHER);