diff options
author | reimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2006-04-14 13:18:35 +0000 |
---|---|---|
committer | reimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2006-04-14 13:18:35 +0000 |
commit | 86b087112712cb82f5c0d1dc929da642927459b5 (patch) | |
tree | 0a9328708cb4e7c01d592cbdb1b213d99a667dba | |
parent | 3a1d78bc7a5d5ce7cf01edf678dc87eda54e0ccb (diff) | |
download | mpv-86b087112712cb82f5c0d1dc929da642927459b5.tar.bz2 mpv-86b087112712cb82f5c0d1dc929da642927459b5.tar.xz |
-ao pcm:fast suboption for faster-than-realtime dumping
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@18093 b3059339-0415-0410-9bf9-f77b7e298cf2
-rw-r--r-- | DOCS/man/en/mplayer.1 | 5 | ||||
-rw-r--r-- | help/help_mp-en.h | 2 | ||||
-rw-r--r-- | libao2/ao_pcm.c | 4 |
3 files changed, 9 insertions, 2 deletions
diff --git a/DOCS/man/en/mplayer.1 b/DOCS/man/en/mplayer.1 index c311acbbdf..5a28dcd490 100644 --- a/DOCS/man/en/mplayer.1 +++ b/DOCS/man/en/mplayer.1 @@ -2226,6 +2226,11 @@ When not included, raw PCM will be generated. Write the sound to <filename> instead of the default audiodump.wav. If nowaveheader is specified, the default is audiodump.pcm. +.IPs fast +Try to dump file faster than realtime. +Make sure the output does not get truncated (usually with +"Too many video packets in buffer" message). +It is normal that you get a "Your system is too SLOW to play this!" message. .RE .PD 1 . diff --git a/help/help_mp-en.h b/help/help_mp-en.h index 8be7ea55d0..e67aaec679 100644 --- a/help/help_mp-en.h +++ b/help/help_mp-en.h @@ -1094,7 +1094,7 @@ static char help_text[]= // ao_pcm.c #define MSGTR_AO_PCM_FileInfo "[AO PCM] File: %s (%s)\nPCM: Samplerate: %iHz Channels: %s Format %s\n" -#define MSGTR_AO_PCM_HintInfo "[AO PCM] Info: Faster dumping is achieved with -vc null -vo null\n[AO PCM] Info: To write WAVE files use -ao pcm:waveheader (default).\n" +#define MSGTR_AO_PCM_HintInfo "[AO PCM] Info: Faster dumping is achieved with -vc null -vo null -ao pcm:fast\n[AO PCM] Info: To write WAVE files use -ao pcm:waveheader (default).\n" #define MSGTR_AO_PCM_CantOpenOutputFile "[AO PCM] Failed to open %s for writing!\n" // ao_sdl.c diff --git a/libao2/ao_pcm.c b/libao2/ao_pcm.c index f6455bdb89..36acf5e703 100644 --- a/libao2/ao_pcm.c +++ b/libao2/ao_pcm.c @@ -27,6 +27,7 @@ extern int vo_pts; static char *ao_outputfilename = NULL; static int ao_pcm_waveheader = 1; +static int fast = 0; #define WAV_ID_RIFF 0x46464952 /* "RIFF" */ #define WAV_ID_WAVE 0x45564157 /* "WAVE" */ @@ -83,6 +84,7 @@ static int init(int rate,int channels,int format,int flags){ opt_t subopts[] = { {"waveheader", OPT_ARG_BOOL, &ao_pcm_waveheader, NULL}, {"file", OPT_ARG_MSTRZ, &ao_outputfilename, NULL}, + {"fast", OPT_ARG_BOOL, &fast, NULL}, {NULL} }; // set defaults @@ -179,7 +181,7 @@ static void audio_resume(void) static int get_space(void){ if(vo_pts) - return ao_data.pts < vo_pts ? ao_data.outburst : 0; + return ao_data.pts < vo_pts + fast * 30000 ? ao_data.outburst : 0; return ao_data.outburst; } |