I have been learning the opcodes one by one. I'm using Csound 5.08 on Ubuntu Linux 7.10, compiled from source. I have also used Csound 5.08 on Windows and encountered the same problem:
Whenever I try to use the hetro / adsyn combination, the end result is always the same: white noise. I have tried every example I could find.
1. The one in the canonical manual is actually the worst -- the output is multiplied by 32768, resulting in staggeringly high amplitudes; removing the multiplication factor gives an in-range .wav file, but only white noise.
2. The examples from chapter 27 in the Csound book fail as well, producing
exactly the same white noise. (Also, the 2701.orc file has to be modified to load the correct file name.)
I have tried these and other examples I could find, both with downloaded and freshly-generated .het files; the result is always the same.
Any help would be appreciated.
--Bruce H. McCosar



5.08 seems slightly broken
I'm probably not the person who should be replying to this, but as no-one else has...
It looks to me as if something has gone wrong with adsyn in this release. I normally still use 4.23, and -- as I'd never played with those opcodes either -- when I saw your post I went and tried on my own system. I first just ran the example adsyn.orc/sco, which uses 'kickroll.het', something like:
csound -W -o test.wav adsyn.orc adsyn.sco(The '-W' is needed in 4.23, apparently not in 5.08.) The result seems a reasonably good reproduction of 'kickroll.wav', so I guess things are working there. I then checked going the other way:
csound -U hetro kickroll.wav test.hetAgain, results seemed reasonable -- passing the test.het back through adsyn generated a reasonable output (if rather muffled -- presumably due to different hetro parameters).
I didn't have 5.08 installed, but I compiled it onto our lab server (as it has lots of free space...), and tried the above again on that. Rather different. The first step generated an output that sounded sort of like the original, but you're right -- it pegged the output meter! And 37K of the 44100 samples were "out of range"!
Generating another het file from the original wav and passing that through adsyn produced an almost unrecognisable sound. I wouldn't call it quite "white noise" -- it still had the original structure -- but close...
So I don't think the problem is with you. I looked at the sources briefly, and the adsyn code is much the same, but changes had to be made for the new environment in Csound. I suspect this has resulted in some necessary initialization being lost. Complain to the management... (:-))
aha!
Hey, thanks for the confirmation! I am new enough to Csound that a small part of me suspected that I'd set something up wacky. It's good to know the problem can be duplicated elsewhere. (And that I'm not wacky.)
By my count (using csound -z), the new version of Csound has 1403 opcodes ... I think as of today I've investigated about 10 to 15 % of them.
adsynwas the only one, so far, to give me a problem I couldn't figure out.I'm not sure if the *32768 issue is a bug -- it may mean that the output is actually being scaled to 0dbfs by default, now, as opposed to some other time when it wasn't. Maybe when a subroutine comes back from version 5, something internal to
adsynis doing a similar scaling operation, blowing the waves up thousands of times beyond the clipping point.Thanks for the reply, and for taking the time to investigate. :-)
--
http://www.jamendo.com/en/artist/bruce.h.mccosar
http://bmccosar.wordpress.com/