Re: generating wavs

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

 



Andrew Gaydenko wrote:

> Say, I need to generate 1 second, 2 ch, given bps and sr wav filled with 
> (analog) 0.0 except for the only sample in middle with 1.0 value, or some 
> periodic sequence like { -1.0, -1.0, 1.0, 1.0, -1.0, -1.0, ... }, or something 
> else which can be described in few lines of C/Java-like language.
> 
> What is an appropriate software for such simple tasks?

Do you use GNU Octave at all?

If so, the latest versions of libsndfile ship with Octave modules
allowing you to do:

   octave:2> data = zeros(1,1000);
   octave:3> data (20) =  1 ;
   octave:4> sfwrite ("a.wav", data', 44100, "wav-float");

Erik
-- 
----------------------------------------------------------------------
Erik de Castro Lopo
http://www.mega-nerd.com/
_______________________________________________
Linux-audio-user mailing list
Linux-audio-user@xxxxxxxxxxxxxxxxxxxx
http://lists.linuxaudio.org/mailman/listinfo/linux-audio-user

[Index of Archives]     [Linux Sound]     [ALSA Users]     [Pulse Audio]     [ALSA Devel]     [Sox Users]     [Linux Media]     [Kernel]     [Photo Sharing]     [Gimp]     [Yosemite News]     [Linux Media]

  Powered by Linux