Mercurial > mplayer.hg
changeset 18092:96fdfbad5b1a
-ao pcm:fast suboption for faster-than-realtime dumping
author | reimar |
---|---|
date | Fri, 14 Apr 2006 13:18:35 +0000 |
parents | 71f9a4e7fd9d |
children | 937c496ed2e8 |
files | DOCS/man/en/mplayer.1 help/help_mp-en.h libao2/ao_pcm.c |
diffstat | 3 files changed, 9 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/DOCS/man/en/mplayer.1 Fri Apr 14 13:03:05 2006 +0000 +++ b/DOCS/man/en/mplayer.1 Fri Apr 14 13:18:35 2006 +0000 @@ -2226,6 +2226,11 @@ 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 .
--- a/help/help_mp-en.h Fri Apr 14 13:03:05 2006 +0000 +++ b/help/help_mp-en.h Fri Apr 14 13:18:35 2006 +0000 @@ -1094,7 +1094,7 @@ // 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
--- a/libao2/ao_pcm.c Fri Apr 14 13:03:05 2006 +0000 +++ b/libao2/ao_pcm.c Fri Apr 14 13:18:35 2006 +0000 @@ -27,6 +27,7 @@ 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 @@ 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 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; }