On Tue, Oct 24, 2023 at 09:15:57PM +0600, Maria Morisot wrote:
> It is my understanding that wav files contain the headers necessary for a 
> program to adjust the audio settings for play, or to do the software process 
> necessary to reformat the input to the audio device.
> 
> It doesn't make sense to have the wav headers if they aren't going to be 
> used. Tell me if I'm wrong.
> 
> I'm not very good at C but I'm willing to try to fix aucat to adjust wav 
> output in response to the headers if that's something that seems like it's 
> broken.
> 

You're right. The .wav headers require to lseek(2) within the file
which doesn't work on a pipes. It could work on certain files which
headers are placed in a way lseek(2) doesn't need to move the file
pointer.

You could try to modify aucat to skip the lseek(2) calls if it
wouldn't change the file pointer.  Possibly call read(2) and discard
few bytes when the file pointer moves forward by few bytes only (iirc
.wav needs data to be aligned).

HTH

Reply via email to