Mercurial > mplayer.hg
diff mplayer.c @ 8627:14ab71b47a58
user friendly channel tuning + 10L fix in tvi_v4l (by Stephane Jourdois)
author | henry |
---|---|
date | Sat, 28 Dec 2002 22:57:39 +0000 |
parents | 544bb92b62e5 |
children | a8c4246b6869 |
line wrap: on
line diff
--- a/mplayer.c Sat Dec 28 21:58:21 2002 +0000 +++ b/mplayer.c Sat Dec 28 22:57:39 2002 +0000 @@ -613,6 +613,7 @@ int osd_show_sub_alignment = 0; int osd_show_vobsub_changed = 0; int osd_show_percentage = 0; +int osd_show_tv_channel = 25; int rtc_fd=-1; @@ -2467,15 +2468,46 @@ case MP_CMD_TV_STEP_CHANNEL : { if (tv_param_on == 1) { int v = cmd->args[0].v.i; - if(v > 0) + if(v > 0){ tv_step_channel((tvi_handle_t*)(demuxer->priv), TV_CHANNEL_HIGHER); - else +#ifdef USE_OSD + if (tv_channel_list) { + osd_show_tv_channel = sh_video->fps; + vo_osd_changed(OSDTYPE_SUBTITLE); + } +#endif + } else { tv_step_channel((tvi_handle_t*)(demuxer->priv), TV_CHANNEL_LOWER); +#ifdef USE_OSD + if (tv_channel_list) { + osd_show_tv_channel = sh_video->fps; + vo_osd_changed(OSDTYPE_SUBTITLE); + } +#endif + } } } break; case MP_CMD_TV_SET_CHANNEL : { - if (tv_param_on == 1) + if (tv_param_on == 1) { tv_set_channel((tvi_handle_t*)(demuxer->priv), cmd->args[0].v.s); +#ifdef USE_OSD + if (tv_channel_list) { + osd_show_tv_channel = sh_video->fps; + vo_osd_changed(OSDTYPE_SUBTITLE); + } +#endif + } + } break; + case MP_CMD_TV_LAST_CHANNEL : { + if (tv_param_on == 1) { + tv_last_channel((tvi_handle_t*)(demuxer->priv)); +#ifdef USE_OSD + if (tv_channel_list) { + osd_show_tv_channel = sh_video->fps; + vo_osd_changed(OSDTYPE_SUBTITLE); + } +#endif + } } break; case MP_CMD_TV_STEP_NORM : { if (tv_param_on == 1) @@ -2952,6 +2984,12 @@ osd_show_dvd_nav_delay--; } else #endif +#ifdef USE_TV + if (osd_show_tv_channel && tv_channel_list) { + sprintf(osd_text_tmp, "Channel: %s", tv_channel_current->name); + osd_show_tv_channel--; + } else +#endif if (osd_show_sub_visibility) { sprintf(osd_text_tmp, "Subtitles: %sabled", sub_visibility?"en":"dis"); osd_show_sub_visibility--;