1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119
|
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META NAME="GENERATOR" CONTENT="Mozilla/4.03 [en] (X11; I; IRIX 6.3 IP32) [Netscape]">
<TITLE>HETRO</TITLE>
</HEAD>
<BODY>
<CENTER><A NAME="HETRO"></A>
<HR><B><A HREF="../REFER.html">QUICK-REF</A></B> - <B><A HREF="../TITLE.html"><FONT SIZE=+1>C</FONT>soundManual</A></B>
- <B><A HREF="UTILITIES.html">Top of this section</A></B> - <A HREF="sndinfo.html">Previous</A>
- <A HREF="../CONTENTS.html">Contents</A> - <A HREF="../INDEX.html">Index</A>
- <A HREF="lpanal.html">Next</A>
<HR></CENTER>
<H2>
HETRO</H2>
<B>HETRO</B> - hetrodyne filter analysis for the Csound <B>adsyn </B>generator.
<PRE><TT> <B>csound -U hetro</B> [flags] infilename outfilename
or <B>hetro </B> [flags] infilename outfilename</TT></PRE>
<B>hetro</B> takes an input soundfile, decomposes it into component sinusoids,
and outputs a description of the components in the form of breakpoint amplitude
and frequency tracks. Analysis is conditioned by the control flags below.
A space is optional between flag and value.
<P>-<B>s</B><srate> sampling rate of the audio input file. This will
over-ride the srate of the soundfile header, which otherwise applies. If
neither is present, the default is 10000. Note that for <B><A HREF="../Generate/adsyn.html">adsyn</A></B>
synthesis the srate of the source file and the generating orchestra need
not be the same.
<P>-<B>c</B><channel> channel number sought. The default is 1.
<P>-<B>b</B><begin> beginning time (in seconds) of the audio segment
to be analyzed. The default is 0.0
<P>-<B>d</B><duration> duration (in seconds) of the audio segment to
be analyzed. The default of 0.0 means to the end of the file. Maximum length
is 32.766 seconds.
<P>-<B>f</B><begfreq> estimated starting frequency of the fundamental,
necessary to initialize the filter analysis. The default is 100 (cps).
<P>-<B>h</B><partials> number of harmonic partials sought in the audio
file. Default is 10, maximum is a function of memory available.
<P>-<B>M</B><maxamp> maximum amplitude summed across all concurrent
tracks. The default is 32767.
<P>-<B>m</B><minamp> amplitude threshold below which a single pair of
amplitude/frequency tracks is considered dormant and will not contribute
to output summation. Typical values: 128 (48 db down from full scale),
64 (54 db down), 32 (60 db down), 0 (no thresholding). The default threshold
is 64 (54 db down).
<P>-<B>n</B><brkpts> initial number of analysis breakpoints in each
amplitude and frequency track, prior to thresholding (-<B>m</B>) and linear
breakpoint consolidation. The initial points are spread evenly over the
duration. The default is 256.
<P>-<B>l</B><cutfreq> substitute a 3rd order Butterworth low-pass filter
with cutoff frequency <I>cutfreq</I> (in cps), in place of the default
averaging comb filter. The default is 0 (don't use).
<H4>
<U>EXAMPLE</U></H4>
<B>hetro</B> -s44100 -b.5 -d2.5 -h16 -M24000 audiofile.test adsynfile7
<P>This will analyze 2.5 seconds of channel 1 of a file "audiofile.test",
recorded at 44.1 KHz, beginning .5 seconds from the start, and place the
result in a file "adsynfile7". We request just the first 16 harmonics of
the sound, with 256 initial breakpoint values per amplitude or frequency
track, and a peak summation amplitude of 24000. The fundamental is estimated
to begin at 100 Hz. Amplitude thresholding is at 54 db down.
<P>The Butterworth LPF is not enabled.
<H4>
<U>FILE FORMAT</U></H4>
The output file contains time-sequenced amplitude and frequency values
for each partial of an additive complex audio source. The information is
in the form of breakpoints (time, value, time, value, ....) using 16-bit
integers in the range 0 - 32767. Time is given in milliseconds, and frequency
in Hertz (cps). The breakpoint data is exclusively non-negative, and the
values -1 and -2 uniquely signify the start of new amplitude and frequency
tracks. A track is terminated by the value 32767. Before being written
out, each track is data-reduced by amplitude thresholding and linear breakpoint
consolidation.
<P>A component partial is defined by two breakpoint sets: an amplitude
set, and a frequency set. Within a composite file these sets may appear
in any order (amplitude, frequency, amplitude ....; or amplitude, amplitude...,
then frequency, frequency,...). During <B><A HREF="../Generate/adsyn.html">adsyn</A></B>
resynthesis the sets are automatically paired (amplitude, frequency) from
the order in which they were found. There should be an equal number of
each.
<P>A legal <B>adsyn</B> control file could have following format:
<PRE><TT>-1 time1 value1 ... timeK valueK 32767 ; amplitude breakpoints for partial 1
-2 time1 value1 ... timeL valueL 32767 ; frequency breakpoints for partial 1
-1 time1 value1 ... timeM valueM 32767 ; amplitude breakpoints for partial 2
-2 time1 value1 ... timeN valueN 32767 ; frequency breakpoints for partial 2
-2 time1 value1 ..........
-2 time1 value1 .......... ; pairable tracks for partials 3 and 4
-1 time1 value1 ..........
-1 time2 value1 ..........</TT></PRE>
<CENTER><P>
<HR><B><A HREF="../REFER.html">QUICK-REF</A></B> - <B><A HREF="../TITLE.html"><FONT SIZE=+1>C</FONT>soundManual</A></B>
- <B><A HREF="UTILITIES.html">Top of this section</A></B> - <A HREF="sndinfo.html">Previous</A>
- <A HREF="../CONTENTS.html">Contents</A> - <A HREF="../INDEX.html">Index</A>
- <A HREF="lpanal.html">Next</A>
<HR></CENTER>
<P><CENTER>
<B><I><FONT COLOR="#006600">HTML Csound Manual - <FONT SIZE=-1>©
Jean Piché & Peter J. Nix, 1994-97</FONT></FONT></I></B>
</CENTER>
</HTML>
|