mirror of
https://github.com/mpv-player/mpv.git
synced 2024-09-20 12:02:23 +02:00
-ss patch by Loring Holden
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@652 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
efe401c879
commit
67f6da0702
@ -58,7 +58,7 @@ struct config conf[]={
|
||||
{"bg", &play_in_bg, CONF_TYPE_FLAG, 0, 0, 1},
|
||||
{"nobg", &play_in_bg, CONF_TYPE_FLAG, 0, 1, 0},
|
||||
{"sb", &seek_to_byte, CONF_TYPE_INT, CONF_MIN, 0, 0},
|
||||
// {"ss", &seek_to_sec, CONF_TYPE_INT, CONF_MIN, 0, 0},
|
||||
{"ss", &seek_to_sec, CONF_TYPE_INT, CONF_MIN, 0, 0},
|
||||
{"sound", &has_audio, CONF_TYPE_FLAG, 0, 0, 1},
|
||||
{"nosound", &has_audio, CONF_TYPE_FLAG, 0, 1, 0},
|
||||
{"abs", &audio_buffer_size, CONF_TYPE_INT, CONF_MIN, 0, 0},
|
||||
|
@ -92,6 +92,8 @@ void vo_x11_putkey(int key){
|
||||
case wsSpace: mplayer_put_key(' '); break;
|
||||
case wsEscape: mplayer_put_key(KEY_ESC); break;
|
||||
case wsEnter: mplayer_put_key(KEY_ENTER); break;
|
||||
case wsPageUp: mplayer_put_key(KEY_PAGE_UP); break;
|
||||
case wsPageDown: mplayer_put_key(KEY_PAGE_DOWN); break;
|
||||
case wsq:
|
||||
case wsQ: mplayer_put_key('q'); break;
|
||||
case wsp:
|
||||
|
@ -1668,6 +1668,11 @@ switch(sh_video->codec->driver){
|
||||
case KEY_DOWN:
|
||||
osd_function=OSD_REW;
|
||||
rel_seek_secs-=60;break;
|
||||
// seek 10 min
|
||||
case KEY_PAGE_UP:
|
||||
rel_seek_secs+=600;break;
|
||||
case KEY_PAGE_DOWN:
|
||||
rel_seek_secs-=600;break;
|
||||
// delay correction:
|
||||
case '+':
|
||||
buffer_delay+=0.1; // increase audio buffer delay
|
||||
@ -1715,6 +1720,10 @@ switch(sh_video->codec->driver){
|
||||
mixer_usemaster=!mixer_usemaster;
|
||||
break;
|
||||
}
|
||||
if (seek_to_sec) {
|
||||
rel_seek_secs += seek_to_sec;
|
||||
seek_to_sec = 0;
|
||||
}
|
||||
if(rel_seek_secs)
|
||||
if(file_format==DEMUXER_TYPE_AVI && demuxer->idx_size<=0){
|
||||
printf("Can't seek in raw .AVI streams! (index required, try with the -idx switch!) \n");
|
||||
|
Loading…
Reference in New Issue
Block a user