Mercurial > mplayer.hg
comparison libao2/ao_pcm.c @ 1113:d92e19f1ae71
Ooops
author | atmosfear |
---|---|
date | Tue, 12 Jun 2001 14:37:32 +0000 |
parents | b1cf1087ec33 |
children | 981a9e5118ce |
comparison
equal
deleted
inserted
replaced
1112:b1cf1087ec33 | 1113:d92e19f1ae71 |
---|---|
78 if(!ao_outputfilename) { | 78 if(!ao_outputfilename) { |
79 ao_outputfilename = (char *) malloc(sizeof(char) * 14); | 79 ao_outputfilename = (char *) malloc(sizeof(char) * 14); |
80 strcpy(ao_outputfilename,(ao_pcm_waveheader ? "audiodump.wav" : "audiodump.pcm")); | 80 strcpy(ao_outputfilename,(ao_pcm_waveheader ? "audiodump.wav" : "audiodump.pcm")); |
81 } | 81 } |
82 | 82 |
83 wavhdr.fmt_length = 16; /* = format? */ | |
84 wavhdr.channels = channels; | 83 wavhdr.channels = channels; |
85 wavhdr.sample_rate = rate; | 84 wavhdr.sample_rate = rate; |
86 wavhdr.bytes_per_second = rate * (format / 8) * channels; | 85 wavhdr.bytes_per_second = rate * (format / 8) * channels; |
87 wavhdr.bits = format, | 86 wavhdr.bits = format; |
88 | 87 |
89 printf("PCM: File: %s (%s) Samplerate: %iHz Channels: %s Format %s\n", ao_outputfilename, (ao_pcm_waveheader?"WAVE":"RAW PCM"), rate, (channels > 1) ? "Stereo" : "Mono", audio_out_format_name(format)); | 88 printf("PCM: File: %s (%s) Samplerate: %iHz Channels: %s Format %s\n", ao_outputfilename, (ao_pcm_waveheader?"WAVE":"RAW PCM"), rate, (channels > 1) ? "Stereo" : "Mono", audio_out_format_name(format)); |
90 printf("PCM: Info - fastest dumping is achieved with -vo null -hardframedrop.\n"); | 89 printf("PCM: Info - fastest dumping is achieved with -vo null -hardframedrop.\n"); |
91 printf("PCM: Info - to write WAVE files use -waveheader (default), for RAW PCM -nowaveheader.\n"); | 90 printf("PCM: Info - to write WAVE files use -waveheader (default), for RAW PCM -nowaveheader.\n"); |
92 fp = fopen(ao_outputfilename, "wb"); | 91 fp = fopen(ao_outputfilename, "wb"); |