[svlug] Re: making a silent ogg or mp3

George Georgalis georgw at galis.org
Wed Jul 9 11:08:17 PDT 2003

On Wed, Jul 09, 2003 at 12:56:15PM -0400, Michael Bacarella wrote:
>> Hi all, how can I create n seconds of silent ogg or mp3, eg not
>> recording the preamp with the level set to zero but something akin to
>> cat /dev/zero > silence.ogg
>You can do precisely that:
>    dd if=/dev/zero of=silence.pcm bs=176400 count=N
>where N equal number of seconds.  Then run:
>    oggenc -r silence.pcm
>to produce an ogg.  -r assumes you're working with a raw
>headerless straight-from-CD audio track.
>Where does 176400 come from?  Each CD redbook audio track
>contains 75 audio "frames" per second, of 2352 bytes
>each in raw mode.  75 * 2352 = 176400 (All of this information
>is contained in /usr/include/linux/cdrom.h, btw)
>Michael Bacarella                  24/7 phone: 646 641-8662
>Netgraft Corporation                   http://netgraft.com/

Beautiful, thanks very much.

// George

GEORGE GEORGALIS, System Admin/Architect    cell: 646-331-2027    <IXOYE><
Security Services, Web, Mail,            mailto:george at galis.org 
Multimedia, DB, DNS and Metrics.       http://www.galis.org/george 

More information about the svlug mailing list