RE: Sound Programming.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



As far as I can get you and asaik  

Your underlying driver/dsp chip should allow you to play it in any
format/chaanel/sampling rate tou want.

When you write the code for recording and playing you specify these three
parameters.
I have done this exercise on symbian and wince but not on linux.

For more reference I found these 2 releveant links
http://www.speech.cs.cmu.edu/festival/cstr/festival/free-1.4.1/PATCHES/voxwa
re.cc

look into play_voxware_wave function

and http://www.oreilly.de/catalog/multilinux/excerpt/ch14-05.htm

Gowri.

-----Original Message-----
From: Amith [mailto:amith@multitech.co.in]
Sent: Tuesday, February 17, 2004 11:18 AM
To: Newbies
Cc: Gowri Ramasubramanian
Subject: Re: Sound Programming.


hmm.. nope not on a desktop -   iam using the same code to play the file i
just
do some changes to the source file so that it reads from the file - (which
contains the recorded voice data, that was recorded from a diff system ) and
writes to "/dev/dsp" rather than reading from /dev/dsp . Hope iam clear now.
And iam wondering how do people manage code so that it plays a certain
channel/format/sampling rate  clearly on diff systems - iam confused :-( .
does this disparity  have something to do with hardware ?????
cheers,
Amith


Gowri Ramasubramanian wrote:

> What are you playing the file with? your own program or another
application
> already present?
>
> In that case when you play the file you should ensure that the format,
rate
> and chaanels of the application you are using to play are the same as you
> had used for recording.
>
> And are you doing it on a desktop?
>
> Gowri.
>
> -----Original Message-----
> From: kernelnewbies-bounce@nl.linux.org
> [mailto:kernelnewbies-bounce@nl.linux.org]
> Sent: Tuesday, February 17, 2004 9:53 AM
> To: Newbies
> Subject: Sound Programming.
>
> hi all,
>             i had sent a similar query before. Now, the problem i have
> is something like this :
>             i use OSS sound programming guide as a reference.
>             i use the API given in <linux/souncard.h>
>             i set the number of channels to one (1) Mono. /* ioctl calls
> */
>             i set the sampling rate to 11025
>             i set the sampling format to Unsigned Little Endian .
>             Now i record sound for sometime using read() and play it
> back on my system using write() it works fine.
>             I write the recorded sound (data) to a file through my
> program and i copy the file to another system.
>             I try playing it there it gives me a loud noise . The reason
> i'am sending this query again is that many people had rightly
>            pointed out that i hadn't set the Channels/Format/Sampling
> Rate (then) . But now i have done all this but it still
>            seems to me that the problem persists. Could anyone help ?
>
> Thank you.
> -Amith
>
> --
> Kernelnewbies: Help each other learn about the Linux kernel.
> Archive:       http://mail.nl.linux.org/kernelnewbies/
> FAQ:           http://kernelnewbies.org/faq/


--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux