linear encoding with audiotool

linear encoding with audiotool

Post by Cafer Barutcuza » Fri, 28 Jun 1996 04:00:00


I am trying to get my audiotool record in linear encoding rather than u-law
which is the default.

Checked the man pages and it tells you to use some ioctls for this job.
I have tried the following code:

        if ((ioctl(fd_audio, AUDIO_GETINFO, &auInfo)) == -1) {
                perror("ERROR: ioctl AUDIO_GETINFO");

        printf("encoding    = %d\n",;

        auInfo.record.encoding = 3;   /* 3 = linear encoding */

        if ((ioctl(fd_audio, AUDIO_SETINFO, &auInfo)) == -1) {
                perror("ERROR: ioctl AUDIO_SETINFO");

        if ((ioctl(fd_audio, AUDIO_GETINFO, &auInfo2)) == -1) {
                perror("ERROR: ioctl AUDIO_GETINFO");

        printf("encoding    = %d\n",;

where both auInfo and auInfo2 are audio_info_t structs. Both of my printfs result in
printing 1 which is u_law encoding.

Any ideas to get this thing record in linear (8-bit) encoding.
Please reply to:



|          Emory University   |  
|          Atlanta GA 30322            Phone : (404) 373-3410             |
|          USA                         Fax   : (404) 727-5611             |


1. Transfer-Encoding: chuunked AND Content-Encoding: deflate

using zlib

with HTTP/1.1

I am attempting to send
Transfer-Encoding: chunked
Content-Encoding: deflate

(from a home-built web server)

to a client browser that has indicated its willingness to accept this:
GET / HTTP/1.1
Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, application/, application/msword, application/, */*
Accept-Language: en,en-ca;q=0.9,de;q=0.8,fr;q=0.7,it;q=0.6,es;q=0.4,da;q=0.3,he;q=0.2,yi;q=0.1
Accept-Encoding: gzip, deflate
User-Agent: Mozilla/4.0 (compatible; MSIE 5.0; Windows 95; DigExt)
Connection: Keep-Alive

Ive RFC'd myself and tested the component peices individually . successfully.
my interpretation of the RFC leads me to format my HTTP response as:

chunksize n
chunksize n
chunksize 0

where n is the size of the deflated data

I am applying this deflation to arbitrary mime types and
maintaining the original mime-type.

if i had a website to look at that DOES do this successfully
I could compare  the output to see what I am doing wrong.. or indeed if
my browser is not handling it properly.

Does my interpretation of the RFC as to the format of the chunked and compressed
output seem correct?

Thanks in advance..

2. slackware bare.i problems?

3. audiotool and audioctl

4. How to NOT wait for an execve() to complete from CGI ???

5. help: what is the audiotool stereo file format

6. New logging application

7. Deleted audiotool from 2.3 - can someone send it to me ?

8. Program software

9. Audiotool does not work after running xdm

10. audiotool ok, but /dev/audio only pops?

11. AudioTool freezes SS5/Sol2.4 for some seconds -- is there a fix?

12. audiotool in AIX Motif ??

13. Audiotool- How to read Microsoft Windows .wav files?